Results 1 to 4 of 4

Thread: How to create subdomains in php via script?

  1. #1

    Thread Starter
    New Member
    Join Date
    Sep 2008
    Posts
    1

    How to create subdomains in php via script?

    How to create subdomains in php via script?

  2. #2
    I'm about to be a PowerPoster!
    Join Date
    Jan 2005
    Location
    Everywhere
    Posts
    13,647

    Re: How to create subdomains in php via script?

    If you modify the access level of the web browser's configuration file (usually 'httpd.conf' or similar) appropriately, you could read from and write to that file using a PHP script.

  3. #3
    Frenzied Member the182guy's Avatar
    Join Date
    Nov 2005
    Location
    Cheshire, UK
    Posts
    1,473

    Re: How to create subdomains in php via script?

    Hi dineshmatolia,

    penegate is hinting that you can create subdomains by adding rules to the httpd.conf file. So your going to need permission to access that file. If you're on a shared host then it is unlikely that they will allow you to write to that file.

    They may allow you to create subdomains via a control panel however.
    Chris

  4. #4
    I'm about to be a PowerPoster!
    Join Date
    Jan 2005
    Location
    Everywhere
    Posts
    13,647

    Re: How to create subdomains in php via script?

    You'll also need to modify your DNS records appropriately. If you haven't already, I suggest adding a catch-all (wildcard) record, which will allow you to receive all requests to your domain regardless of subdomain. You can then control the subdomains via your web server's configuration file, if you have the appropriate access rights. I agree that on shared hosting this is less likely to be possible.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width