Jump to content

Store Name Changed


infam1

Recommended Posts

The Store Name is entered in Store Settings, General tab, and is then saved in the entire group of configuration settings.

 

The store configuration settings is one large array. When saving this array to the database, it is json_encoded, then base64_encoded. The resultant (very long) string will look like:

eyJzdG9yZ.... lots more.

 

This string is saved in the database table CubeCart_config, in a record where the 'name' column is "config".

 

When CubeCart is waking up, one of the first things it does is to fetch this string from the database, base64_decode it, then json_decode it. The resulting array can be accessed with, for example:

$GLOBALS['config']->get('config', "store_name");

Link to comment
Share on other sites

Okay so when I installed a fresh version of CC that plugged into my old database and got into the admin the store name had changed. Would putting the string from my backup database into the database now bring back the old settings?

Link to comment
Share on other sites

It would. Probably. Connecting a store to an existing database should work fine (actually, there are a few exceptions to this).

 

It remains a mystery why only the Store Name - and not the entire configuration array - would be what did not get used.

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...