[Typo3] What is the best way to set up a multiple site with subdomains?
Michiel Roos
typo3 at monosock.org
Fri Dec 9 16:29:32 CET 2005
Gilles,
Here's what I think should be going on a working setup using multiple
domains in a single Typo3 install on a single IP address;
- point as many names as you like to put.your.ip.here
- the domain names may also be c-names, doesn't matter as long as the
lowest name points to the webservers IP.
- The webserver should know what 'names' to listen to. I guess your
provider calls this 'sub domains' and that these are configurable via your
cpanel.
- For simplicities sake I would start out without any redirection.
- For simplicities sake, disable realurl when setting up.
If this is done All names e.g. *.critterpal.com and
*.sunshinelocksmith.com should point to your Typo3 root. This should mean
that you can access the backend via *.critterpal.com/typo3 or
*.sunshinelocksmith.com/typo3. You should in no case be locked out of the
backend.
I have several virtual domains configured seperate page trees in the typo3
root;
GLOBE
|-+ www.critterpal.com
|-+ monkey.critterpal.com
\-+ whatever.sunshinelocksmith.com
I always use the main domain name for the name of the root page of every
page tree for clarity.
Every page tree root-page may have several domain records.
Your setup should now work.
On Fri, 09 Dec 2005 09:37:09 -0500, Gilles Deacur wrote:
> When I type in www.critterpal.com, it actually goes to
> critterpal.sunshinelocksmith.com (or sunshinelocksmith.com/critterpal,
> I'm not sure) but it displays as www.critterpal.com because it's an
> addon domain.
When I type www.critterpal.com, I am redirected to
http://admin-maint.sunshinelocksmith.com/index.php?id=1
I think this should not be happening the redirect is still in place?
> www.sunshinelocksmith.com is my master domain, but I have Typo3
> installed in a subdomain (or folder) called "admin-maint". I did this
> because I have an index.php file in the root of sunshinelocksmith.com
> and installing Typo3 into my "master domain" would knock my functioning
> site first page off-line. So I put it in a subdomain thinking it would
> work the same admin-wise not thinking about the problems I'm having at
> the moment.
Ok, so the currently running sunshinelocksmith.com site is on the same
server. This is an interesting setup ;-).
I have no idea how cpanel handles stuff behind the scenes. Does it do
rewriting of its own? Or does it create a separate vhost entry for every
subdomain? It feels like vhost.
If it creates a separate vhost for every subdomain, then all your other
'listening domains' should be listed as ServerAlias in that same vhost
entry. As I said in my first post.
If you cannot do this through cpanel (create aliases for a certain
subdomain), please contact your hosting provider and explain your problem.
You need aliasing.
> I told cpanel to add critterpal.com as a subdomain.
>
> Should I then tell cpanel to remove the subdomain?
>
> I already have the DNS pointing to the nameserver of my shared IP
> address. Do I keep the DNS pointing to the same nameservers? I guess
> there really isn't much of a choice. That's the only setting my name
> registrar gives me.
>
> However, I can modify another name www.gotpet.net and use that as the
> domain "base" instead of critterpal. I have a few extra settings to
> play with on that registrar, including http redirect and frame
> forward(yuck... no frames).
>
> Yeah, I already have a domain listed in the pageroot as follows
> (secondary fields are on):
> Domain: www.critterpal.com
> Redirect to: {blank}
> Transfer parameters {blank}
> and:
> Domain: www.gotpet.net
> Redirect to: {blank}
> Transfer parameters {blank}
> These are in the root page. I have "Home Page" shortcut to the root page.
> That's good. (I think.)
Yup, looks fine and dandy to me.
> Also, in my AutoParser template setup field I have all this crap:
> config.simulateStaticDocuments = 0
> config.baseURL = 1
> config.baseURL = http://admin-maint.sunshinelocksmith.com/
> config.tx_realurl_enable = 1
> config.prefixLocalAnchors = all
> # Configuring the Auto-Parser:
> plugin.tx_automaketemplate_pi1 {
> # Read the template file:
> content = FILE
> content.file = fileadmin/critterpal/template.htm
> # Here we define which elements in the HTML that
> # should be wrapped in subpart-comments:
> elements {
> BODY.all = 1
> BODY.all.subpartMarker = DOCUMENT_BODY
> HEAD.all = 1
> HEAD.all.subpartMarker = DOCUMENT_HEADER
> HEAD.rmTagSections = title
> TD.all = 1
> }
> # Prefix all relative paths with this value:
> # relPathPrefix = http://www.critterpal.com/
> }
I see, I would leave realurl out for a start.
> (I've played with www.critterpal.com and other names for the baseURL but
> my css and images break, so this is working at the moment, but probably
> isn't correct.)
> Notice the relPathPrefix as well. This is currently commented out, but
> I was playing with this to see if I could get things working. I've
> played with several varieties of the path.
>
> Hey, I REALLY appreciate you taking time out of your day to help me with
> this. I really pored over the documentation and googled my fingers off
> to get this to go so I wouldn't need to bother anybody with this, but I
> was a day away from switching to phpwcms. I really, really, really
> didn't want to go the "quitter" route.
I think it would be just as daunting to get this to work on a subdomain
using phpwcms.
Do you consider it an option to 'move' your base sunshinelocksmith.com
site to a subdomain and install typo3 smack hard in the root? Provided
that you are positive that it would then still function properly?
Cheers,
Michiel Roos
More information about the TYPO3-english
mailing list