0
votes

Broken Links from wysiwyg on frontend of Magento store. Am unsure what has caused this but they were working previously.

My Urls created from Wysiwyg seem to be fine within admin and are only broken on category and product pages however they still seem to be working on CMS Pages.

The URL's on broken pages are not like below with broken shortcodes:

Admin -

    <img src="{{media url="wysiwyg/image.png"}}" alt="image" />

Frontend -

    <img src="{{media url=" wysiwyg="" image.png"}}"="" alt="image">

These img tags have been inserted into different attributes within admin of Magento where wysywig has been used for adding images.

On the product view page there are sometimes the {{media url=""}} pulled from the description attribute in products. On category view pages they also sometimes appear in description attribute of categories. I think its just going into the description block but my templates are modified from default.

2

2 Answers

0
votes

There is a issue with quotes. You should use this code.

<img src="{{media url='wysiwyg/image.png'}}" alt="image" />

Now you can use below code to get proper image output.

<?php
    echo $this->helper('cms')->getBlockTemplateProcessor()->filter($this->helper('catalog/output')->productAttribute($_product,nl2br($_product->getShortDescription()), 'short_description'));
 ?>

Hope this code helps you!!!

0
votes

This is possibly caused by the new security permissions added with security patch 6788 or from upgrading to 1.9.2.2+

Solution might be to add the variable to the permissions list in

System -> Permissions -> Variables.