Guest Posted May 3, 2013 Posted May 3, 2013 When i try to edit my main text on my website it throws up Parse error: syntax error, unexpected T_STRING in /home/chelm750/public_html/onlinemeatdelivery.com/admin/modules.php(232) : eval()'d code on line 2 and my text doesn't appear for me to edit it, what is clear is when i edited last i made some error with the code which has played havoc when i try to edit it again in the admin area. so where can i locate this bit of text that i have previously edited? website is www.onlinemeatdelivery.com thanks in advance!
MrPhil Posted May 3, 2013 Posted May 3, 2013 The first thing to check somewhere in the file is whether you have a ' in the middle of the text that you failed to "escape": don't should be don\'t. Make sure that the ' at each end of your text is that exact character, and not some Smart Quotes crud cut and pasted in from Word. In general: define ('TERM_NAME','your text goes here, don\'t forget to escape apostrophes.'); If you're using File Manager from osC 2.2, get rid of it faster than a radioactive potato. Use a real text editor instead. It (and the Define Language facility) are terrible security holes. If you still have them, you probably still have million other security problems.
Guest Posted May 3, 2013 Posted May 3, 2013 Yes that would be the problem, but i can't change it, please tell me where to manuallly change it?
MrPhil Posted May 4, 2013 Posted May 4, 2013 How are you editing? You should FTP the file to your PC, use a good editor such as ViM or Notepad++ to edit it, and FTP back up to the server.
Guest Posted May 4, 2013 Posted May 4, 2013 yes i'm using ftp and just notepad atm but thats because no dw on here, what i need to know is where the file that contains this text is? i changed it using the admin end, but no it won't because i put a ' in the text when i was editing it. so where has it saved this text i inputted? where does the index.php or what ever bit of php it is call to bring this text up? I can't find it.
♥joli1811 Posted May 4, 2013 Posted May 4, 2013 Hi Carl, Try looking in catalog/includes/languages/english/index.php define('TEXT_MAIN', '????????'); regards Joli To improve is to change; to be perfect is to change often.
MrPhil Posted May 4, 2013 Posted May 4, 2013 You should have a copy of your site FTP'd on to your PC, as a backup if nothing else. Learn to use tools like findstr (Windows) or grep (Linux, available for Windows) to search multiple files for certain strings: findstr /si /c:"Welcome to Hughe" \*.php just notepad atm but thats because no dw on here Don't even think of using DW (or EW, or Word) or anything but a real text editor to edit your PHP files. You'll ruin the files. Two very popular (and free) editors are Notepad++ and ViM. Notepad is OK for very small jobs, but you'll get tired of it on large files.
Recommended Posts
Archived
This topic is now archived and is closed to further replies.