Jump to content

Modifying $page->rootParent for multisite setup


Neil_Haskins
 Share

Recommended Posts

My organization is looking at moving our various websites to a CMS. As we have probably 20 - 30 sites, I want to do a multisite setup, using the multisite module, so that we don't need to maintain so many duplicate user accounts for our content editors. I'm wondering how I'm supposed to hook into $page->rootParent to get it to return its appropriate child.

I'm thinking I'll setup the page tree so that Home is just a dummy page, and all my real sites' homepages will be its direct children. That way I think I should be able to make the change to the rootParent method universal without having issues.

How could I accomplish this?

Am I making some horrible mistake which I have been unable to percieve thus far?

Thanks.

Link to comment
Share on other sites

The strategy you are describing is somewhat similar to the Multisite module by Apeisa. Read the thread for more info and you'll find that Soma rewrote the module. I don't know how wise it would be to create that many sites using this strategy since you'll end up with a lot of templates and fields if the sites are all different in their approach or needs.

  • Like 1
Link to comment
Share on other sites

Thanks for your reply.

Yes, I was describing using Apesia's Multisite module. I was aware Soma had done a re-write, but wasn't sure if it was tested and stable. Seeing it's only a bit over 200 lines does make it a bit more approachable, so maybe I'll try it.

As for creating many site under 1 install, the only thing I've heard against it is that one needs to manage many templates and fields. I had thought the obvious thing was to prefix them with an abbreviation of the site name. Has anybody reported any stability issues with multiple sites, or is it just organization.

We have 5 or 6 mid sized sites (50 - 200 pages), and probably 15 - 20 smallish (> 10 page) sites, and we want some of our less technical users to be able to edit content. I would just see it being a nightmare having to maintain seperate user accounts on 25 sites, whereas for multisite I would just create a user role for each site's template, and then assign user's whatever role's they need.

My other option at this point seems to be SilverStripe, but I don't really care for it, so I'm hoping to make ProcessWire work for me.

Thanks.

Link to comment
Share on other sites

It's not a stability issue. We've been using the multisite on several sites and it's working fine. The issue could be that if the sites all have different fields and templates you create a sort of frankenstein. On the sites we've used it on, the subsites are pretty simple and straightforwand basicly only using a basic-page template. I understand where you are coming from. We never did a project like that, but I would use ProcessWire to setup something like the thing you are describing. If you can provide the sites you are describing we can take a look and give a more detailed advice.

Link to comment
Share on other sites

Some of our larger sites:

http://onlineschool.ca/

http://www.bconlineschool.ca/

http://www.icos.ca/

http://www.heritagechristian.ca/

http://www.kcc.net/

An example of a smaller site:

http://www.bcconvention.ca/

Some of these we may be able to constrain to similar templates, onlineschool.ca and bconlineschool.ca for example. I frankly think that would be helpful for many reasons beyond CMS compatibility. But we still will have lots of fields and templates I'm quite certain.

Also bear in mind, we're hoping to start redesigning many of our sites, that's part of why were looking for a CMS, so these can give you an idea of our scale, but don't try to analyse the html for template compatibility or anything like that.

Thanks

Link to comment
Share on other sites

There are similarities, but most seem pretty different too. I don't really know if I should do this if the sites are really different on front-end side. If I could manage to design a (design) template-like structure with different colourschemes I might do it. 

Link to comment
Share on other sites

The template management and field management is not such a headache as long as you draw up some sort of group policy. That would include, for instance, saying that all sites use the same framework (Bootstrap or whatever), that certain central fields must be used over all the sites ... and so on.

Really, it is the same approach as if you were creating 30 standalone sites and were having to manage them all - you would not want them to be using 30 different CMS and frameworks!

I have not worked on multisite with Processwire, but I have with Liferay. The main issue we had was not so much the technology, but in making sure the right people from the right departments had the correct access to their bits, without treading on anyone else's toes or without making it too complicated.

That was far harder to get right than the actual site - the politics was a nightmare!

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...