Textpattern CMS support forum
You are not logged in. Register | Login | Help
- Topics: Active | Unanswered
Pages: 1
Sub domain micro sites with TxP
Hi everyone
I have a client who wishes to extend his current TXP site by adding sub-domains for each of his franchiees so they have their own home page and contact page, but duplicate the rest of the content of the main site.
So www.example.com and example.com both resolve to his main home page, but franchise1.example.com and franchise2.example.com go to specific home pages for each of the two franchises, etc.
The content of the rest of the sites should be the same, except for the contact page: example.com/contact-us is the contact details for the parent company, but franchises1.example.com/contact-us shows the specific contact details for franchisee 1.
For the duplicated pages, they should ideally be pulled from the same db entries, so updating the content for the main site updates it for all the micro sites too.
So my questions are:
1. Is this possible with TXP using the multi-site capabilities of 4.2.0 and if so, what is the best way to go about this?
2. Instead of duplicating the content (possible Google penalties?) would it be possible to set a cookie if the visitor was coming from a franchise URL adn use that to show the custom home pages and contact us pages for each micro site? How would I best implement this?
3. Any other ways of doing this?
Thanks for your help.
Steve
Offline
Re: Sub domain micro sites with TxP
Any reason why you couldn’t just do this on the other side of the tld?
eg… example.com/contact-us/franchise1 or even just with urlvars… example.com/contact-us?fran=a_franchise_name
That way you could have customized content all coming out of the same db.
Offline
Re: Sub domain micro sites with TxP
True, it’s possible, but then it’s more difficult for a franchisee to publicise their own website as the “home page” URL is really a sub-page of the main site, i.e. example.com/franchise1 instead of franchise1.example.com.
It’s a subtle difference I’ll grant you, but with the second option, it becomes possible to sell it to the franchisees that they have a unique focussed website for their area, rather than a sub-page on the main site.
Last edited by springworks (2009-12-15 19:33:21)
Offline
Re: Sub domain micro sites with TxP
Does each franchisee need access to ONLY their content?
Offline
Re: Sub domain micro sites with TxP
Hi Springworks.
1. Is this possible with TXP using the multi-site capabilities of 4.2.0 and if so, what is the best way to go about this?
I’ve been working (and currently working) on a website that needed a similar setup (a main “www.example.com” site and a few regional sites, running on a subdomain, like “us.example.com”, “eu.example.com”, etc).
Each website (“www”, “us”, “eu”, etc) is an stand-alone site. In other words, there is a Textpattern installation running behind each website. I’ve used the multi-site capability of 4.2.0 to make it easier to set-up and maintain.
Of course, this only shares the TXP core files. Don’t expect it to share the contents across each installation (each website needs its own database)
For the duplicated pages, they should ideally be pulled from the same db entries, so updating the content for the main site updates it for all the micro sites too.
Here, I would recommend you the following: keep all the common company content under the “www” TXP installation. In other words, keep it on just one database.
Then, for example, when someone visits franchise1.example.com, you will have a main navigation similar to this:
- Home (URL: franchise1.example.com)
- A Common Section 1 (URL: www.example.com/a-common-section-1)
- Another Common Section 2 (URL: www.example.com/another-common-section-2)
- Contact us (URL: franchise1.example.com/contact-us)
2. Instead of duplicating the content (possible Google penalties?) would it be possible to set a cookie if the visitor was coming from a franchise URL adn use that to show the custom home pages and contact us pages for each micro site? How would I best implement this?
Now, this is a possible scenario: the visitor is browsing the franchise1 website (for example, the Home or the Contact Us section) and decides to visit a common section (on the “www” domain).
How do you keep track from which site the visitor is coming, so to render the main navigation with links back to the Home and Contact Us of the franchise1 website?
As you also suggest, I’ve solved this by using the chs_cookie plugin (a modified version that I can share with you) and storing a cookie to remember where the visitor is coming from. Then, I used the value of the cookie to create the main navigation properly
3. Any other ways of doing this?
I would suggest you to use cnk_versioning. With a clever setup (using some simple symlinks) you can share and handle all the page templates and forms for all the websites (main and franchises) from one place.
Offline
Re: Sub domain micro sites with TxP
I’m currently building this kind of setup. I’ve run some preliminary tests, and it works so far.
In fact, the multi-site capability of Textpattern does exactly the reverse: several independant websites with just one install. As I understand, you’re looking for the same as I am: several domains/subdomains which share some content and the admin side.
My particular case is the following: I own the domain graphie.org. Which is nice to compose subdomains like: info.graphie.org, typo.graphie.org… I want to mix articles from each one on the frontpage, or the blog part,… All is centralised under the same hood, under one login, one can control content from main and subsites, all at once.
The first step is quite easy, thanks to TXP’s supreme flexibility:
Install Textpattern at each domain/subdomain root folder, and configure each to point to the same database. Or simply copy one install around, and just change the path to textpattern folder if you want to reach the admin from each subsite. Yes, as simple as that.
Second step is to configure your site’s navigation to take advantage of this. It’s a bit more tricky.
And the life saver is:
ied_if_domain
I didn’t go very far for the moment. But one thing is sure: it works.
I imagine giving each subdomain it’s own section(s). This way, we can build special navigation for each case, even without abusing ied_if_domain. I have yet to design the details and get into the problems. I suppose at this step another life saver will be: gdb_permanent_links.
Be careful however not to have some particular content with several urls. I fear it would be considered as duplicate content by Google and co. and very, very bad for CEO. Or, if you realy need to do this, be sure to use the “canonical” meta, to point to the “true” page. I think Stef talked about it, search the forum.
Maybe some developers will reveal some potential problems with this. For exemple, I’d like to be sure that security is not compromised by such unusual setup. I wouldn’t see why, but who knows?
Keep in mind that the admin-side will be the same for each site. If you want to hide some sections/parts to some users, you’ll have to use some plugins. Total separation is not possible, and would be better served by really distinct TXP install.
Cheers
Pascal
Last edited by PascalL (2009-12-15 23:51:37)
Offline
Re: Sub domain micro sites with TxP
Thanks maniqui and Pascal for your very useful suggestions. I will take a look at them all and see which one best fits how the client wants this to work.
maniqui wrote:
As you also suggest, I’ve solved this by using the chs_cookie plugin (a modified version that I can share with you) and storing a cookie to remember where the visitor is coming from. Then, I used the value of the cookie to create the main navigation properly
Maniqui, please would you let me have a copy of your updated version of chs_cookie and a few more details of how you have used it, this looks like it might be the easiest way to go.
Thanks again to you both.
Steve
Last edited by springworks (2009-12-16 09:55:56)
Offline
Re: Sub domain micro sites with TxP
A) A sub-domain setup is a totally different issue compared to sub-folders when talking about search engine success. For gathering traffic a sub-folder setup is always better. A sub-domain setup creates different websites and a sub-domain owner will never participate from the search engine ‘love’ for the main site.
For franchise websites I would use the sub-folder (TXP sections) setup.
B) I wouldn’t use Textpattern for a sub-domain setup. Instead I would check PivotX or Drupal which are very smart for 1. community setup (roles etc.) and 2. for running different domains with one database.
Get all online mentions of Textpattern via OPML subscription: TXP Info Sources: Textpattern RSS feeds as dynamic OPML
Offline
Re: Sub domain micro sites with TxP
merz1 wrote:
A) A sub-domain setup is a totally different issue compared to sub-folders when talking about search engine success. For gathering traffic a sub-folder setup is always better. A sub-domain setup creates different websites and a sub-domain owner will never participate from the search engine ‘love’ for the main site.
For franchise websites I would use the sub-folder (TXP sections) setup.
B) I wouldn’t use Textpattern for a sub-domain setup. Instead I would check PivotX or Drupal which are very smart for 1. community setup (roles etc.) and 2. for running different domains with one database.
So for the best SEO experience for the franchise websites you would recommend using example.com/franchise1 over franchise1.example.com ?
Since the existing website is already using Textpattern, swapping it all over to another CMS is not an option. Whichever technique I go for, it will be using Textpattern.
Offline
Pages: 1