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 401 to 420 of 2,247
17 Feb 2008, 7:59 AM
#401
makenoiz avatar

makenoiz

Zen Follower

Join Date:
Mar 2006
Posts:
284
Plugin Contributions:
0

MultiSite Module Support Thread

Have installed fresh 1.3.7 with Multi site. I have activated teh side box categories via tools > layout boxes but my cats show not products.
I have added the <!--site1-site2--> etc. code to descriptions in in categories_definiations but I still do no see any products. I am using the demo products that I installed with the ZC install.. ist here something else that I have to "turn on" in order to see the products?

Thanks

22 stores and counting! Ive been zenned.

17 Feb 2008, 8:49 AM
#402
makenoiz avatar

makenoiz

Zen Follower

Join Date:
Mar 2006
Posts:
284
Plugin Contributions:
0

Re: MultiSite Module Support Thread

I need to make a correction... my categories are not even showing in the side box- only

Specials.....
All Products ....

Need the categories themselves to show.. I have placed the comments in the DB per instructions. What am I missing?

Thank you

22 stores and counting! Ive been zenned.

18 Feb 2008, 4:24 PM
#403
kthompson avatar

kthompson

New Zenner

Join Date:
Jul 2007
Location:
Minneapolis, MN, United States
Posts:
71
Plugin Contributions:
0

Re: MultiSite Module Support Thread

Check to make sure the name you used in the comments is the same that you specified in the "www.YOURDOMAIN.com_config.php" file

I dont care what it says next to my name. I've been Zenned!

24 Feb 2008, 9:53 PM
#404
tanik avatar

tanik

New Zenner

Join Date:
Oct 2007
Posts:
63
Plugin Contributions:
0

Re: MultiSite Module Support Thread

hi, i was testing out the payment on my website and i got this error message.

1054 Unknown column 'order_site' in 'field list'

and a bunch of other stuff below but thats the main one.

I was using paypal and using a credit card not a paypal account. it gives that error message but it went through with paypal but it did not go through in the orders under the admin page. Is there something wrong that i cannot see. The order did go through but only in paypal before it was working fine. But i think the multisite did something not sure what it is.

27 Feb 2008, 2:56 PM
#405
cablesimple avatar

cablesimple

New Zenner

Join Date:
May 2007
Posts:
99
Plugin Contributions:
0

Re: MultiSite Module Support Thread

Just a forewarning, while I am using this, it is not even close to a complete solution. I also do not use the category filtering in this mod, or the cross-site carts so I have no idea if this would effect their functionality although it seems unlikely. I may never get around to providing this as an addition to this module, so figured it was still worth posting.

I had the need to limit which products were displayed by the stores by something other than categories. For the most part I needed to be able to restrict by manufacturer, but I figured why not make it more flexible while I was at it. So I decided to use the products_status field in the products table. Basically the idea is that you can create a filter group of products by making all of their products_status=2 (or any number). I keep the regular products that all stores can see on status=1. Then only the stores that are specifically given access to a status of 2 will be able to see the products in question. Doing this gives me unlimited product filtering flexibility. If I wanted to create tools to limit it by manufacturer it would be simple enough, although at the moment I just manually update the database where I see fit.

The other advantage to this solution for me is that I share the products,categories,manufacturers tables (mysql symbolic link) with another non-multisite store. By limiting products in this way the non-multisite store without any modifications will not see the products specified in a filter group.

What I did was install this function (put it in a file in includes/functions/extra_functions of any PHP filename):

function status_query_phrase()
{
    global $status_access;
 
   $query_phrase = "(";
 
    foreach ((array)$status_access as $status)
    {    $query_phrase .= "p.products_status = '". $status ."' OR "; }

    $query_phrase = rtrim($query_phrase,"OR ");
    $query_phrase .= ")";

    return $query_phrase;
}
```In each store config file includes\config_sites\www.example.com_config.php create the $status_access array:

```php
$status_access = array("1","2");
```Make sure each store has at least "1" so it can see the globally available products.  You could make that a default in the function (if the array didn't exist) if you'd like, I chose not to.

Then I just used the zen cart developer tool to search for p.products_status and replaced each occurrence where products_status is in the "where" clause with status_query_phrase() like the example below from **includes/functions/functions_categories.php

**```php
      $products_query = "select count(*) as total
                         from " . TABLE_PRODUCTS . " p, " . TABLE_PRODUCTS_TO_CATEGORIES . " p2c
                         where p.products_id = p2c.products_id
                         and ". status_query_phrase() ."
                         and p2c.categories_id = '" . (int)$category_id . "'";
```Then you have to update the database and set the products you want in their respective filter groups.  So for example if I wanted the manufacturer_id=5 to be only visible to one of my stores I would:

update products set products_status=2 where manufacturers_id=5;


Anyway, sorry for the roughness of this but I hope it's useful to someone out there.
3 Mar 2008, 3:03 PM
#406
coop1979 avatar

coop1979

New Zenner

Join Date:
May 2006
Location:
Columbia, SC
Posts:
26
Plugin Contributions:
0

Re: MultiSite Module Support Thread

I've been following this module for months, but there appear to be a few questions that I have that I can't find the answers to.

  • I have my main ZC installation on domain1.com on server1
  • I want to use the multisite module to use that 1 ZC installation on domain2.com on server2.
  • Eventually I will have domain3.com on server3, domain4.com, etc... all on different servers.How do I set that up?
5 Mar 2008, 2:11 AM
#407
motodelta avatar

motodelta

Zen Follower

Join Date:
Jan 2006
Posts:
119
Plugin Contributions:
0

Re: MultiSite Module Support Thread

Not sure if anyone is still looking at this, but I have a few questions that I hope some Multisiters can help me with...

  1. With secure checkout I'll be using a common page for all sites. (ie https://www.site1.com, https://www.site2.com all go to secure.site.com for checkout). Will the secure checkout respect the template of the site it came from?

  2. Ihave the admin tools installed but the "add all" and "remove all" buttons generate the following error:

Line 28
char 6
Error 'name' is null or not an object
URL: http://secure.xxx.com/admin/multisite.php?action=categories_sites

Any ideas?

5 Mar 2008, 2:13 AM
#408
motodelta avatar

motodelta

Zen Follower

Join Date:
Jan 2006
Posts:
119
Plugin Contributions:
0

Re: MultiSite Module Support Thread

tanik:

hi, i was testing out the payment on my website and i got this error message.

1054 Unknown column 'order_site' in 'field list'
.

Did you add the "order_site" column to the database per the installation instructions?

5 Mar 2008, 2:15 AM
#409
motodelta avatar

motodelta

Zen Follower

Join Date:
Jan 2006
Posts:
119
Plugin Contributions:
0

Re: MultiSite Module Support Thread

makenoiz:

On step 4 where exactly am I supposed to upload www.site1.com_config.php to? the site1.com html folder or a folder on the main sites area?

Thanks

To the includes/config_sites directory per the instructions.

6 Mar 2008, 8:41 PM
#410
cablesimple avatar

cablesimple

New Zenner

Join Date:
May 2007
Posts:
99
Plugin Contributions:
0

Re: MultiSite Module Support Thread

MotoDelta

  1. With secure checkout I'll be using a common page for all sites. (ie www.site1.com, www.site2.com all go to secure.site.com for checkout). Will the secure checkout respect the template of the site it came from?

Since you will have to setup secure.site.com in multisite config it will have its own template folder so I don't think it will. Don't remember seeing any code to make that work smoothly, but I could easily be wrong.

Try it. If it doesn't work you should be able to set something up where the template variable is passed when the secure site is accessed, put it in as a session variable, and then have the multisite config access that session variable as it's template folder.

7 Mar 2008, 6:41 PM
#411
calljj avatar

calljj

Zen Follower

Join Date:
Mar 2007
Posts:
253
Plugin Contributions:
2

Re: MultiSite Module Support Thread

NullMind:

Can somebody tell me if Multistore will do this ?

check this site

http://rc-mushroom.com/index.php

see how you can jump from "car" to "helicopter" .. it's the same store .. but when you jump, only the categories from each section show up .. very seamless

so it's not 2 sites with one db, but one db, one site, 2 stores ?

Gerome:

Yes, you can do that with multisite.

Any one managed to do this and can supply an overview of how to do it?
Struggling to get my head around this!

8 Mar 2008, 11:52 PM
#412
tanik avatar

tanik

New Zenner

Join Date:
Oct 2007
Posts:
63
Plugin Contributions:
0

Re: MultiSite Module Support Thread

MotoDelta:

To the includes/config_sites directory per the instructions.

Yea i found that out later on. I dont know how i missed that. but i got it working. thx

10 Mar 2008, 10:25 PM
#413
tankha avatar

tankha

New Zenner

Join Date:
Feb 2008
Posts:
11
Plugin Contributions:
0

Re: MultiSite Module Support Thread

I have same problem as makenoiz
installed MultiSite, set all categories to current site via tools->multisite tools but don't see categories in main page. May be i missed sum sing in configuration?

Steps, that i done...
updated SQL
copied all files (new and modyfied) as written in the FAQ.
Make site config file
set in tools->multisite my host name (test server so this is localhost)

Thank you

13 Mar 2008, 9:29 PM
#414
motodelta avatar

motodelta

Zen Follower

Join Date:
Jan 2006
Posts:
119
Plugin Contributions:
0

Re: MultiSite Module Support Thread

I'm stuck!

So here's the problem.. I've got my 3 front ends working fine and tuned up nicely...

...then comes SSL. I want to use a common site, http://secure.site.com as my checkout area common to all front-ends. I'm using subdomains as my various front ends with these directories being virtual to the main directory.

In other words:

Store1.site.com, Store2.site.com, Storen.site.com, all point to secure.site.com

Now when I enable ssl on secure.site.com and a user clicks on login, the statement in Switch_sites.php $default_server_name = $_SERVER['HTTP_HOST']; doesn't understand the "parent" site. So I lose my template.

I'd like secure.site.com to respect the referring template for a seamless user experience. I tried using $_SERVER['HTTP_REFERER'] but at the next click that is lost too.

My thought was then to use a session variable to store the parent site, this variable would be invoked in the original store1.site.com_config.php file. However whenever I try and use a session variable, the site crashes. As soon as I start a session. Even if I use !isset to check the session it still crashes if I invoke session_start();

SO what gives? How can I store the parent site from the unsecured browsing in such a way that when the user hits the secure site I still know where he came from and can dynamically configure the secure.site.com_config.php to use the proper referring template?

I can't find any good documentation on zen_Session_start which I feel may be the answer.

THanks for any help.

15 Mar 2008, 5:56 PM
#415
motodelta avatar

motodelta

Zen Follower

Join Date:
Jan 2006
Posts:
119
Plugin Contributions:
0

Re: MultiSite Module Support Thread

Anyone? Beuhler? Beuhler? Beuhler?

20 Mar 2008, 3:24 PM
#416
kthompson avatar

kthompson

New Zenner

Join Date:
Jul 2007
Location:
Minneapolis, MN, United States
Posts:
71
Plugin Contributions:
0

Re: MultiSite Module Support Thread

Hey MotoDelta,

When I used this mod I actually settled for having a "checkout template" but maybe there is some way for you to implement this...

http://www.YOURDOMAIN.com/cart/index.php?main_page=index&template_dir=classic

note the last part of the url it will display whatever template you tell it to (using the directory name)

for example if you say &template_dir=template_default it will use the default template.

Maybe you can use that somehow

Keep us posted on what you come up with. I'm curious

I dont care what it says next to my name. I've been Zenned!

25 Mar 2008, 3:11 PM
#417
makenoiz avatar

makenoiz

Zen Follower

Join Date:
Mar 2006
Posts:
284
Plugin Contributions:
0

Re: MultiSite Module Support Thread

HI there.... any updates on this? I also am having problems with multi site ssl.

I have vps and I cert for all domains on VPS such as https://www.mymainsite.com/~addonaccountSite

Thanks

22 stores and counting! Ive been zenned.

26 Mar 2008, 1:56 AM
#418
juliartz avatar

juliartz

New Zenner

Join Date:
Oct 2007
Posts:
53
Plugin Contributions:
0

Re: MultiSite Module Support Thread

I don't mean to sound "dumb", (eh hemm, but I am! :lookaroun ) but is this "multiSite Mod" meaning that this mod will allow you to use your googlecart account on more one website? I have 3, and need to have the same account working for/on all three?

26 Mar 2008, 4:46 PM
#419
kthompson avatar

kthompson

New Zenner

Join Date:
Jul 2007
Location:
Minneapolis, MN, United States
Posts:
71
Plugin Contributions:
0

Re: MultiSite Module Support Thread

You can use the same account on all three.

I dont care what it says next to my name. I've been Zenned!

31 Mar 2008, 12:06 PM
#420
stellarweb avatar

stellarweb

Zen Follower

Join Date:
May 2006
Location:
Montana
Posts:
293
Plugin Contributions:
8

Re: MultiSite Module Support Thread

As far as I can tell, I have followed the instructions to a T - but I get this error when trying to go to the website:

include_once('includes/config_sites/sites_switch.php');
1054 Unknown column 'CATEGORIES_ROOT' in 'where clause'
in:
[select cd.categories_name from zen_categories c, zen_categories_description cd where cd.categories_description LIKE '%-SITE_NAME-%' AND cd.language_id=1 AND c.parent_id = CATEGORIES_ROOT and c.categories_id = cd.categories_id and cd.language_id='1' and c.categories_status=1]

The admin area works - but not the website :oops:

Can anyone help me get this resolved?

THANKS in advance!