Tycoon Talk
Become a Big fish!
The number 1 forum for online business!
Post topics, ask questions, share your knowledge.
Tycoon Talk is part of Freelancer.com - find skilled workers online at a fraction of the cost.

PHP Forum


You are currently viewing our PHP Forum as a guest. Please register to participate.
Login



Freelance Jobs

Reply
A php question! Please help!
Old 04-21-2005, 12:39 PM A php question! Please help!
Junior Talker

Posts: 1
Trades: 0
Hello!
I just need help with a thing for php (I am noob )
Example:
I enter...
www.somesite.com/something.php?name=myg00t
...in the browser...and then i come to:
www.somesite.com/myg00t
myg00t is offline
Reply With Quote
View Public Profile
 
 
Register now for full access!
Old 04-21-2005, 01:35 PM
leavethisplace's Avatar
Ultra Talker

Posts: 297
Trades: 0
before any html output on that page, do:

PHP Code:
<?php

if(isset($_GET[name])) {
 
  
$url_redirect $_GET[name];
  
header("Location: http://www.somesite.com/$url_redirect");

  exit;

}


?>
This could have easily been found using the PHP manual
__________________
A lie gets halfway around the world before the truth has a chance to get its pants on. - Sir Winston Churchill

Please visit my sites:
Please login or register to view this content. Registration is FREE
|
Please login or register to view this content. Registration is FREE

Last edited by leavethisplace; 04-21-2005 at 01:35 PM.. Reason: formatting
leavethisplace is offline
Reply With Quote
View Public Profile
 
Reply     « Reply to A php question! Please help!
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off





   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML



Page generated in 0.13306 seconds with 12 queries