Quantcast

Wildcard DNS | Domain | Subdomain

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
12 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Wildcard DNS | Domain | Subdomain

swimwithabhra
Hi!
Can anybody tell me what does it takes to get a website with "wildcard
dns" configured and properly functional.

I read about wildcard DNS and the following are my findings -:

1. Need to add a A type record [as my hosting company is godaddy and
they doesn't support CNAME]
2. Add ServerAlias in VirtualHost of httpd.conf
3. Upload .htaccess with necessary modifications.

I am using CakePHP and i have tried performing all the three steps.
But whenever I type something like
xyz.domain.com [say domain.com is my domain] in the URL I get a "404
Error-Page not found".

I would really appreciate if anyone would let me know what exactly I
need to do to make this working.

Thanks.

--
Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org 
Check out the new CakePHP Questions site http://ask.cakephp.org and help others with their CakePHP related questions.


To unsubscribe from this group, send email to
[hidden email] For more options, visit this group at http://groups.google.com/group/cake-php
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Wildcard DNS | Domain | Subdomain

Daniel S. Reichenbach-2
Greetings,

> 3. Upload .htaccess with necessary modifications.
Why would you want to modify .htaccess? This step is not
needed for CakePHP to work on multiple subdomains.

> I am using CakePHP and i have tried performing all the three steps.
> But whenever I type something like
> xyz.domain.com [say domain.com is my domain] in the URL I get a "404
> Error-Page not found".
Have you properly configured your <VirtualHost ... /> settings inside
Apache? You need one virtual host for domain.com, and one to be used
for any name using *.domain.com, and *both have to point to the same
DocumentRoot*.

WkR,
Daniel S. Reichenbach

--
Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org 
Check out the new CakePHP Questions site http://ask.cakephp.org and help others with their CakePHP related questions.


To unsubscribe from this group, send email to
[hidden email] For more options, visit this group at http://groups.google.com/group/cake-php
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Wildcard DNS | Domain | Subdomain

Ryan Schmidt

On Mar 29, 2011, at 06:00, Daniel S. Reichenbach wrote:

> Have you properly configured your <VirtualHost ... /> settings inside
> Apache? You need one virtual host for domain.com, and one to be used
> for any name using *.domain.com, and *both have to point to the same
> DocumentRoot*.

No reason you can't to both within the same VirtualHost.

<VirtualHost *:80>
        ServerName example.com
        ServerAlias *.example.com
        DocumentRoot /path/to/cakephp/app
        ...
</VirtualHost>



--
Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org 
Check out the new CakePHP Questions site http://ask.cakephp.org and help others with their CakePHP related questions.


To unsubscribe from this group, send email to
[hidden email] For more options, visit this group at http://groups.google.com/group/cake-php
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Wildcard DNS | Domain | Subdomain

Daniel S. Reichenbach-2
> No reason you can't to both within the same VirtualHost.
>
> <VirtualHost *:80>
> ServerName example.com
> ServerAlias *.example.com
> DocumentRoot /path/to/cakephp/app
> ...
> </VirtualHost>
True, but you may want to run a different CakePHP application on the
main site in some cases :D

WkR,
Daniel

--
Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org 
Check out the new CakePHP Questions site http://ask.cakephp.org and help others with their CakePHP related questions.


To unsubscribe from this group, send email to
[hidden email] For more options, visit this group at http://groups.google.com/group/cake-php
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Wildcard DNS | Domain | Subdomain

lowpass
In reply to this post by swimwithabhra
On Tue, Mar 29, 2011 at 4:13 AM, swimwithabhra <[hidden email]> wrote:

> Hi!
> Can anybody tell me what does it takes to get a website with "wildcard
> dns" configured and properly functional.
>
> I read about wildcard DNS and the following are my findings -:
>
> 1. Need to add a A type record [as my hosting company is godaddy and
> they doesn't support CNAME]
> 2. Add ServerAlias in VirtualHost of httpd.conf
> 3. Upload .htaccess with necessary modifications.
>
> I am using CakePHP and i have tried performing all the three steps.
> But whenever I type something like
> xyz.domain.com [say domain.com is my domain] in the URL I get a "404
> Error-Page not found".

Make sure debug is set to 2. If it's 0, any error in your code will
throw a 404, which can lead one to think there's a routing problem.

--
Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org 
Check out the new CakePHP Questions site http://ask.cakephp.org and help others with their CakePHP related questions.


To unsubscribe from this group, send email to
[hidden email] For more options, visit this group at http://groups.google.com/group/cake-php
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Wildcard DNS | Domain | Subdomain

swimwithabhra
Hi all,
thanks for all your suggestions.

I will talk to my hosting provider to check whether the virtualhost
and other server configurations are correctly done or not.
The following is the htaccess I am using -:

<IfModule mod_rewrite.c>
        RewriteEngine On
        RewriteCond %{REQUEST_FILENAME} !-d
        RewriteCond %{REQUEST_FILENAME} !-f
        RewriteCond %{HTTP_HOST} ^([^.]+)\.?domain\.com [NC]
        RewriteCond %1 !^(www)?$ [NC]
        RewriteRule ^([^/]*)/?([^/]*)?/?$ index.php?user=%1&url=$1 [QSA,L]
</IfModule>

As I am not good with htaccess I am not sure whether it is correct or
not.

I will be waiting for your valuable comments on the above.
Thanks.

--
Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org 
Check out the new CakePHP Questions site http://ask.cakephp.org and help others with their CakePHP related questions.


To unsubscribe from this group, send email to
[hidden email] For more options, visit this group at http://groups.google.com/group/cake-php
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Wildcard DNS | Domain | Subdomain

swimwithabhra
In reply to this post by Daniel S. Reichenbach-2
> > 3. Upload .htaccess with necessary modifications.
>
> Why would you want to modify .htaccess? This step is not
> needed for CakePHP to work on multiple subdomains.

Hello Daniel,
What I am trying to do is to access virtual sub domains [non existing
sub domains] for each individual user of my website. This means that
one can access my website by daniel.domain.com and xyz.domain.com and
abc.domain.com and ....... I read the following article where I found
out configuring .htaccess -:
http://www.mail-archive.com/cake-php@.../msg03990.html

Can you please let me know what steps would be enough to achieve the
above.

Thanks.

--
Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org 
Check out the new CakePHP Questions site http://ask.cakephp.org and help others with their CakePHP related questions.


To unsubscribe from this group, send email to
[hidden email] For more options, visit this group at http://groups.google.com/group/cake-php
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Wildcard DNS | Domain | Subdomain

bujanga
Do what Ryan suggested for getting your apache set up correctly.

Get rid of that .htaccess file and cake until you know apache can
serve a simple index.htm.

Now about the .htaccess file, is this line really in it?
"RewriteCond %{HTTP_HOST} ^([^.]+)\.?domain\.com [NC]"

On Wed, Mar 30, 2011 at 2:05 AM, swimwithabhra <[hidden email]> wrote:

>> > 3. Upload .htaccess with necessary modifications.
>>
>> Why would you want to modify .htaccess? This step is not
>> needed for CakePHP to work on multiple subdomains.
>
> Hello Daniel,
> What I am trying to do is to access virtual sub domains [non existing
> sub domains] for each individual user of my website. This means that
> one can access my website by daniel.domain.com and xyz.domain.com and
> abc.domain.com and ....... I read the following article where I found
> out configuring .htaccess -:
> http://www.mail-archive.com/cake-php@.../msg03990.html
>
> Can you please let me know what steps would be enough to achieve the
> above.
>
> Thanks.
>
> --
> Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org
> Check out the new CakePHP Questions site http://ask.cakephp.org and help others with their CakePHP related questions.
>
>
> To unsubscribe from this group, send email to
> [hidden email] For more options, visit this group at http://groups.google.com/group/cake-php
>

--
Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org 
Check out the new CakePHP Questions site http://ask.cakephp.org and help others with their CakePHP related questions.


To unsubscribe from this group, send email to
[hidden email] For more options, visit this group at http://groups.google.com/group/cake-php
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Wildcard DNS | Domain | Subdomain

swimwithabhra
Hi all,
I am glad to inform you that finally wildcard DNS is working for me.
I just add a A type record and added server alias in virtual host. I
didn't have to change anything in the .htaccess file.

Thank you all for your kind support.

Regards,

Abhra Banerjee

--
Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org 
Check out the new CakePHP Questions site http://ask.cakephp.org and help others with their CakePHP related questions.


To unsubscribe from this group, send email to
[hidden email] For more options, visit this group at http://groups.google.com/group/cake-php
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Wildcard DNS | Domain | Subdomain

euromark (munich)
if the document root is correctly set, everything should work:
DocumentRoot /path/to/cakephp/app/webroot/

always down to webroot

On 4 Apr., 07:39, swimwithabhra <[hidden email]> wrote:

> Hi all,
> I am glad to inform you that finally wildcard DNS is working for me.
> I just add a A type record and added server alias in virtual host. I
> didn't have to change anything in the .htaccess file.
>
> Thank you all for your kind support.
>
> Regards,
>
> Abhra Banerjee

--
Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org 
Check out the new CakePHP Questions site http://ask.cakephp.org and help others with their CakePHP related questions.


To unsubscribe from this group, send email to
[hidden email] For more options, visit this group at http://groups.google.com/group/cake-php
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Wildcard DNS | Domain | Subdomain

Rajaram indira
In reply to this post by swimwithabhra
Hi swimwithabhra,

     Can you help me to implement this with cakephp 3.x

On Wednesday, March 30, 2011 at 11:57:35 AM UTC+5:30, swimwithabhra wrote:
Hi all,
thanks for all your suggestions.

I will talk to my hosting provider to check whether the virtualhost
and other server configurations are correctly done or not.
The following is the htaccess I am using -:

<IfModule mod_rewrite.c>
        RewriteEngine On
        RewriteCond %{REQUEST_FILENAME} !-d
        RewriteCond %{REQUEST_FILENAME} !-f
        RewriteCond %{HTTP_HOST} ^([^.]+)\.?domain\.com [NC]
        RewriteCond %1 !^(www)?$ [NC]
        RewriteRule ^([^/]*)/?([^/]*)?/?$ index.php?user=%1&url=$1 [QSA,L]
</IfModule>

As I am not good with htaccess I am not sure whether it is correct or
not.

I will be waiting for your valuable comments on the above.
Thanks.

--
Like Us on FaceBook https://www.facebook.com/CakePHP
Find us on Twitter http://twitter.com/CakePHP

---
You received this message because you are subscribed to the Google Groups "CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at https://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Wildcard DNS | Domain | Subdomain

Rajaram indira
In reply to this post by swimwithabhra
Hi Abhra,

      I'm doing Wildcard DNS with cakephp 3.x. But I can't found exact solution for this problem. Can you help me to fix this problem.

On Monday, April 4, 2011 at 11:09:45 AM UTC+5:30, swimwithabhra wrote:
Hi all,
I am glad to inform you that finally wildcard DNS is working for me.
I just add a A type record and added server alias in virtual host. I
didn't have to change anything in the .htaccess file.

Thank you all for your kind support.

Regards,

Abhra Banerjee

--
Like Us on FaceBook https://www.facebook.com/CakePHP
Find us on Twitter http://twitter.com/CakePHP

---
You received this message because you are subscribed to the Google Groups "CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at https://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/d/optout.
Loading...