Magento Forum

   
WYSIWYG “media url=” images not displaying in back end
 
broesch
Jr. Member
 
Total Posts:  11
Joined:  2012-04-23
 

We’re running Magento ver. 1.7.0.0. In the CMS, when an image is added via “Show Editor” > “Insert Image...”, the image shows up as broken on the back end. Saving the page and loading it on the front end reveals a working image.

Here is a sample line of code generated in this way:

<img src="{{media url="wysiwyg/pages/perfect-fit/align-center-notch.png"}}" alt="" />

 
Magento Community Magento Community
Magento Community
Magento Community
 
broesch
Jr. Member
 
Total Posts:  11
Joined:  2012-04-23
 

This showed up nicely in the logs:

Warninggetimagesize(http://example.com/media/wysiwyg/path/to/image.jpg): http:// wrapper is disabled in the server configuration by allow_url_fopen=0  in /full/path/to/webroot/lib/Varien/Image/Adapter/Abstract.php on line 87
It seems entirely unnecessary ( wrong? ) to me that this method would be called on an external URL rather than the file path itself. I’d rather not hack Magento core. What would be a good solution to this problem?

 
Magento Community Magento Community
Magento Community
Magento Community
 
charismeky
Jr. Member
 
Total Posts:  9
Joined:  2011-03-29
 

same here. any solutions for that issue? thx, c--

 
Magento Community Magento Community
Magento Community
Magento Community
 
broesch
Jr. Member
 
Total Posts:  11
Joined:  2012-04-23
 

I did some more digging around to no avail. We have a dev site and a production site, so ultimately, since our client is familiar enough with HTML, we just left it with broken images in the editor and refreshed the page on the front end. The other styles are missing in the editor, anyway.

At some point I would like to go back and find a real solution, though. Let me know if you find anything.

 
Magento Community Magento Community
Magento Community
Magento Community
 
elfling
Enthusiast
 
Avatar
Total Posts:  899
Joined:  2008-10-21
 

Fopen is disabled on the server. You will need to switch it on in order to view the images in the wysiwyg

 
Magento Community Magento Community
Magento Community
Magento Community
 
broesch
Jr. Member
 
Total Posts:  11
Joined:  2012-04-23
 

In our PHP config, fopen is enabled, but allowing it to open remote URLs is not acceptable. The way the core code is calling it uses the web path rather than the file path… ? I think I’m going to have to wait until this is changed in the core code.

 
Magento Community Magento Community
Magento Community
Magento Community
Magento Community
Magento Community
    Back to top