Forums / All Other Contributions/Addons / MultiSite Module Support Thread

MultiSite Module Support Thread

Started by gerome on 23 Apr 2007, 10:24 AM · Views: 581,870

Results 1,861 to 1,880 of 2,247
25 Jan 2014, 7:53 PM
#1861
raimo avatar

raimo

New Zenner

Join Date:
Oct 2008
Posts:
7
Plugin Contributions:
0

MultiSite Module Support Thread

My multisite works perfect but now i want to add a site dieren-artikelen.nl (there is a - in the middle) because this is also the seperator, this gives problems....
Has anyone an idea how to put the categories to this site?

Thanks

25 Jan 2014, 8:23 PM
#1862
design75 avatar

design75

Totally Zenned

Join Date:
Dec 2009
Location:
Amersfoort, The Netherlands
Posts:
2,862
Plugin Contributions:
5

Re: MultiSite Module Support Thread

Raimo:

My multisite works perfect but now i want to add a site dieren-artikelen.nl (there is a - in the middle) because this is also the seperator, this gives problems....
Has anyone an idea how to put the categories to this site?

Thanks
That is most unfortunate. I think it means the whole module needs to be rewritten so you can use another separator like for example | (pipe).

26 Jan 2014, 7:16 PM
#1863
raimo avatar

raimo

New Zenner

Join Date:
Oct 2008
Posts:
7
Plugin Contributions:
0

Re: MultiSite Module Support Thread

Design75:

That is most unfortunate. I think it means the whole module needs to be rewritten so you can use another separator like for example | (pipe).

Does anyone have experience with this problem?
Can i simply change the seperator in multisite.php at .value.split("-") or will this not work at all?

26 Jan 2014, 7:51 PM
#1864
design75 avatar

design75

Totally Zenned

Join Date:
Dec 2009
Location:
Amersfoort, The Netherlands
Posts:
2,862
Plugin Contributions:
5

Re: MultiSite Module Support Thread

Raimo:

Does anyone have experience with this problem?
Can i simply change the seperator in multisite.php at .value.split("-") or will this not work at all?

I never heard of anyone else with the problem, maybe there aren't many using a - in their url's. At the moment I really have no idea where the changes would have to be made, because i didn't need to change that part of the code.
I has been a while since i looked at the code, because I made a new and completely different multi store module. It is database driven, but also a commercial mod (due to the development time i put in it).
If you have some time i could take a look at the current module this week to see what would need to be changed.

4 Feb 2014, 3:08 PM
#1865
rocketsites avatar

rocketsites

New Zenner

Join Date:
Jun 2013
Location:
United Kingdom
Posts:
41
Plugin Contributions:
4

Re: MultiSite Module Support Thread

Hi,

I'm trying install the module, and I seem to be falling at the first hurdle as I can't find any information that explains the fundamentals of the setup.

  • Do I need more than one installation of Zen Cart before I start?
  • If so, where do I install the multi-site module? The 'main' site, the other sites, or all of them?
  • The docs mention creating a template for each site. Do these new templates go into the templates directory of the 'main' site, the other sites, or all of them?

Any help would be appreciated! Thank you.

4 Feb 2014, 3:16 PM
#1866
twitchtoo avatar

twitchtoo

Totally Zenned

Join Date:
Apr 2007
Location:
Ontario, Canada
Posts:
1,733
Plugin Contributions:
14

Re: MultiSite Module Support Thread

Hi,

I'm trying install the module, and I seem to be falling at the first hurdle as I can't find any information that explains the fundamentals of the setup.
** - No worries...
**

  • Do I need more than one installation of Zen Cart before I start?
    - Just One.

  • If so, where do I install the multi-site module? The 'main' site, the other sites, or all of them?
    **- The hosting server location stays the same, choose an appropriate directory/folder name for your installed Zen Cart

  • **The **'multiple' **domains **'point at' **or **'redirect to' **your **unique domain names.

- The docs mention creating a template for each site. Do these new templates go into the templates directory of the 'main' site, the other sites, or all of them?
** - Yes you 'can' have two template/override folders.

Any help would be appreciated! Thank you.
- You're welcome.

Twitch.
https://www.twitchtoo.com Do you work for free? Please donate.
June 7.2026 - NOW AVAILABLE - Twitch Base8 - Obsidian

4 Feb 2014, 5:34 PM
#1867
rocketsites avatar

rocketsites

New Zenner

Join Date:
Jun 2013
Location:
United Kingdom
Posts:
41
Plugin Contributions:
4

Re: MultiSite Module Support Thread

twitchtoo:

Hi,

I'm trying install the module, and I seem to be falling at the first hurdle as I can't find any information that explains the fundamentals of the setup.
** - No worries...
**

  • Do I need more than one installation of Zen Cart before I start?
    - Just One.

  • If so, where do I install the multi-site module? The 'main' site, the other sites, or all of them?
    **- The hosting server location stays the same, choose an appropriate directory/folder name for your installed Zen Cart

  • **The **'multiple' **domains **'point at' **or **'redirect to' **your **unique domain names.

- The docs mention creating a template for each site. Do these new templates go into the templates directory of the 'main' site, the other sites, or all of them?
** - Yes you 'can' have two template/override folders.

Any help would be appreciated! Thank you.
- You're welcome.

Hi Twitch,

Thank you SO much for your reply. Very helpful.

Your instructions have got me slightly closer!

Do you know if the 'main' site can be in a subdirectory, and the 'other' sites be in a further directory?

e.g.

Main site = mydomain.com/store
Other = mydomain.com/store/other

Also, upon installing it onto my 'main' site (mydomain.com/store) it no longer uses the selected template (in Tools > Template Selection) and instead just uses template_default. Any ideas what that might be?

Thank you.

4 Feb 2014, 5:51 PM
#1868
twitchtoo avatar

twitchtoo

Totally Zenned

Join Date:
Apr 2007
Location:
Ontario, Canada
Posts:
1,733
Plugin Contributions:
14

Re: MultiSite Module Support Thread

Do you know if the 'main' site can be in a subdirectory, and the 'other' sites be in a further directory?

e.g.

Main site = mydomain.com/store
Other = mydomain.com/store/other
- Only one 'main site' here:
hosting site root/public_html/your_multisite_folder/zencart installed here

**- Your domain names all point at this folder with cPanel/hosting.

Also, upon installing it onto my 'main' site (mydomain.com/store) it no longer uses the selected template (in Tools > Template Selection) and instead just uses template_default. Any ideas what that might be?
- Yes go to Admin -> Tools -> MultiSite Tools -> Display the relations Categories/Sites
**

  • Add the 'sites' or template names to the appropriate categories**

Twitch.
https://www.twitchtoo.com Do you work for free? Please donate.
June 7.2026 - NOW AVAILABLE - Twitch Base8 - Obsidian

24 Feb 2014, 10:01 PM
#1869
philb316 avatar

philb316

New Zenner

Join Date:
Oct 2013
Location:
Waterloo, ON Canada
Posts:
3
Plugin Contributions:
0

Re: MultiSite Module Support Thread

I have been asked to take over a Zencart site which uses the multisite module. The sites have been neglected re doing the ZenCart upgrades and are still at v1.3.9h. I'm a newbie on the multisite module, and considering that these original Zencart sites were put together in 2007, need to investigate whether or not the multisite module is actually still required. Could someone please direct me to any doc that explains in what situations/requirements the multisite module must be used?
Thanks!

25 Feb 2014, 1:37 AM
#1870
twitchtoo avatar

twitchtoo

Totally Zenned

Join Date:
Apr 2007
Location:
Ontario, Canada
Posts:
1,733
Plugin Contributions:
14

Re: MultiSite Module Support Thread

Multisite = two or more domains, one database.

Sell shoes on one site, clothing on another.

One database stores customers, orders, etc.

Twitch.
https://www.twitchtoo.com Do you work for free? Please donate.
June 7.2026 - NOW AVAILABLE - Twitch Base8 - Obsidian

25 Feb 2014, 6:54 PM
#1871
philb316 avatar

philb316

New Zenner

Join Date:
Oct 2013
Location:
Waterloo, ON Canada
Posts:
3
Plugin Contributions:
0

Re: MultiSite Module Support Thread

Thanks!

The sites sell related equipment, all in the automotive industry, so it would be my guess that as long as only 1 template was needed for displaying all product, that I could potentially collapse the sites into 1.
The sites are:
wiretrim.langeman.com
wrapcut.langeman.com

and they also created separate sites for the CDN equivalents at:
wiretrim.shoplangeman.ca
wrapcut.shoplangeman.com
I do not know why a separate set of sites (with their multisite module) were created for Canada. Although I believe that the pricing is different. i.e. not even ***after ***the US/CDN dollar exchange is taken into account.

Does Zencart have limitless pricing levels? i.e. could I have separate pricing for Distributor A, Distributor B, ... Distributor N, plus retail etc ?

Thanks.

25 Feb 2014, 7:06 PM
#1872
twitchtoo avatar

twitchtoo

Totally Zenned

Join Date:
Apr 2007
Location:
Ontario, Canada
Posts:
1,733
Plugin Contributions:
14

Re: MultiSite Module Support Thread

It's less complex to have one site and point the various domains at it when you're only using one template. Yes there are a number of options for group pricing, discount pricing and wholesale pricing in the forum plugins.

From my *biased *perspective, Group Pricing is currently being integrated into Twitch Wholesale which would give you guest, retail, wholesale prices then 5 more static pricing levels.

Twitch.
https://www.twitchtoo.com Do you work for free? Please donate.
June 7.2026 - NOW AVAILABLE - Twitch Base8 - Obsidian

25 Feb 2014, 7:44 PM
#1873
philb316 avatar

philb316

New Zenner

Join Date:
Oct 2013
Location:
Waterloo, ON Canada
Posts:
3
Plugin Contributions:
0

Re: MultiSite Module Support Thread

I have no problem paying for good code / good support that makes things simpler. I am still re-establishing requirements, but once they're done will be looking for solutions to set up ZenCart for selling products on every continent - well maybe not Antarctica - but certainly will require quite a number of pricing levels plus multiple languages.

Thanks again for your help.

25 Feb 2014, 9:18 PM
#1874
twitchtoo avatar

twitchtoo

Totally Zenned

Join Date:
Apr 2007
Location:
Ontario, Canada
Posts:
1,733
Plugin Contributions:
14

Re: MultiSite Module Support Thread

Sounds good, you know where to find me ;)

Twitch.
https://www.twitchtoo.com Do you work for free? Please donate.
June 7.2026 - NOW AVAILABLE - Twitch Base8 - Obsidian

22 Apr 2014, 4:59 PM
#1875
adb34 avatar

adb34

Totally Zenned

Join Date:
Mar 2008
Location:
Brampton, Cumbria, United Kingdom, United Kingdom
Posts:
825
Plugin Contributions:
0

Re: MultiSite Module Support Thread

I am just trying to get my head around MYsql and adding/removing items from the database.

Using this plugin as reference I do not understand why there is only one line of command in the install patch and three lines in the uninstall patch.

Install.sql

ALTER TABLE orders ADD order_site varchar(30) NOT NULL DEFAULT 'no';

Uninstall.sql

ALTER TABLE orders DROP order_site;
ALTER TABLE ezpages DROP ezpages_description;

DELETE FROM admin_pages WHERE page_key = 'toolsMultiSite' LIMIT 1;

First: is this the correct place to talk about this
Second: can somebody explain why there is a variation in the two sql’s

Learning Fast.
Eden Craft Supplies

22 Apr 2014, 5:07 PM
#1876
twitchtoo avatar

twitchtoo

Totally Zenned

Join Date:
Apr 2007
Location:
Ontario, Canada
Posts:
1,733
Plugin Contributions:
14

Re: MultiSite Module Support Thread

ALTER TABLE orders ADD order_site varchar(30) NOT NULL DEFAULT 'no';
This adds the column 'order_site' to the orders table

Uninstall.sql

ALTER TABLE orders DROP order_site;
This removes the column 'order_site' from the orders table

ALTER TABLE ezpages DROP ezpages_description;
This removes 'ezpages_description' from the ezpages table

DELETE FROM admin_pages WHERE page_key = 'toolsMultiSite' LIMIT 1;
** This removes the 'toolsMultiSite' from the admin registry page**

Twitch.
https://www.twitchtoo.com Do you work for free? Please donate.
June 7.2026 - NOW AVAILABLE - Twitch Base8 - Obsidian

13 May 2014, 7:38 PM
#1877
simpledomaining avatar

simpledomaining

New Zenner

Join Date:
May 2011
Posts:
89
Plugin Contributions:
0

Re: MultiSite Module Support Thread

Hello. i am looking at this module, and need a little bit explanation if it will work for me. We have a working site mydomain.com/store in english. i need to add 2 more translations for the entire site and its products (spanish and french). do i need to use the multisite module for this or there is anything simpler available? will this module in any way affect my existing urls? will qbi orders exporting work with multisite? thanks.

13 May 2014, 8:33 PM
#1878
IDEASLady avatar

IDEASLady

Totally Zenned

Join Date:
Aug 2005
Location:
Trujillo Alto, Puerto Rico
Posts:
1,455
Plugin Contributions:
4

Re: MultiSite Module Support Thread

simpledomaining:

Hello. i am looking at this module, and need a little bit explanation if it will work for me. We have a working site mydomain.com/store in english. i need to add 2 more translations for the entire site and its products (spanish and french). do i need to use the multisite module for this or there is anything simpler available? will this module in any way affect my existing urls? will qbi orders exporting work with multisite? thanks.

Hello!

No, you don't need multisite for that. You just have to download the languages files for those languages and install.

IDEASLady
IDEAS Creative Studio

Your image... our business!

13 May 2014, 8:38 PM
#1879
design75 avatar

design75

Totally Zenned

Join Date:
Dec 2009
Location:
Amersfoort, The Netherlands
Posts:
2,862
Plugin Contributions:
5

Re: MultiSite Module Support Thread

simpledomaining:

Hello. i am looking at this module, and need a little bit explanation if it will work for me. We have a working site mydomain.com/store in english. i need to add 2 more translations for the entire site and its products (spanish and french). do i need to use the multisite module for this or there is anything simpler available? will this module in any way affect my existing urls? will qbi orders exporting work with multisite? thanks.

No you do not need this module, just install extra languages

10 Jun 2014, 5:30 AM
#1880
royaldave avatar

royaldave

Zen Follower

Join Date:
Aug 2013
Location:
Perth, WA, AU
Posts:
285
Plugin Contributions:
1

Re: MultiSite Module Support Thread

Would you like to see which 'template' your customer is visiting when looking at whos_online ?

I did, and here's what you need to do if you also wish to ....

WHOS ONLINE FOR MULTISITE

Add following column to whos_online in database -

site varchar(50)


/zencart/admin/includes/languages/english/whos_online.php

add -

define('TEXT_SITE', '<strong>Site:</strong> ');


/zencart/admin/whos_online.php

change -

$who_query = $db->Execute("select session_id, time_entry, time_last_click, host_address, user_agent
from " . TABLE_WHOS_ONLINE . "
where session_id='" . $which . "'");

to -

$who_query = $db->Execute("select session_id, time_entry, time_last_click, host_address, user_agent, site
from " . TABLE_WHOS_ONLINE . "
where session_id='" . $which . "'");

change -

$sql = "select customer_id, full_name, ip_address, time_entry, time_last_click, last_page_url, session_id, host_address, user_agent
from " . TABLE_WHOS_ONLINE . " :where: order by :orderby:";

to -

$sql = "select customer_id, full_name, ip_address, time_entry, time_last_click, last_page_url, session_id, host_address, user_agent, site
from " . TABLE_WHOS_ONLINE . " :where: order by :orderby:";

change -

                echo TEXT_SESSION_ID . zen_output_string_protected($whos_online->fields['session_id']) . '<br />' .
                TEXT_HOST . zen_output_string_protected($whos_online->fields['host_address']) . '<br />' .
                TEXT_USER_AGENT . zen_output_string_protected($whos_online->fields['user_agent']) . '<br />';

to -

                echo TEXT_SESSION_ID . zen_output_string_protected($whos_online->fields['session_id']) . '<br />' .
                TEXT_HOST . zen_output_string_protected($whos_online->fields['host_address']) . '<br />' .
                TEXT_SITE . zen_output_string_protected($whos_online->fields['site']) . '<br />' .
                TEXT_USER_AGENT . zen_output_string_protected($whos_online->fields['user_agent']) . '<br />';

/zencart/includes/functions/whos_online.php

change -

$wo_user_agent = substr(zen_db_prepare_input($_SERVER['HTTP_USER_AGENT']), 0, 254);

to -

$wo_user_agent = substr(zen_db_prepare_input($_SERVER['HTTP_USER_AGENT']), 0, 254);
$wo_site = SITE_NAME;

change -

$sql = "update " . TABLE_WHOS_ONLINE . "
          set customer_id = '" . (int)$wo_customer_id . "',
              full_name = '" . zen_db_input($wo_full_name) . "',
              ip_address = '" . zen_db_input($wo_ip_address) . "',
              time_last_click = '" . zen_db_input($current_time) . "',
              last_page_url = '" . zen_db_input($wo_last_page_url) . "',
              host_address = '" . zen_db_input($_SESSION['customers_host_address']) . "',
              user_agent = '" . zen_db_input($wo_user_agent) . "'
          where session_id = '" . zen_db_input($wo_session_id) . "' and ip_address='" . zen_db_input($wo_ip_address) . "'";

to -

$sql = "update " . TABLE_WHOS_ONLINE . "
          set customer_id = '" . (int)$wo_customer_id . "',
              full_name = '" . zen_db_input($wo_full_name) . "',
              ip_address = '" . zen_db_input($wo_ip_address) . "',
              time_last_click = '" . zen_db_input($current_time) . "',
              last_page_url = '" . zen_db_input($wo_last_page_url) . "',
              host_address = '" . zen_db_input($_SESSION['customers_host_address']) . "',
              user_agent = '" . zen_db_input($wo_user_agent) . "',
		site = '" . zen_db_input($wo_site) . "'
          where session_id = '" . zen_db_input($wo_session_id) . "' and ip_address='" . zen_db_input($wo_ip_address) . "'";

change -

$sql = "insert into " . TABLE_WHOS_ONLINE . "
            (customer_id, full_name, session_id, ip_address, time_entry,
             time_last_click, last_page_url, host_address, user_agent)
          values ('" . (int)$wo_customer_id . "', '" . zen_db_input($wo_full_name) . "', '"
                     . zen_db_input($wo_session_id) . "', '" . zen_db_input($wo_ip_address)
                     . "', '" . zen_db_input($current_time) . "', '" . zen_db_input($current_time)
                     . "', '" . zen_db_input($wo_last_page_url)
                     . "', '" . zen_db_input($_SESSION['customers_host_address'])
                     . "', '" . zen_db_input($wo_user_agent)
                     . "')";

to -

$sql = "insert into " . TABLE_WHOS_ONLINE . "
            (customer_id, full_name, session_id, ip_address, time_entry,
             time_last_click, last_page_url, host_address, user_agent, site)
          values ('" . (int)$wo_customer_id . "', '" . zen_db_input($wo_full_name) . "', '"
                     . zen_db_input($wo_session_id) . "', '" . zen_db_input($wo_ip_address)
                     . "', '" . zen_db_input($current_time) . "', '" . zen_db_input($current_time)
                     . "', '" . zen_db_input($wo_last_page_url)
                     . "', '" . zen_db_input($_SESSION['customers_host_address'])
                     . "', '" . zen_db_input($wo_user_agent)
                     . "', '" . zen_db_input($wo_site)
                     . "')";