We currently have a hand full of companies using an online ordering site with each company's products inside their own sub-domain (i.e. amce.onlineorders.com).
So the question is... do we/can we leave our current site as is and integrate MM2 into it or should we move all the individual company folders into one customer (members) folder?
I'd really prefer to not have to move anything (and possibly brake) and still have restricted access to each of the different company sub-domains.
Any suggestions would be greatly appreciated!
Ryan
Ryan,
If you use the .htaccess basic authentication w/ popup login you should have no problems with the site the way it is setup now. As the .htaccess file has a path in it to the authentication files on the server.
The non popup / mod_rewrite method works off of sessions and probably would not work as you're logging in on lets say the main site address then moving over to a new address / sub-domain where the session would be lost.
If you use the .htaccess basic authentication w/ popup login you should have no problems with the site the way it is setup now. As the .htaccess file has a path in it to the authentication files on the server.
This option is out. Some of our users distrust the "popup" login due to the fact that it's not part of the page layout/design.
The non popup / mod_rewrite method works off of sessions and probably would not work as you're logging in on lets say the main site address then moving over to a new address / sub-domain where the session would be lost.
Does the "session loss" occur if the user is redirected to a sub folder (i.e. onlineorders.com/acme)? Or is it possible to hand off the session info with an additional php header?
Ryan
Does the "session loss" occur if the user is redirected to a sub folder (i.e. onlineorders.com/acme)? Or is it possible to hand off the session info with an additional php header?
No sub-folders are fine and I would think in the long run easier to handle then setting up a sub-domain each time?
No sub-folders are fine and I would think in the long run easier to handle then setting up a sub-domain each time?
Our hosting company makes the creation of sub-domains really easy. Plus, at the time, before we purchased MM2, it was easier this was to keep everything, and everyone, separated.
So the long and short of it is:
- sub-folders not sub-domains
- it's not necessary to move group (company) folders into a members' folder
- and session data transfers within the main domain and all its folders
Thank you so much!
Ryan,
Doing a little research I found:
If you want to be able to pass session data between subdomains you need to add the following to the php.ini file.
session.cookie_domain = .mydomain.com
Do you have access to your php.ini?
If you want to be able to pass session data between subdomains you need to add the following to the php.ini file.
session.cookie_domain = .mydomain.com
Do you have access to your php.ini?
According to our hosting provider, if one doesn't exist, it can be created and placed at the root directory.
Sorry to ask such a basic question, but how do I test it properly.
Ryan
put this in /configs/config.php
under
ini_set("session.cookie_domain", ".mydomain.com");
Replacing .mydomain.com with yours.