Go Back   HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials > ISPConfig 3 > Developers' Forum

Do you like HowtoForge? Please consider supporting us by becoming a subscriber.
Reply
 
Thread Tools Display Modes
  #1  
Old 19th August 2009, 02:39
moglia moglia is offline
Member
 
Join Date: Apr 2009
Posts: 92
Thanks: 7
Thanked 15 Times in 11 Posts
Exclamation How Subdomain works (for documentation)

I will starts produce of end user documentation anyone can explain how subdomain works im looking at apache alias points subdomain for the same document root of main site.

Host
DOMAIN
REDIRECT TYPE - No Redirect - No Flag - R - L - R,L
PATH

Active - Y

I need explanations how REDIRECT TYPE works.
its possible create a independent virtualhost for subdomain?
(see workarround)

How subdomain can use another document root.

domain inclusion creates folders: cgi-bin log ssl tmp web

subdomain can use a folder like: subdomain name?

at the same level of web (document root)

cgi-bin log ssl tmp web subdomain

The main question is can specify another document root for subdomain?

If not possible specify a subdomain document root i no see any diferences between server alias and subdomain.

i think alias can redirect one domain to another using virtual redirect. one domain to another.

My workarround i created subdomain as independent website.

My idea is create subdomain with another document root with the same virtual hosting settings. share setting (main domain and subdomain).
Reply With Quote
Sponsored Links
  #2  
Old 19th August 2009, 10:37
till till is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lneburg, Germany
Posts: 37,015
Thanks: 840
Thanked 5,651 Times in 4,461 Posts
Default

Quote:
My workarround i created subdomain as independent website.
This is no workaround, it is the intended way of doing it. If you want a website, create a website. It does not matter for a website if a domain is a.com a.a.com or a.a.a.com

Quote:
If not possible specify a subdomain document root i no see any diferences between server alias and subdomain.
The difference is very easy. An alias domain can be any domain while a subdomain can just be a subdomain. This is a often requested feature and separation from hosters as many of them allow free subdomains but not free alias domains.
__________________
Till Brehm
--
Get ISPConfig support and the ISPConfig 3 manual from ispconfig.org.
Reply With Quote
  #3  
Old 5th April 2010, 01:14
trondhuso trondhuso is offline
Junior Member
 
Join Date: Mar 2010
Location: Mysen, Norway
Posts: 24
Thanks: 1
Thanked 3 Times in 2 Posts
Default

Quote:
Originally Posted by till View Post
This is no workaround, it is the intended way of doing it. If you want a website, create a website. It does not matter for a website if a domain is a.com a.a.com or a.a.a.com



The difference is very easy. An alias domain can be any domain while a subdomain can just be a subdomain. This is a often requested feature and separation from hosters as many of them allow free subdomains but not free alias domains.
To make it even more obvious:
With an alias you can do this:
main domain: example.com
alias: example.net (will point to example.com)
alias: example.org (will point to example.com)
alias: domain.com (will point to example.com)

To till:
What people are reacting to is how subdomains are created.
Example:
(probably a typical one): blog.domain.com
The way ISP Config 3 wants us to do this by using the sub-domain menu, it will actually be the same as: www.domain.com/blog
Which sometimes is OK, unless you would like to have a subdomain like test.domain.com where you want to test your application with a different setting.
In Plesk they do it like this:
directory-structure:
-domain.com
--web
--subdomain
----test
------web
And the information regarding the subdomain is found in the vhost-file for the domain.

You should probably ask users how they implement sub domains. if it is the www.domain.com/test eq test.domain.com then do no changes.
If it is that people go and create a new website as test.domain.com, then I would consider changing the way ISP Config handles sub domains.
I for one support the latter as I am often testing out client websites in a sub domain (client.domain.com) before putting them into production (www.client.com).
Reply With Quote
  #4  
Old 5th April 2010, 10:30
till till is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lneburg, Germany
Posts: 37,015
Thanks: 840
Thanked 5,651 Times in 4,461 Posts
Default

There is absolutely no need to change the way ispconfig handles subdomains as you just created the subdomain the wrong way. If you like to have a separate directory for a subdomain, you simply click on new website, enter sub.domain.com into the domain field and click on save.

If you want to test a website before you put it in production, you just click on new website, enter test.cdomain.com into the domain field and click on save. If the site shall go live, you edit the website settings and change test.domain.com to domain.com abd click on save. Thats all.
__________________
Till Brehm
--
Get ISPConfig support and the ISPConfig 3 manual from ispconfig.org.
Reply With Quote
  #5  
Old 12th June 2010, 12:21
we_are_borg we_are_borg is offline
Junior Member
 
Join Date: Aug 2008
Posts: 7
Thanks: 1
Thanked 0 Times in 0 Posts
Default

Quote:
Originally Posted by till View Post
There is absolutely no need to change the way ispconfig handles subdomains as you just created the subdomain the wrong way. If you like to have a separate directory for a subdomain, you simply click on new website, enter sub.domain.com into the domain field and click on save.

If you want to test a website before you put it in production, you just click on new website, enter test.cdomain.com into the domain field and click on save. If the site shall go live, you edit the website settings and change test.domain.com to domain.com abd click on save. Thats all.
Till if i make a subdomain as a new website i will get the desired effect namely domain.tld and subdomains.domain.tld all with different logins and pass as a bonus. But would this system not break Ajax requests or will Ajax see it as one domain even its split up.
Reply With Quote
  #6  
Old 13th June 2010, 16:31
till till is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lneburg, Germany
Posts: 37,015
Thanks: 840
Thanked 5,651 Times in 4,461 Posts
Default

Quote:
But would this system not break Ajax requests or will Ajax see it as one domain even its split up.
I guess the way a subdomain gets implemented in apache has no influence on ajax, as the client does not know if a subdomain is redirected by a rewrite rule or if its a separate vhost.
__________________
Till Brehm
--
Get ISPConfig support and the ISPConfig 3 manual from ispconfig.org.
Reply With Quote
  #7  
Old 19th June 2010, 17:05
Croydon Croydon is offline
ISPConfig Developer
 
Join Date: Jul 2007
Location: Koblenz, Germany
Posts: 932
Thanks: 16
Thanked 264 Times in 208 Posts
Default

A question regarding this "subdomains" thing has just come up...

The situation is as follows:
Clients have 1 Domain mydomain.com and they shall NOT be able to add further domains like mysecond.com to their ispc account - so I have to limit the web-domain thing to 1.
BUT: The clients shall be able to add subdomains like happywith.mydomain.com with separate login data and root path.
This is not possible with the Subdomain function of ispc and as the website limit is set to 1 - not possible with the add website function either.
If I raise the website limit to 5 to allow such subdomains - users could add external domains to their account.

Is there any solution for this?
Reply With Quote
  #8  
Old 19th June 2010, 23:14
till till is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lneburg, Germany
Posts: 37,015
Thanks: 840
Thanked 5,651 Times in 4,461 Posts
 
Default

In SVN you find a domain module which allos to restrict the domains for websites by the admin user.
__________________
Till Brehm
--
Get ISPConfig support and the ISPConfig 3 manual from ispconfig.org.
Reply With Quote
Reply

Bookmarks

Tags
apache, subdomain, virtual host

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Guidance needed for setting up a subdomain, please manarak Installation/Configuration 16 17th June 2009 20:03
ipsconfig 3 * subdomain planks Installation/Configuration 15 18th February 2009 10:52
PHP not processing on subdomain hybridstorm General 1 20th July 2006 14:29
Subdomain works only localy marclar General 2 16th June 2006 00:02
Subdomain with Webspace nsm Installation/Configuration 1 13th June 2006 11:39


All times are GMT +2. The time now is 14:31.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.