I was wondering if im doing something wrong or what ? I have subdomain pointing to my server IP ( public ip of my server ) but when ever i go to my subdomain it show me the default page of Apache. Yes I'm using name virtual hosts but still nothing ...
For now i have put the page in the html directory, and it works ok but i think that is not the solution. And yes i can point my subdomain to subdomain.domain.com/thepage but this i don't want to do. And here is what i have in conf. part
NameVirtualHost *:80
<VirtualHost *:80>
ServerName subdomain.domain.com
DocumentRoot /var/www/
ServerAlias www.subdomain.domain.com
</VirtualHost>
Any suggestion ?
This is what i've got ..
NameVirtualHost *:80
<VirtualHost *:80>
ServerName domain.com
DocumentRoot /var/www/ - here is domain.com ( there is directory named ivan )
ServerAlias www.domain.com
</VirtualHost>
NameVirtualHost *:80
<VirtualHost *:80>
ServerName subdomain1.domain.com
DocumentRoot /var/www/ - and here is subdomain1.domain.com - directory named sub1
ServerAlias www.subdomain1.domain.com
</VirtualHost>
NameVirtualHost *:80
<VirtualHost *:80>
ServerName subdomain2.domain.com
DocumentRoot /var/www/ - and here is subdomain2.domain.com - directory named sub2 ( And I don't know if they need to be the same name as the address or ??? sometimes I'm confused about that. )
ServerAlias www.subdomain2.domain.com
</VirtualHost>
And all i got is default page of Apache ...