61
maddog_chris
Re: Multisite HACK for 2.2.3 Final

Hi

I decided to delete everything, and started from scratch.

I did everything you told me, when I looked at my tables, I saw that in site1 I had these tables from site2:

block_instance
block_module_link
config
configcategory
configoption
modules
newblocks
sessions
sites

and site2 had no extra tables.

And I could only login as normal using site2 login details.

What did I do wrong?

Regards

Chris

62
draj
Re: Multisite HACK for 2.2.3 Final
  • 2006/5/6 9:10

  • draj

  • Quite a regular

  • Posts: 271

  • Since: 2005/6/23


Hi Chris!
Quote:

maddog_chris wrote:
And I could only login as normal using site2 login details.


Looks good. Now it should actually work and therefore I am confused!

Can you login into site2 with the same user details? Then it has worked, or? I did not seem to understand.

Is it possible to have an admin login of XOOPS access that I can have a look? Send me a PM the details of your website and I shall take it from there.

For this I need:

a. Installation of site1
b. site2 parked or pointing to site1
c. all modules uploaded in the XOOPS directory.
d. A copy of mainfile.php.txt
e. Admin Password for site1

More rights I have, earlier I may be able to get your work going. Actually it is a matter of minutes to get it going. You may also create extra subdomains and let me show you what and how to do it. May be it could be a good idea to install a demo somewhere and show everyone how to do it.

This discussions is for both of us taking more time and you do not come further.

63
maddog_chris
Re: Multisite HACK for 2.2.3 Final

Hi

I cannot login to Site2 using Site1 login details.

Can you explain how this mod works, as I cannot see where we have told site2 to use site1 login details, as all the work we have done has been on site1.

I would of expected to have to have altered something in site2.

Or is this just me not understanding.

Anyway I shall install XOOPS of the proper sites that I want to use later on this weekend, and then I shall pm you the details that you require.

At a later stage, if I install extra mods to either the mainsite or the subsite, will that make any difference.

Also just one last thing if when it's all working, if a new users signs up to site2, will they be able to login to site1, or do I need all users to signup to site1?

Regards

Chris

64
draj
Re: Multisite HACK for 2.2.3 Final
  • 2006/5/6 19:17

  • draj

  • Quite a regular

  • Posts: 271

  • Since: 2005/6/23


Hi!
Quote:

maddog_chris wrote:
I cannot login to Site2 using Site1 login details.
Can you explain how this mod works, as I cannot see where we have told site2 to use site1 login details, as all the work we have done has been on site1.

If you share User tables, you will have ONLY ONE SET of User tables that works and applies to both the sites. If you do not share, then you will have two set of them and each site will have different details of users.

If you share , then:

- If a user registers in site1, then he will be login from site2
- If he registered from site1, he will be able to call all the details of the account from the site2.

Try to understand this of sharing thing. Both the installation will use the same info from the DB.

Quote:

I would of expected to have to have altered something in site2.
At a later stage, if I install extra mods to either the mainsite or the subsite, will that make any difference.


No changes for site2.

All the modules will become specific to each site, mainsite or subsite, as the XOOPS will have each individual table for the mods THAT ARE NOT SHARED.

The biggest problem you may have in the de-installation of modules that are shared! Then you have a big trouble. DO NOT DE-INSTALL SHARED MODULES from subsite.

Quote:

Also just one last thing if when it's all working, if a new users signs up to site2, will they be able to login to site1, or do I need all users to signup to site1?


THEY WLL BE ABLE TO LOGIN TO SITE, because the table is the same, regardless of site1 or site2. Both the site have one and only one user table.

Signing up a users from any of the hundred of subsites, the user details will land only in one user table, as it is a shared one. If you side by side see in the MySQL DB after each creation of subsite, then you will notice that the shared tables have the prefix of the master site whereas the subsite have the prefix of shared sites. (I hope this observation is correct?)

Waiting for your PM.

65
draj
Re: Multisite HACK for 2.2.3 Final
  • 2006/5/9 15:36

  • draj

  • Quite a regular

  • Posts: 271

  • Since: 2005/6/23


Hallo Friends!

I am having problems with Chris. I am not able to convince him to read my messages or this thread, or even the title of this thread. After a series of messages as PM, he has asked me the following message. I am speechless!

Can someone answer the following question by Chris (maddog_chris):
Quote:

My mainsite has XOOPS version 2.2.4 and not 2.2.3 does that matter, if it does, let me know I will re-install 2.2.3

66
draj
Re: Multisite HACK for 2.2.3 Final
  • 2006/5/12 8:02

  • draj

  • Quite a regular

  • Posts: 271

  • Since: 2005/6/23


Hallo Chris and everyone!

I have successfully installed multisite module and have configured two sites for Chris (maddog_chris), one mastersite and one subsite!

Following were problems and mistakes:

In my earlier post, I refered to the URI and see now, that I myself made a wrong reference, absent minded. It happened due to copy cut and paste URL. Here is the correct version:

URI should NOT have http:// in the field!

This is the way how I solved and successfully installed:

1.
define('XOOPS_RESCUE_URL', 'http://mastersite.com')
>>> refers to the apache conf as the main site.

2.
Enter in the preferences, custom cookies >> mastersite.com_session for all cookies references

Preferences > System > General Settings
Site name: mastersite.com
Use custom session: Yes
Name for user cookies: mastersite.com_user
Session name: mastersite.com_session
SSL Post variable name: mastersite.com_ssl (If ssl is yes!)

Install PM, User Profiles and site module.

3.
Logout from http://mastersite.com and then login http://mastersite.com again to capture correct cookies on your local computer.

4.
User Site Management from the modules.

Enter following in the Add site form:

Site Name: subsite1.com
Site URL: http://subsite1.com
Theme Path: themes
Templates Path: templates_c
Upload Path: uploads
Cache Path: cache
URI Pattern: subsite1.com
DB Prefix * subsite1
Shared Tables
>>>>>>>>>>>>>>>> block_instance
>>>>>>>>>>>>>>>> block_module_link
>>>>>>>>>>>>>>>> group_permissions
>>>>>>>>>>>>>>>> groups
>>>>>>>>>>>>>>>> groups_users_link
>>>>>>>>>>>>>>>> newblocks
>>>>>>>>>>>>>>>> priv_msgs
>>>>>>>>>>>>>>>> profile_category
>>>>>>>>>>>>>>>> profile_fieldcategory
>>>>>>>>>>>>>>>> tpl_file
>>>>>>>>>>>>>>>> tplset
>>>>>>>>>>>>>>>> tplsource
>>>>>>>>>>>>>>>> user_profile
>>>>>>>>>>>>>>>> user_profile_field
>>>>>>>>>>>>>>>> users
>>>>>>>>>>>>>>>> xoops_notifications

The above tables are marked blue during creation of subsites. Then click SUBMIT.

Thereafter click on the newly created subsite and make sure to have all the fields filled with the above parameters including all the marked tables same. Then do the following:

>> Click on the box
URI Pattern: subsite1.com to be set yes.

Write in the empty field of as
URI Pattern: http://www.subsite1.com

Then click SUBMIT. Then in the URI pattern both the URI pattern will appear as

subsite1.com
http://www.subsite1.com

By doing so, the multisite module FORCES to redirect the URL/URI to point to both the location.

4.
Logout and then login to http://subsite1.com get correct cookies on your local computer.

Change the following:
Preferences > System > General Settings the following:

Site name: subsite1.com
Use custom session: Yes
Name for user cookies: subsite1.com_user
Session name: subsite1.com_session
SSL Post variable name: subsite1.com.com_ssl (If ssl is yes!)

5.
Logout and then login to http://subsite1.com get correct cookies on your local computer.

6.
Begin installing modules on mastersite.com and subsite1.com.

Now you are done with the basic configuration of mastersite.com and subsite1.com.
------------------------------------------------
Notice during the process that the moment you start changing the title of the subsite, cookies, etc the XOOPS multisite module will show in the title tags those changes. You will be logged into mastersite while notlogged into the subsite1!
------------------------------------------------
If you want to install more sites, substitute subsite1.com to any other subsiteXXX.com and repeat the subsite creation process.
------------------------------------------------
Please note: I have shared the following:
>>>>>>>>>>>>>>>> tpl_file
>>>>>>>>>>>>>>>> tplset
>>>>>>>>>>>>>>>> tplsource

I do not know the impact of the above tables to be shared. Did not have time to play with it. However, I can imaging that during installation or de-installation process, the templates would be stored or removed from those tables. So what will happen with the modules that are shared or not shared and their respective templates.

Further, I have also shared blocks. I do not know what will happen if one does not share.

This question one must try and see... Well.
------------------------------------------------

If anyone has problems to install the module, let me know here. After having many nightmares and mistakes by myself, I have learned to detect mistakes. Hence it goes quickly for me to install those things.

Hope it helps to all others who wanna use this module.

67
maddog_chris
Re: Multisite HACK for 2.2.3 Final

Hi Deepy

I have 1 small problem now, I installed 2 subsites, which I managed to get the modules permission working okay, and they work great now.

My main problem now is that if I login to cjsinks.co.uk, cjsprinting.co.uk, or my main site and click on list all blocks, I just get a white screen, the debug show up as:

Fatal error: Call to a member function getVar() on a non-object in /home/cjsnet/public_html/modules/system/admin/blocksadmin/blocksadmin.php on line 97
Notice [PHP]: Undefined index: 13 in file modules/system/admin/blocksadmin/blocksadmin.php line 97

What is wrong, and how do I cure this, cj-systems.co.uk, this site lists the blocks okay, but the other sites don't

Regards

Chris

68
maddog_chris
Re: Multisite HACK for 2.2.3 Final

Hi Deepy and Everyone

Managed to get my problem sorted out, but ran into further problems with groups and permission.

I found it far better not to share the group tables, as sometimes you want certain items on one site1, but not on site2.

It's all seems to be working fine now, but I would suggest to anyone out there trying to install and run this module, to BACKUP your SQL database regularly, just incase you make any mistakes.

Chris

69
Mamba
Re: Multisite HACK for 2.2.3 Final
  • 2006/5/15 3:24

  • Mamba

  • Moderator

  • Posts: 11409

  • Since: 2004/4/23


Quote:

maddog_chris wrote:
Managed to get my problem sorted out, but ran into further problems with groups and permission.


Would you care to update Deepey's posting with detailed steps on how to make it work? This would be very useful.

Thanks....
Support XOOPS => DONATE
Use 2.5.11 | Docs | Modules | Bugs

70
draj
Re: Multisite HACK for 2.2.3 Final
  • 2006/5/15 6:42

  • draj

  • Quite a regular

  • Posts: 271

  • Since: 2005/6/23


Hello Chris and everyone!

Quote:

Mamba wrote:
Quote:

maddog_chris wrote:
Managed to get my problem sorted out, but ran into further problems with groups and permission.

Would you care to update Deepey's posting with detailed steps on how to make it work? This would be very useful.


@Chris
I am glad that you sorted out. This module becomes a nightmare when it does not work.

@Everyone
The combination of tables, which Chris mentions to change, should be decided to install individually. One has to decide and understand fully and correctly WHICH EXACTLY are the Set of tables to be shared.

For instance, in my earlier messages, I used module table to share. This did also work as I wanted to offer all the subsite the same set of modules without having to install again and again.

I had 70 subsites to generate, of which I did generate or duplicate or clone about 21 subsites with their related environment. Each subsite had about 20 groups, all having the same nature in all.

What a nightmare would it be to install and configure 20 groups 70 times? Many groups like SUbAdmin, Editor, etc has similar properties.

However, in my suggestion of configuraion for Chris, there is also a mistake. I am not sure if Chris did actually realise. This "could be" also a nightmare at a later date! Here is what has NOT been detected:

1.
I first did share table xoops_module. De-installation + other things was problematic and therefore I did not share later on. Then everything worked.

I did share xoops_block_instance, xoops_groups_users_link, xoops_groups_permission

2.
Groups shared but modules not. So the group permissions would be applied to the same modules numer/ID, even if the module functions are different!

In the xoops_groups_permission table, there are references to the following:

gperm_groupid (1)
gperm_modid (27)

Hence, if there is a module (27) given free with Admin Access (1), then it will be the same for all the subsites. Now, I DID NOT share the modules table. So if the modid (27) in subsite1 is Forum and subsite2 modid (27) is News, they all will have module Admin access!!!

Hence, one has to be very carefull and see which combination is correct!!!

Login

Who's Online

405 user(s) are online (298 user(s) are browsing Support Forums)


Members: 1


Guests: 404


xoopdio,

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