NameSilo

[Resolved] Mod_rewrite assistance

Spaceship Spaceship
Watch

jdk

VIP Member
Impact
98
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
•••
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
•••
Thanks, was looking everywhere for that. Repped
 
Last edited:
0
•••
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
•••
Dynadot — .com Registration $8.99Dynadot — .com Registration $8.99
Appraise.net

We're social

Unstoppable Domains
Domain Recover
DomainEasy — Live Options
  • The sidebar remains visible by scrolling at a speed relative to the page’s height.
Back