Simple Machines Community Forum

SMF Support => SMF 2.0.x Support => Topic started by: popabawa on December 22, 2011, 02:00:36 PM

Title: Warning: Unexpected character in input
Post by: popabawa on December 22, 2011, 02:00:36 PM
Hi, completely out of the blue I'm getting the following error;

Quote
Warning: Unexpected character in input: ''' (ASCII=39) state=1 in /home/legendsr/public_html/forum/cache/data_07bd7a22f0250471f5e7bd63d427aa6e-SMF-modSettings.php on line 1

Parse error: syntax error, unexpected ':' in /home/legendsr/public_html/forum/cache/data_07bd7a22f0250471f5e7bd63d427aa6e-SMF-modSettings.php on line 1

I've read the other posts on this error which suggest deleting the cache. I've done that but the error persists.... I'm a bit confused as to why its throwing an error on a file that doesn't exist any more?

Any help gratefully received!
Title: Re: Warning: Unexpected character in input
Post by: Sir Osis of Liver on December 22, 2011, 02:10:35 PM

If you've emptied the file cache in Admin -> Forum Maintenance, clear your browser cache and force a reload (Ctrl + F5).

Title: Re: Warning: Unexpected character in input
Post by: popabawa on December 22, 2011, 02:16:28 PM
Hi, I can't get to anything on the forum, all I get is the above error.

I deleted the cache via FTP, maybe that wasn't the right thing to do?

I've tried clearing the browser cache and the error persists,
Title: Re: Warning: Unexpected character in input
Post by: popabawa on December 23, 2011, 12:24:26 PM
Sorry for the *BUMP*, can anyone help?
Title: Re: Warning: Unexpected character in input
Post by: Illori on December 23, 2011, 12:29:40 PM
popabawa please do not bump within 24 hours we are all volunteers and reply if and when we know the answer
Title: Re: Warning: Unexpected character in input
Post by: Oldiesmann on December 23, 2011, 02:02:04 PM
Browse to your forum directory in Filezilla, then delete everything in the "cache" folder. That should fix your issue.
Title: Re: Warning: Unexpected character in input
Post by: Sir Osis of Liver on December 23, 2011, 09:47:02 PM
I deleted the cache via FTP, maybe that wasn't the right thing to do?

Did you delete the cache folder, or just the contents?

Title: Re: Warning: Unexpected character in input
Post by: popabawa on December 24, 2011, 04:06:41 AM
Apologies for the premature bump  :-[

I deleted all the files in the cache folder via FTP. As that seemed to have no effect I then deleted the whole folder, also no effect.

Thanks for the help guys, I appreciate it.
Title: Re: Warning: Unexpected character in input
Post by: Kays on December 24, 2011, 09:03:41 AM
Hi, I'm suspecting the file is being recreated. If it is, could you please attach a copy of it to a post.

If you have phpMySQL access, search the settings table for "cache_enable" and change that value to 0. That should give you access to your forums. You might need to delete that file again.
Title: Re: Warning: Unexpected character in input
Post by: popabawa on December 24, 2011, 10:16:24 AM
Thanks Kay's.

The cache folder is completely empty (via FTP) so I don't think it is being recreated.

I'm not sure if i  have phpMySQL access, I'll check it out and report back!
Title: Re: Warning: Unexpected character in input
Post by: Illori on December 24, 2011, 10:21:36 AM
your host should provide phpmyadmin access or similar, if they dont you can install it
Title: Re: Warning: Unexpected character in input
Post by: Kays on December 24, 2011, 10:38:01 AM
If it's empty, you shouldn't be getting that error as it looks for the files in there if caching is enabled. (level 1).

Have you treid refreshing your browser?

Have you got a link to your forum?
Title: Re: Warning: Unexpected character in input
Post by: popabawa on December 25, 2011, 03:45:29 AM
Yes, it seems really odd it's throwing an error on a file that doesn't exist any more but I have refreshed the browser and cleared out its cache...

Link to the forum - http://www.legendsracing.net/forum

Title: Re: Warning: Unexpected character in input
Post by: Skhilled on December 25, 2011, 05:45:49 AM
It may not be that the the error is because the file does not exist but because a mod left code behind somewhere that is looking for it. Look for code in your SMF files from mods that you've recently uninstalled.
Title: Re: Warning: Unexpected character in input
Post by: Kays on December 25, 2011, 12:00:35 PM
Did you install a mod just previous to this problem happening?

Do you have phpMyAdimin or some other form of database access. Do try to disable caching directly in the database first.

If not, backup your sources folder. Then download the large upgrade package and unzip it. First try uploading some of the basic files, load.php, subs.php, boardIndex.php. If that don't help then just upload the rest of them. But do back the files in that folder first so you can revert in that's not the problem.
Title: Re: Warning: Unexpected character in input
Post by: popabawa on December 26, 2011, 03:34:25 AM
Ah... I did uninstall a mod just before the error, that makes sense! Thanks!

Look for code in your SMF files from mods that you've recently uninstalled.

I'm not sure what I'm looking for (or where)  that's causing the issue....
Title: Re: Warning: Unexpected character in input
Post by: popabawa on December 26, 2011, 08:35:12 AM
Ok... quick update, I disabled caching in the database via phpMyAdmin but it didn't change anything, same error.
Title: Re: Warning: Unexpected character in input
Post by: Kays on December 26, 2011, 10:18:31 AM
Do you remember which mod it was that you installled?

I guess the next step is to try replacing the files as I described previously.
Title: Re: Warning: Unexpected character in input
Post by: popabawa on December 26, 2011, 10:29:01 AM
Thanks Kays, yes, it was 'nneonneo's Shoutbox'; http://custom.simplemachines.org/mods/index.php?mod=585

It's the only mod I had installed.

Just so I'm clear, do I  replace the files in the 'Sources' folder? (after backing up)
Title: Re: Warning: Unexpected character in input
Post by: Kays on December 26, 2011, 10:43:31 AM
Yes. If the problem is a file then the most likely ones are those in the Sources folder.
Title: Re: Warning: Unexpected character in input
Post by: popabawa on December 26, 2011, 10:54:52 AM
Wahoo!!! I replaced those 3 files and I'm back up and running!

Thanks Kays, I really appreciate the help :)
Title: Re: Warning: Unexpected character in input
Post by: Kays on December 26, 2011, 11:13:51 AM
Cool. :)

Can you figure out which one was giving the problem and attach it to a post. I'd like to have a look at it.