View Single Post
  #9  
Old 23rd February 2008, 00:32
make-fun make-fun is offline
Member
 
Join Date: Jan 2008
Posts: 92
Thanks: 8
Thanked 8 Times in 7 Posts
Default

Quote:
Originally Posted by till
You can do this with custom rewrite rules.

http://www.howtoforge.com/forums/showthread.php?t=12783
Hi Till,
I've been reading all the info on subdomains — including people wondering if it could be implemented in ISPConfig to have "permanent" subdomains without adding the "RewriteEngine Opton" manually, using this option Co/sub-domains without rewritten

Here's what I was planning on doing about it myself…
I was going to simply add a prefix to the name of the "subdomain" as I insert it into the HOST inputfield.
Like this:
Host: perma_mysubdomain
Domain: example.com

Then add a little switch with something like
PHP Code:
if(substr($domain["domain_weiterleitung"],0,6) == "perma_"){
// remove the prefix
// then change the $rewrite_rule by removing the [R]
$rewrite_rule .= "\nRewriteRule   ^/(.*)$  http://".$servername.$domain["domain_weiterleitung"]."$1 ";

in /root/ispconfig/scripts/lib/config.lib.php around ~ line 1374

So there'd be no big changes within the DB or so, the "Prefix-Option" could just be added as a simple text hint next to the input field "Host:"
Or, to make it nice and simple… at some time in future, be done with a set of radio buttons or what ever…

Any thoughts on that Till — I've not done it jet, it was rather some brainstorming so far

Cheers

Last edited by make-fun; 23rd February 2008 at 00:45.
Reply With Quote