View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0005121 | OXID eShop (all versions) | 3.2. HTML, CSS, JavaScript | public | 2013-05-22 10:48 | 2014-02-20 10:35 |
Reporter | Arunas | Assigned To | |||
Priority | normal | Severity | minor | Reproducibility | always |
Status | resolved | Resolution | no change required | ||
Product Version | 4.7.5 / 5.0.5 | ||||
Summary | 0005121: When using "oxid_include_widget" inside an AJAX template, it messes up the content received from the widget | ||||
Description | When using "oxid_include_widget" inside a smarty template that's used inside an AJAX response, the content that is received from the widget is in JSON format and messes up the page. | ||||
Steps To Reproduce | 1. Create a simple widget that returns a template with some simple content 2. Include the widget via the "oxid_include_widget" function inside the "page\details\inc\productmain.tpl" template 3. Go to the details page of a product that has MD variants 4. Select a variant to partialy reload the page (via AJAX) The part where the widget was included now shows something like {errors:[], content: "BLA BLA BLA"} | ||||
Tags | No tags attached. | ||||
Attached Files | |||||
Theme | Azure | ||||
Browser | Google Chrome | ||||
PHP Version | 5.3 | ||||
Database Version | 5.5 | ||||
related to | 0006229 | closed | When "oxid_include_widget" is used in a template for an AJAX response it returns JSON instead of HTML |
|
To fix this fastly just use the old include-function like: [{include file="tplname" ...}]. This works fine. We canĀ“t see an advantage in this new oxid_include_sidget-construct. |
|
This is becoming a bigger problem with changes in version 5.1 where details page is outsourced from details controller into articledetails widget. We use some kind of "quick shop" overlay in productlist which reloads via ajax on variant selection. This results in the same messed up content. A backup to old include function like speckhardt suggests is not possible because of the missing functions in the details controller. Is there any planned solution to this? |
|
You can write a module that extends oxwidgetcontrol not to use json, i attached one. |
|
I think in fact this fix is not needed in details because details are no longer loaded with json but via widget.php in html. |
|
As already leofonic mentioned, we do not use json in details page, now we reload the widget. I closed this issue. If you think it is still valid, please, reopen and provide more details. |