[Resolved] Mod_rewrite assistance

SpaceshipSpaceship
SpaceshipSpaceship
SpaceshipSpaceship
Watch

jdk

VIP Member
Impact
100
mod_rewrite assistance

I am trying to do the following using mod_rewrite:

www.domain.com/test.com

It will then take and turn test.com into a variable called $domain
 
0
Close
The views expressed on this page by users and staff are their own, not those of NamePros.
GoDaddyGoDaddy
Code:
RewriteEngine On
RewriteBase /
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ /index.php?domain=$1 [L]
PHP:
$domain = $_GET['domain'];
 
2
Close
Thanks, was looking everywhere for that. Repped
 
Last edited:
0
Close
Daniel said:
Code:
RewriteEngine On
RewriteBase /
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ /index.php?domain=$1 [L]
PHP:
$domain = $_GET['domain'];

Repped, was looking for that as well.
 
0
Close
AIVikingsAIVikings

We're social

Escrow.com
Spaceship
Domain Recover
CryptoExchange.com

NamePros updates

The forum home page in the new NamePros Dark style
NamePros Dark has a new look
The dark style of the forum is now darker. The page is close to black, with a slight blue tint. New style: NamePros Dim Do you...
AIVikings
Catchy
  • The sidebar remains visible by scrolling at a speed relative to the page’s height.
Back