Showing similar products through AJAX

Employer
[no-member:pro]Rabotodatel[/no-member:pro]Rabotodatel
Project parameters
Type of cooperationPeriodic employment
SectionWeb development
Prepaymentwithout prepayment
Payment methodsElectronic money
Acceptance of requestsclosed
Project description
I need advice on where to put it on the site.
This section can be added to any page of the store (or any site at all). The data is obtained using AJAX technology.
The following steps must be taken to implement:
1. On the landing page, add a block to the place where products with similar designs should be displayed. Assign an identifier to this block (e.g., 'related_products')
2. On the landing page add a script that will receive on AJAX object.
$.ajax({{{}}
Url: + productId,
Type: 'GET,'
DataType: 'json',
Success: function (data) {
* render code here *
?
}
In the variable productId, you need to transfer the article of the product for which you want to get similar designs (for example, 711385 for the layout of the productId, you need to transfer the article of the product for which you want to get similar designs (for example, 711385 for the layout of the product / black and white).
3. Instead of * render code here *, you need to enter a script that will sort through all the objects in the resulting array and render them in HTML.
This section can be added to any page of the store (or any site at all). The data is obtained using AJAX technology.
The following steps must be taken to implement:
1. On the landing page, add a block to the place where products with similar designs should be displayed. Assign an identifier to this block (e.g., 'related_products')
2. On the landing page add a script that will receive on AJAX object.
$.ajax({{{}}
Url: + productId,
Type: 'GET,'
DataType: 'json',
Success: function (data) {
* render code here *
?
}
In the variable productId, you need to transfer the article of the product for which you want to get similar designs (for example, 711385 for the layout of the productId, you need to transfer the article of the product for which you want to get similar designs (for example, 711385 for the layout of the product / black and white).
3. Instead of * render code here *, you need to enter a script that will sort through all the objects in the resulting array and render them in HTML.