1
Mithrandir
Multisite hack for XOOPS 2.2

As promised, here is my hack for multisites for XOOPS 2.2, giving you the opportunity to run multiple sites off of one XOOPS installation.

The multisite feature looks at the URL for identifying individual sites, so you will need some webserver configuration or parked domains to get the different URLs pointing to the same XOOPS files.

Installation instructions:
1) Install XOOPS
2) Upload hack files - except mainfile.php, it is just there as an example
3) Modify your mainfile.php to define XOOPS_RESCUE_URL instead of XOOPS_URL
4) Install site administration module
5) Configure sites

Each site will be as individual as you want it to be - they can share module tables, configuration tables, user tables etc. but be warned that I take NO RESPONSIBILITY for sites messing up due to mixups when some tables are shared but not others as some conflicts can occur (e.g. sharing the group_user_link table without sharing groups and users table)

USE AT YOUR OWN RISK.

Download multisites from here
"When you can flatten entire cities at a whim, a tendency towards quiet reflection and seeing-things-from-the-other-fellow's-point-of-view is seldom necessary."

Cusix Software

2
smdcom
Re: Multisite hack for XOOPS 2.2

thanks for sharing mith... this what i was looking... i will test it...

3
Kazinak
Re: Multisite hack for XOOPS 2.2
  • 2005/7/27 14:15

  • Kazinak

  • Just popping in

  • Posts: 8

  • Since: 2005/4/19


Any manual or documentation for multisite hack ?

4
romu
Re: Multisite hack for XOOPS 2.2
  • 2005/7/27 14:20

  • romu

  • Theme Designer

  • Posts: 22

  • Since: 2002/12/5


ok fine !
Juste can someone tell me more about subsite hack way to to ?
SubSite shares DB tables between many XOOPS (directories) able to point the same DB(host).

This hack is usefull to share users data (exept avatar) into multiple XOOPS (for large sites).

Regards

5
Mithrandir
Re: Multisite hack for XOOPS 2.2

Quote:
Is there a manual

Not really, no.

There's a readme with the changes and the site module should be rather self-explanatory.

I know this sounds elitist, but if you need the manual, you shouldn't use this hack. And for god's sake, try it out on a test installation until you have the feel for how it works, for when tables are created and removed when editing the shared tables for a site.
"When you can flatten entire cities at a whim, a tendency towards quiet reflection and seeing-things-from-the-other-fellow's-point-of-view is seldom necessary."

Cusix Software

6
Kazinak
Re: Multisite hack for XOOPS 2.2
  • 2005/7/27 14:40

  • Kazinak

  • Just popping in

  • Posts: 8

  • Since: 2005/4/19


Lamers wants to use this hack too! :)

Well, i want just little help, nothing more ) Just tell - where is my mistake ?

1. I have a main site with URL, for example, http://127.0.0.1 and DB prefix "abcde" and I want to make another site with jokes and some humor content.

2. I create another site with URL http://127.0.0.1/humor/ with DB prefix "zxcvb".

3. Then, I install this hack and module "Site Administration"

4. I click on "Add Site" and write in fields:

Site URL - http://127.0.0.1/humor/
Theme Path - http://127.0.0.1/humor/themes
... and etc.

Then I wrote DB prefix - "zxcvb", choose shared tables and click on "Submit"...

Is there correct procedure ?

7
Kazinak
Re: Multisite hack for XOOPS 2.2
  • 2005/7/27 14:48

  • Kazinak

  • Just popping in

  • Posts: 8

  • Since: 2005/4/19


Lamers wants to use this hack too! :)

Well, i want just little help, nothing more ) Just tell - where is my mistake ?

1. I have a main site with URL, for example, http://127.0.0.1 and DB prefix "abcde" and I want to make another site with jokes and some humor content.

2. I create another site with URL http://127.0.0.1/humor/ with DB prefix "zxcvb".

3. Then, I install this hack and module "Site Administration"

4. I click on "Add Site" and write in fields:

Site URL - http://127.0.0.1/humor/
Theme Path - http://127.0.0.1/humor/themes
... and etc.

Then I wrote DB prefix - "zxcvb", choose shared tables and click on "Submit"...

Is there correct procedure ?

8
Mithrandir
Re: Multisite hack for XOOPS 2.2

You first have to understand that basics of how this hack works.

It works by running ALL sites from the SAME code. For example, I have http://www.bfsb.dk pointing to the same physical location as xoops.web-udvikling.dk, so it is the SAME index.php that is accessed.

You can do it with subfolders on Apache with the ALIAS directive in the apache's httpd.conf file, making an alias for the (non-existing) subfolder to point to the root.

In your example, you would

1) install XOOPS on 127.0.0.1
2) install site administration on this site.
3) Create a new site in the site administration module, with the URL http://127.0.0.1/humor and the prefix zxcvb
4) Create an ALIAS in your apache's httpd.conf file
5) Restart apache
6) access 127.0.0.1/humor and start configuring this site. The first thing I do is to change the name of the site in the site's normal XOOPS general preferences and then I uninstall the Site admin module from this site to avoid confusion

To install a module and share it with other sites do this:
1) Install module on all the sites that should have the module - include the "base" site (127.0.0.1/ in your case)
2) Edit each site in the "base" site's Site Administration module to share the new module's tables

To uninstall a shared module from a subsite do this:
1) Edit the subsite in the "base" site's Site Administration and set the module's tables to not be shared anymore
2) Uninstall the module on the subsite

Especially the uninstallation procedure can cause problems if you don't un-share the tables first (since the tables will then be removed by the uninstallation - but all the other subsites will still have references to the module in their database tables)
"When you can flatten entire cities at a whim, a tendency towards quiet reflection and seeing-things-from-the-other-fellow's-point-of-view is seldom necessary."

Cusix Software

9
Kazinak
Re: Multisite hack for XOOPS 2.2
  • 2005/7/27 15:49

  • Kazinak

  • Just popping in

  • Posts: 8

  • Since: 2005/4/19


Quote:
4) Create an ALIAS in your apache's httpd.conf file


Alias /humor"/home/127.0.0.1/www/"


Correct ?

10
draj
Re: Multisite hack for XOOPS 2.2
  • 2005/7/31 15:39

  • draj

  • Quite a regular

  • Posts: 271

  • Since: 2005/6/23


Hallo Mithrandir!

How wonderful to have you in the CORE Team, apart from your excellent Programming skills.

BTW, I have some questions to you:

1. It would be very helpful, if different subdomains could be pointed to different subsites. For instance,

http://a.germany.de >>> Module News
http://b.germany.de >>> Module mylinks etc.

I plan to implement about 50 - 70 subsites over one installation! That shall be the biggest ever multiwebsites by XOOPS and would be a star project (In German to begin with).

Hence if one types in the Browser - Location, different sites would not only have different themes but also different starting module pages, thereby, defining different homepages for different subsites.

This is currently not possible.

Do you have any tweaks or suggestions? In the second week of August, I plan to start cloning the databases to replicate about 50 - 70 sites. Its a star project.

2. The current Membership Module has failed to work with the installation of 2.2 Xoops. I placed several messages no no help. However they were regarding to earlier versions of Xoops. Now that I shall be using the XOOPS 2.2 in combination with the compitable multisites module, it is important to have a Membership Module working.

For our non-profit Association (similar to Fathers4Justice), it is important to maintain a users database of about 40.000 - 50.000 members on the internet.

Is there any other way to have something similar or compatible with XOOPS 2.2?

Thanks for your cooperation in advance.

Login

Who's Online

378 user(s) are online (272 user(s) are browsing Support Forums)


Members: 0


Guests: 378


more...

Donat-O-Meter

Stats
Goal: $100.00
Due Date: Nov 30
Gross Amount: $0.00
Net Balance: $0.00
Left to go: $100.00
Make donations with PayPal!

Latest GitHub Commits