Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Two shops, same database


Guest

Recommended Posts

Hi Community,

this topic has been posted several times but i could not find any useable answer.

 

We do need to run two shops with different designs and different logos & different 1st pages.

Thes shops share everything else, products, customers, prices... and should share the same database, to avoid duplicate maintenance.

 

I have made two installations in two directories and reused the database for the second shop.

 

The second shop shows up exactly like the first one, apparently using the index.php's and language files of the directories of the first shop.

 

That is a bit confusing, since apparently no reference to folders are stored in the database and everything else is referenced to the folders of the second shop. :huh:

 

Could anyone give me a start, or mention a thread about this subject that could help me?

 

Thank you

 

Michel

Link to comment
Share on other sites

Hi Community,

this topic has been posted several times but  i could not find any useable answer.

 

We do need to run two shops with different designs and different logos & different 1st pages.

Thes shops share everything else, products, customers, prices... and should share the same database, to avoid duplicate maintenance.

 

I have made two installations in two directories and reused the database for the second shop.

 

The second shop shows up exactly like the first one, apparently using the index.php's and language files of the directories of the first shop.

 

That is a bit confusing, since apparently no reference to folders are stored in the database and everything else is referenced to the folders of the second shop. :huh:

 

Could anyone give me a start, or mention a thread about this subject that could help me?

 

Thank you

 

Michel

 

If you have something like:

Shop 1:

/catalog/admin

/catalog...

 

Shop 2:

/catalog1/admin

/catalog1...

 

and have adapted both configure.php's in your Shop 2 it would say it should work on one and the same database. Maybe you didn't change the Shop's 2 configure.php's to the correct path's so they still refer to the Shop 1 catalog path ?

Link to comment
Share on other sites

Hi,

 

My aim is to have all stores sharing the same info. Seems to be a different approach.

 

That is what the contribution does, from memory, it allows you to use/share the same database, whilst having multiple stores.

 

Before I found out about the Multi-Stores contrib., I put 3 osCommerce domains on the one site, and I 'tweaked' the languages to force different content. Just a simple check on the domain name, and then set a number of constants and the language. In the end it was very messy, and I wish I had known about the contribution beforehand, ... oh well.

 

Peter

Link to comment
Share on other sites

If you have something like:

Shop 1:

/catalog/admin

/catalog...

 

Shop 2:

/catalog1/admin

/catalog1...

 

and have adapted both configure.php's in your Shop 2 it would say it should work on one and the same database. Maybe you didn't change the Shop's 2 configure.php's to the correct path's so they still refer to the Shop 1 catalog path ?

 

It seems to be something like this, the syntax is also a bit touchy isn't it?

 

I have found 3 lines where i replaced with the old path "catalog" with the new one "gab":

 

define('DIR_WS_HTTP_CATALOG', '/gab/');

define('DIR_WS_HTTPS_CATALOG', '/gab/');

 

the third one seems to be Harry Potter magic:

define('DIR_FS_CATALOG', '/u/web/schr1/gab/');

This content was preset by install, i have got no clue what "/u/web/schr1" means.

Maybe the hitch is located there?

 

I made a try with

define('DIR_FS_CATALOG', '/gab/');

it gave me the same result

and made another attemp with

define('DIR_FS_CATALOG', 'gab/');

and the it could not get the .css I suppose

 

It really seems to be a matter of just getting the correct syntax, isn't it?

 

Thanks for your help

Link to comment
Share on other sites

It seems to be something like this, the syntax is also a bit touchy isn't it?

 

I have  found 3 lines where i replaced with the old  path "catalog" with the new one "gab":

 

  define('DIR_WS_HTTP_CATALOG', '/gab/');

  define('DIR_WS_HTTPS_CATALOG', '/gab/');

 

the third one seems to be Harry Potter magic:

define('DIR_FS_CATALOG', '/u/web/schr1/gab/');

This content was preset by install, i have got no clue what "/u/web/schr1" means.

Maybe the hitch is located there?

 

I made a try with

define('DIR_FS_CATALOG', '/gab/');

it gave me the same result

and made another attemp with

define('DIR_FS_CATALOG', 'gab/');

and the it could not get the .css I suppose

 

It really seems to be a matter of just getting the correct syntax, isn't it?

 

Thanks for your help

 

Glad to hear you found the 'little bugger' and have it working :thumbsup:

I guess "/u/web/schr1" must be your absolute path as defined by your provider for your webspace. Mine is even longer and just as cryptic so I am glad the osC install figured this out for me :lol:

 

I liked your idea. I could be handy to have the same stuff on different domains with just another touch to the layout. I think it might even have been easier if you just copied your stuff from one directory to another and then change the configure.php's accordingly.

Link to comment
Share on other sites

Glad to hear you found the 'little bugger' and have it working :thumbsup:

I guess "/u/web/schr1" must be your absolute path as defined by your provider for your webspace. Mine is even longer and just as cryptic so I am glad the osC install figured this out for me  :lol:

 

I liked your idea. I could be handy to have the same stuff on different domains with just another touch to the layout. I think it might even have been easier if you just copied your stuff from one directory to another and then change the configure.php's accordingly.

 

Unfortunately it still does not work.

There is a default directory stored somewhere and I really cannot find out where

:'(

In my actual configure.php there is no more reference to the old stuff (excepted the database) and it still gets the pictures form the old domain each time I don't specify the full path.

 

I actually am still investigating. The good thing i also found out is that the database can be anywhere, even on another domain, so it really seem to be easy to have one maintenance for several domains.

Link to comment
Share on other sites

Unfortunately it still does not work.

There is a default directory stored somewhere and I really cannot find out where

:'(

In my actual configure.php there is no more reference to the old stuff (excepted the database) and it still gets the pictures form the old domain each time I don't specify the full path.

 

I actually am still investigating. The good thing i also found out is that the database can be anywhere, even on another domain, so it really seem to be easy to have one maintenance for several domains.

 

I assume you mean the pictures from the catalog/images only !? Have you looked how the pictures are stored into the database (with/without sub-directories or something) ? Any template system or custom things which might interfere with the defaults inside the config.php ? Strange why everything else works and the images not ?

Link to comment
Share on other sites

I assume you mean the pictures from the catalog/images only !? Have you looked how the pictures are stored into the database (with/without sub-directories or something) ? Any template system or custom things which might interfere with the defaults inside the config.php ? Strange why everything else works and the images not ?

 

Hi,

shame on me! i have found out that I just was fiddling in the wrong configure.php file!

There are two of them, one on admin/ includes and another one in /includes .

 

Actually i must go for a trip until Monday, but i will keep on and report about my results soon.

 

Thanks

Michel

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...