lang-en.php syntax error - complete disaster, please help :(

So I was editing the lang-en.php file "terms of use" section - just simply pasting text inbetween all the <p> tags, but when I went to view the changes on my website I got nothing but this:

Parse error: syntax error, unexpected T_STRING, expecting ')' in /home/theferal/public_html/langs/lang-en.php on line 649

I checked back carefully over what I did and can't for the absolute life of me find where the error is - I was being so careful!

Line 649 shows me this (when viewed in Notepad): <p>&nbsp;</p>

After having a massive freak-out (which has now subsided to a small and constant panic attack!) I decided to reupload the original lang-en.php file (overwriting the existing one which I have somehow managed to stuff up).

It didn't work.

I thought maybe I needed to clean the cache, but I can't access the Dolphin admin panel, because all I see is the above error.

PLEASE, is there anyone who has a solution on how to fix this?

Quote · 15 Mar 2011

The lang-en.php in the langs folder is not suppose to be edited. Your suppose to edit language keys from within the languages section in admin. That lang-en.php gets regenerated everytime the languages are recompiled.

You can manually clear the cache by emptying the contents of the folders cache, cache_public via FTP or in cpanals file manager.


https://www.deanbassett.com
Quote · 15 Mar 2011

Clean out your cache.

Upload the original lang file.

Recompile it. (Settings > Language Settings - Check it and Compile.  May not need to but if all else fails)

Then search for the Key: _TERMS_OF_USE

Edit it there.

Quote · 15 Mar 2011

Oh, and when you upload the origional lang-en.php file, the permissions on it must be set to writable.


https://www.deanbassett.com
Quote · 15 Mar 2011

Thanks for the response - I did as you both suggested, but it didn't work.

Good grief, what have I done!

Will I have to completely re-install this thing?

Quote · 15 Mar 2011

Go to Winmerge.org and download a copy of the program.  This will allow you to compare the messed up version of your site with a fresh install version.  It will point out changes in each file.  You will be able to see exactly where the ) needs to go.

 

It only takes a few minutes to find the error.

 

Check the lang file first and compare it with an original.  Then check the rest of the site.

Quote · 15 Mar 2011

 

Go to Winmerge.org and download a copy of the program.  This will allow you to compare the messed up version of your site with a fresh install version.  It will point out changes in each file.  You will be able to see exactly where the ) needs to go.

 

It only takes a few minutes to find the error.

 

Check the lang file first and compare it with an original.  Then check the rest of the site.

Ok, did that - but the lang file is the original one I re-uploaded after I cleaned the cache and set writable permissions.  The original one is now, somehow, a messed up one even though I haven't changed it in any way.  Also, when I compared them, one was a .php file and the other was an .htaccess file which didn't really compare with each other.

Should I take myself out in a paddock and shoot myself now or, what?

Quote · 15 Mar 2011

Well, wait a couple more minutes before doing that.

 

Of course the .htaccess is not the same file as the lang file.  The way Winmerge works is you open two versions of the same file and compare them.

So, since you have uploaded an original lang file do the following:

1. Download your live site into a folder called screwed.

2. Download a fresh version of Dolphin.

3. Open Winmerge and start a new compare by opening the Screwed folder.  Then open the new Dolphin folder.  The program will compare files and show you where changes have been made.  It will pinpoint where you are lacking a ).

So your administration folder is being compared with administration folder, etc., etc.

Quote · 15 Mar 2011

Have you any ideas how to download a live version of my site? Every time I try with my ftp program it just hangs forever.

Quote · 15 Mar 2011

The same way it went up is the way you get it back down.

 

However, you must have a local copy that you've been editing.  Compare the one you've been working on with the new version.

Quote · 15 Mar 2011

 

The same way it went up is the way you get it back down.

 

However, you must have a local copy that you've been editing.  Compare the one you've been working on with the new version.

Terabyte Hosting installed it and I had just been going into the CPanel to make edits...because of my stupid ftp client.

Maybe time to shoot myself now? Undecided

Quote · 15 Mar 2011

Ok, in that case use nerf bullets because you are just needing a few good tools.  Download Filezilla.

This will get your site down quick and easy.  Then run the compare.

Quote · 15 Mar 2011

In case you are not familiar with using FTP your hosting company should be able to help you with the FTP setup but a typical setup would look like this:

In filezilla go to File - Site manager - New Site

Server type: Ftp

Logon type: Normal

User: your hosting account username

password: hosting account password

Click Connect

Go to public_html

Left panel is local computer, right panel is server.

Download right side to left side.  Create a folder for your download.

Quote · 15 Mar 2011

 

In case you are not familiar with using FTP your hosting company should be able to help you with the FTP setup but a typical setup would look like this:

In filezilla go to File - Site manager - New Site

Server type: Ftp

Logon type: Normal

User: your hosting account username

password: hosting account password

Click Connect

Go to public_html

Left panel is local computer, right panel is server.

Download right side to left side.  Create a folder for your download.

Yeah, that's no problem - I'm in the middle of doing it now, thanks!  Fingers crossed......

Quote · 15 Mar 2011

or you could have opened phpmyadmin  and searched for _TERMS_OF_USE in the sys_localization_keys table  then match the ID to the sys_localization strings table   then pasted this in: SEE ATTACHED FILES

 Then clear your cache folder .... and try and refresh the site.

TERMS_OF_USE.txt · 17.2K · 162 downloads
langs.wmv · 4.3M · 65 downloads
https://dolphin-techs.com - Skype: Dolphin Techs
Quote · 15 Mar 2011

Thanks dolphin_jay.

Thankfully, PravoNetwork's advice saw me through to a successful solution - even if it did take hours and a multitude of panic attacks inbetween!!

Thanks again, everyone - it's so nice to have such a fabulous, supportive place to come to for such awesome advice!!

Smile

Quote · 15 Mar 2011
 
 
Below is the legacy version of the Boonex site, maintained for Dolphin.Pro 7.x support.
The new Dolphin solution is powered by UNA Community Management System.