| ||||||||||
Shopping cart software Solutions for online shops and malls | ||||||||||
|
X-Cart Home | FAQ | Forum rules | Calendar | User manuals | Login |
How to generate a product catalog to embed on any (non-X-Cart) page? | |||
|
|
Thread Tools | Search this Thread |
#1
|
|||||||
|
|||||||
How to generate a product catalog to embed on any (non-X-Cart) page?
How to generate a product catalog to embed on any (non-X-Cart) page?
A grid list or any type of list with the products, just as on the catalog pages of X-Cart. Possibly all-in-one, consisting of parts like: - thumbnails - titles - short descriptions - prices - add to cart buttons
__________________
5.3.1.3 |
|||||||
#2
|
|||||||||
|
|||||||||
Re: How to generate a product catalog to embed on any (non-X-Cart) page?
It depends on where you want to include the data. Will you do it server-side, or do you want to include the section into an HTML page via a JavaScript code?
Anyway, implementing this may be tricky as the server-side solution may conflict with your PHP code, and the JavaScript solution may require complex JavaScript code to get all the X-Cart functions (pagers, add-to-cart, ...) work as intended.
__________________
Alex Solovev, Qualiteam --- User manual Video tutorials X-Cart FAQ You are welcome to press "Thanks" button if you find this post useful Click here to learn how to apply patches X-Cart Extensions |
|||||||||
#3
|
|||||||
|
|||||||
Re: How to generate a product catalog to embed on any (non-X-Cart) page?
You talk about conflicts with PHP, but therefore you have for example json to have data available which can be (that's my idea, because that's where json could be suitable for) easily translated. I read your REST-api could do it. I was just - as an interested user - very interested how this works.
The data as described in my original question will be eventually used in a HTML / PHP page, that's the goal. Anyway, generating such data server side will also be fine, so we can use it in our pages. Any info about this would be more than welcome. Thanks in advance.
__________________
5.3.1.3 |
|||||||
#4
|
|||||||||
|
|||||||||
Re: How to generate a product catalog to embed on any (non-X-Cart) page?
I thought of rendering embedded catalog pages exactly the same way that they appear on the X-Cart-based site.
But if JSON information about products works for you (and you render the catalog with your own templates), REST API may be a solution. Although REST API doesn't provide the full access to the source code, it is a mediator between third-party applications and the X-Cart database. With the API you can query database records. Every API call matches to a method in the Model\Repo\* class that handles that database table. So, if you "search" for products, it looks for "search" method in the repository class for Product model and runs it with the parameters you pass in your API call - this way you can filter products returned by the query.
__________________
Alex Solovev, Qualiteam --- User manual Video tutorials X-Cart FAQ You are welcome to press "Thanks" button if you find this post useful Click here to learn how to apply patches X-Cart Extensions |
|||||||||
|
|||
X-Cart forums © 2001-2020
|