NeilD Posted May 23, 2011 Share Posted May 23, 2011 Not sure what I've done wrong here but for some reason I cant upload images using the upload/edit image function on CMS pages. Just to be clear I'm not talking about the images for products, they seem to be uploading just fine. I updated to 1.4.1 in the hopes it would clear the problem but to no avail.On my local installs of Prestashop (both 1.4.1 and 1.4.0.17) I have no issues and can upload as Tinymce intended on firefox and safari, but now that I've put the site up on a server I'm having problems. I've changed the permissions on the folder to 775 and then later to 777. Heres what i do:Click insert/edit image-> brings up popup -> Click browse from popup - > brings up second popup -> click upload -> brings 3rd popup -> click browse -> find the file on my desktop -> click upload. this is as far as i can get on my webserver.I've tested it on serveral platforms: On the Mac: Firefox4 i get to the last click upload but then get an error message reading " SyntaxError: missing ; before statement"On the Mac Safari 5.0.3 is exactly the same all the way to upload but the error message reads "SyntaxError: Parse error" On the PC: IE8 The "Insert/edit image" button has no effect whatsoever. Also if i right click to bring the menu up it appears in the top right corner of the browser and equally has no effect. Chrome 11.0.696.68 brings up a nearly blank screen with " Not Found the requested URL/admin/ajaxfilemanager/login.php was not found on this server. additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request.instead of the second popup.The file "ajax_login.php" is where it should be i have no idea why its looking for login.php? Its a real pain the main reason i moved to prestashop from zencart was so i could upload images to non product pages. Its probably a simple problem but any help would be appreciated, so thanks in advanceNeil 2 Link to comment Share on other sites More sharing options...
NeilD Posted May 24, 2011 Author Share Posted May 24, 2011 51 views so far and no one has an idea? Com'on people one of you bright sparks must have some clues to share with me. Just take a stab in the dark! Link to comment Share on other sites More sharing options...
NeilD Posted May 24, 2011 Author Share Posted May 24, 2011 Getting: Not Foundthe requested URL/admin/ajaxfilemanager/login.php was not found on this server.additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the requestin Firefox 4 and safari now.the button still has no effect in IE8 Link to comment Share on other sites More sharing options...
korrona Posted May 26, 2011 Share Posted May 26, 2011 Same problem here! It appeared out of nowhere. It worked fine at the office, but now, working from home this was thrown at me.Any hints? Link to comment Share on other sites More sharing options...
NeilD Posted May 26, 2011 Author Share Posted May 26, 2011 I've explored every avenue i can think of. I've even reposted this on the TinyMCE forum. so far nothing but i will post an answer as soon as i have one Link to comment Share on other sites More sharing options...
korrona Posted May 26, 2011 Share Posted May 26, 2011 Thanks for the answer. I have seen your post on the other forum as well.But! Behold! at the office works very well. Hmmmmmmm! I would love to make this thing clear because I would love to manage the system from any place in the world. Link to comment Share on other sites More sharing options...
korrona Posted May 28, 2011 Share Posted May 28, 2011 It is definitely an issue as I cannot do it from home. Hmmmm... Have you got any clues so far?It is in the works here:http://forge.prestashop.com/browse/PSCFI-1127?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanelA little update:It seems it likes the Firefox 4.0.1 on Windows7.this gets puzzling by the move... Link to comment Share on other sites More sharing options...
NeilD Posted May 28, 2011 Author Share Posted May 28, 2011 Thanks for the update, I think ill ask a friend to see if he can login with his windows 7 machine. I only really kept a pc around for testing purposes so I'm still running on XP. I'll also go round and install the main browsers and see if i have any luck with any of them, Ill keep you posted. Cheers Link to comment Share on other sites More sharing options...
korrona Posted May 28, 2011 Share Posted May 28, 2011 Changing the browser done me good as it magically solved the issue. So, when I need off I go from Chrome to Opera (Mac OSX) and get the job done.Hmmmm... it's a browser issue! Link to comment Share on other sites More sharing options...
NeilD Posted May 31, 2011 Author Share Posted May 31, 2011 Hi korrona, Thanks for the pointer I installed Opera and Chrome on the mac, and i get a little further than before.can't get much further but i do get all the way to the upload screen after choosing a file and hitting upload i get" SyntaxError: Unexpected token < " in Chrome and " SyntaxError: at line 2, column 0: expected expression, got '<' "in operaI wonder which file its talking about if i could find the < then there's a chance i could edit the code to work somehow. I've yet to hear back from my windows 7 using friend.... Sigh back to square one for me. Link to comment Share on other sites More sharing options...
NeilD Posted June 25, 2011 Author Share Posted June 25, 2011 I may have found a lucky break. I found this post on another forum:http://stackoverflow.com/questions/1359476/tinymce-file-upload-generic-syntax-errorIt seems that many TinyMCE users are having the same issues, I have found posts in quite a few forums regarding the " SyntaxError: missing ; before statement " most were marked solved when someone added Our host had just added mod_security and recompiled Apache. They had to white list ajaxfilemanager to get it to work properly again. I have my own host looking into the issue now fingers crossed ill have a solution soon. ill keep you posted@Korrona - Dunno if this will help you since you seem to fine from your office computer. I had my friend check windows 7 for me but he gets the same errors as i do, so i suspect we have a different issue. Link to comment Share on other sites More sharing options...
pierrot10 Posted November 2, 2011 Share Posted November 2, 2011 Hello I just got the same problem I absolkutely does know why. I cleared my my recent history on Firefox and it went back tp the normal I hope it's all. Cheers Link to comment Share on other sites More sharing options...
mrazka Posted November 29, 2011 Share Posted November 29, 2011 Hello, i got same problem here syntax error when upload image. After tiring googling, the last solution contact your hosting provider and told then total disabled mod security. It working. Link to comment Share on other sites More sharing options...
NeilD Posted December 7, 2011 Author Share Posted December 7, 2011 in the end i just changed hosts since the one i had just deleted my ticket and ignored me new hosting company seems fine so far Link to comment Share on other sites More sharing options...
shellxie Posted February 24, 2012 Share Posted February 24, 2012 I encountered the same problem as I use IE. But when I use FireFox I can upload image well. I am trying to upload embedded media such as Windows Media by TinyMCE. Link to comment Share on other sites More sharing options...
cyberespia Posted August 3, 2012 Share Posted August 3, 2012 I have the same problem Link to comment Share on other sites More sharing options...
fogolin Posted August 5, 2012 Share Posted August 5, 2012 Seriosuly people? Nobody found anything on it yet? In Firefox I get: SyntaxError: missing ; before statement In Safari I get: SyntaxError: Unexpected token '<' In Chrome I get: SyntaxError: Unexpected token < In Internet Explorer (God forgive me!) I get: SyntaxError: Unexpected token If anyone found the solution, please post it here Link to comment Share on other sites More sharing options...
Bacardichile Posted October 26, 2012 Share Posted October 26, 2012 ????????????? Link to comment Share on other sites More sharing options...
flowersticky Posted November 1, 2012 Share Posted November 1, 2012 Please help....anyone? Link to comment Share on other sites More sharing options...
frederic42 Posted November 15, 2012 Share Posted November 15, 2012 Some hosting blocked function sleep() for security reason (safe_mode) You can comment line 13 of file ajax_file_upload.php //sleep(3) from folder "your_admin/ajaxfilemanager/" http://php.net/manual/en/function.sleep.php Link to comment Share on other sites More sharing options...
PSD-to-Template Posted November 20, 2012 Share Posted November 20, 2012 (edited) Seriosuly people? Nobody found anything on it yet? In Firefox I get: SyntaxError: missing ; before statement In Safari I get: SyntaxError: Unexpected token '<' In Chrome I get: SyntaxError: Unexpected token < In Internet Explorer (God forgive me!) I get: SyntaxError: Unexpected token If anyone found the solution, please post it here replace this line in ajax_file_upload.php (admin/ajaxfilemanager/) $manager = new manager($upload->getFilePath(), false); to: $manager = new manager(dirname($upload->getFilePath()), false); Edited November 20, 2012 by PSD-to-Template (see edit history) 1 Link to comment Share on other sites More sharing options...
dem4nk Posted November 26, 2012 Share Posted November 26, 2012 just clear a cookies and a cache on your browser 2 Link to comment Share on other sites More sharing options...
silentRun Posted July 24, 2013 Share Posted July 24, 2013 replace this line in ajax_file_upload.php (admin/ajaxfilemanager/) $manager = new manager($upload->getFilePath(), false); to: $manager = new manager(dirname($upload->getFilePath()), false); did as you say, but still I cant upload files through the tinymce, neither browse among the folders ... any idea ? Link to comment Share on other sites More sharing options...
thanos26 Posted July 25, 2013 Share Posted July 25, 2013 just clear a cookies and a cache on your browser I feel soooooo stupid! I tried all sorts of thing and the solution, for me at least, was as dem4nk descrbed. Thanks dem4nk! Link to comment Share on other sites More sharing options...
globosoftware.net Posted October 24, 2014 Share Posted October 24, 2014 just clear a cookies and a cache on your browser I have the same problem. Thank dem4nk, you solved my problem. Link to comment Share on other sites More sharing options...
Recommended Posts