prestamax Posted March 19, 2014 Share Posted March 19, 2014 I have uploaded an image via editor for a cms page. The image is is uploaded and I can see it in the folder /img/cms/. But the image won't show up even though the path is correct. There is a .htaccess file in the folder img/cms/ containing the line php_flag engine off If I delete the .htaccess file the image shows up correctly. What it the command php_flag engine off for and is it save to delete the .htaccess file? Link to comment Share on other sites More sharing options...
Bruno Leveque Posted March 19, 2014 Share Posted March 19, 2014 Hey, Thank you for your feedback, please do not remove this file, it's actually here to improve security. This .htaccess directive is here to prevent anyone from running a PHP script in that folder. However after researching, it appears that it may generate some sides effects. Please can you try to replace the content of this .htaccess by the following: <IfModule mod_php5.c> # Turn the PHP engine off php_flag engine off </IfModule> Let us know if this helps, else we will be glad to assist you. It would also be interesting to know which hosting provider you have. Regards, 6 Link to comment Share on other sites More sharing options...
prestamax Posted March 19, 2014 Author Share Posted March 19, 2014 (edited) Thank you for your response and the code. I have inserted the suggested code in the .htaccess file and now the image appears with .htaccess file in the folder. The site is on an own root server with Hetzner. The server is running with PHP Version 5.4.9-4ubuntu2.3. Could it be that the reason for the error was that PHP is running as CGI? Edited March 19, 2014 by prestamax (see edit history) 1 Link to comment Share on other sites More sharing options...
Dougadanny Posted March 21, 2014 Share Posted March 21, 2014 Hi Bruno, This worked for me. However, I noticed that the GUI for the insert image no longer has ability to change float left right or add margins, had to add this manually to code. 1 Link to comment Share on other sites More sharing options...
elenaba Posted March 24, 2014 Share Posted March 24, 2014 Hi this works also for me !!! thanks PS 1.6.0.5 1 Link to comment Share on other sites More sharing options...
tmk Posted April 24, 2014 Share Posted April 24, 2014 (edited) This works also for me in case of displaying images but I observed another issue: Depending on browser kind and version thumbnail images in file manager are displaying correctly or not. I discover that in some browsers images are not displaying because path to thumbnail images is changing from img/tmp/cms/ to youradminfoldername/img/tmp/cms/ which of course not exist by "youradminfoldername" I mean admin folder name to login to BO presta 1.6.0.5 example browsers: Opera 12.12 - images displaying correctly (path to thumb: img/tmp/cms/) Firefox 12.0 - images not displaying (path to thumb: youradminfoldername/img/tmp/cms/) Any idea what could be the reason? Edited April 24, 2014 by tmk (see edit history) 1 Link to comment Share on other sites More sharing options...
soniar4i Posted June 16, 2014 Share Posted June 16, 2014 This works also for me in case of displaying images but I observed another issue: Depending on browser kind and version thumbnail images in file manager are displaying correctly or not. I discover that in some browsers images are not displaying because path to thumbnail images is changing from img/tmp/cms/ to youradminfoldername/img/tmp/cms/ which of course not exist by "youradminfoldername" I mean admin folder name to login to BO presta 1.6.0.5 example browsers: Opera 12.12 - images displaying correctly (path to thumb: img/tmp/cms/) Firefox 12.0 - images not displaying (path to thumb: youradminfoldername/img/tmp/cms/) Any idea what could be the reason? I have the same issue now, in Chrome works perfectly, but in Safari it adds /youradminfoldername/ to my path. 1 Link to comment Share on other sites More sharing options...
mir-aus Posted September 3, 2014 Share Posted September 3, 2014 Hey, Thank you for your feedback, please do not remove this file, it's actually here to improve security. This .htaccess directive is here to prevent anyone from running a PHP script in that folder. However after researching, it appears that it may generate some sides effects. Please can you try to replace the content of this .htaccess by the following: <IfModule mod_php5.c> # Turn the PHP engine off php_flag engine off </IfModule> Let us know if this helps, else we will be glad to assist you. It would also be interesting to know which hosting provider you have. Regards, Hi, Still I have a same problem, any way I can fix it please.? Link to comment Share on other sites More sharing options...
p4t0X Posted September 5, 2014 Share Posted September 5, 2014 (edited) Hi, Still I have a same problem, any way I can fix it please.? http://tinyurl.com/l3a36bk See if helps! []'s Diego Edited September 6, 2014 by p4t0X (see edit history) Link to comment Share on other sites More sharing options...
w3bsolutions Posted September 27, 2014 Share Posted September 27, 2014 I have the same issue now, in Chrome works perfectly, but in Safari it adds /youradminfoldername/ to my path. I am having this issue too, has anyone managed to solve it? Link to comment Share on other sites More sharing options...
nicholast10 Posted October 10, 2014 Share Posted October 10, 2014 hi. i have a similar problem but with some computers only. on some computers i can upload image without any problem but on some other computers, i get error as attached file. why is this? Link to comment Share on other sites More sharing options...
Rahul Soni Posted February 19, 2015 Share Posted February 19, 2015 thanks, my problm solved too. Link to comment Share on other sites More sharing options...
eleit Posted February 21, 2015 Share Posted February 21, 2015 hello, I have the same problem - the images are not shown... in all browsers I tried to change the code in htaccess.. but the problem persists.. COuld you please advice how to resolve? Thanks Hey, Thank you for your feedback, please do not remove this file, it's actually here to improve security. This .htaccess directive is here to prevent anyone from running a PHP script in that folder. However after researching, it appears that it may generate some sides effects. Please can you try to replace the content of this .htaccess by the following: <IfModule mod_php5.c> # Turn the PHP engine off php_flag engine off </IfModule> Let us know if this helps, else we will be glad to assist you. It would also be interesting to know which hosting provider you have. Regards, hello, I have the same problem - the images are not shown... in all browsers I tried to change the code in htaccess.. but the problem persists.. COuld you please advice how to resolve? Thanks Link to comment Share on other sites More sharing options...
eleit Posted February 21, 2015 Share Posted February 21, 2015 hello, I have the same problem - the images are not shown... in all browsers I tried to change the code in htaccess.. but the problem persists.. COuld you please advice how to resolve? Thanks hello, I have the same problem - the images are not shown... in all browsers I tried to change the code in htaccess.. but the problem persists.. COuld you please advice how to resolve? Thanks I see that the path to the image is not correct. Prestashop insert also the language (es.sitename/en/content).. how can I make in order the path becom correct? somebody knows? Link to comment Share on other sites More sharing options...
Recommended Posts