Jump to content

Administration language files keep 'disappearing'


Guest andrewdc

Recommended Posts

Guest andrewdc

Hi,

While developing on a version of CubeCart (v4.0.2), I've noticed that in the administration, the menu seems to random disappear - along with the text for the "Edit" and "Delete" buttons when I'm editing or deleting a category.

I've applied a so-called fix for the getLang() function, which has proven unsuccessful.

Does anyone else know of a fix for this? It's becoming rather annoying.

If you need to know anything else, please ask and I'll try to give you a good reply!

Regards,

Andrew.

Link to comment
Share on other sites

Guest andrewdc

A quick update... I've decided to stick a var_dump($langCache); at the bottom of the getLang() function (just above the return;), when I'm deleting categories, I seem to rather randomly get a bool(false); from the language function, I assume this is for the $lang['admin_common'] array (or admin_common.inc.php language file).

$langCache = unserialize($result[0]['langArray']);




Update After a bit more digging, I've found it's that variable returning the false, I assume this means it's something to do with the database?



The other thing that's strange, is I don't think the database entry is corrupt; because sometimes the language file/data will be loading appropriately and other times it simply does not.



Update (again) It appears that the data is being retrieved from the database, however the unserialize() function is returning the false; statement.



Update (again, again) I'm now getting the following error: 




Notice: unserialize() [function.unserialize]: Error at offset 1841 of 6403 bytes in /var/www/vhosts/xxxxx/httpdocs/xxxxx/includes/functions.inc.php on line 796

That's happening randomly, the same $identifier[1] is being returned regardless of which page(s) I go too, so I doubt there is really an error at byte 1841, otherwise the other pages would be language-less.

Any thoughts anyone? ;)

Link to comment
Share on other sites

Guest andrewdc

Fixed it :)

The s:55; in the database was incorrect for the serialized string (the part changed was the welcome_note bit); I've changed that now and it works, turns out CubeCart had it set to one byte larger than it should of been. ;)

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...