Page 1 of 1

need some help

Posted: Mon Jun 30, 2003 9:27 pm
by anfx
Hello,

I have a short domain name that I would like to use for all of my linking.

Let's say the domain is dom.com and I want dom.com/link2 to be able to access my sql database pull up the 'link2' link, which let's say is somebigdomain.com/link.php and then automatically redirect me to that url.

Does anybody know on how I can accomplish this?

Thanks,

Andy

Posted: Mon Jun 30, 2003 9:42 pm
by m3rajk
i know there is a php function for it, but i don't know that.

here's some htmkl for the link page to call to then fwd to the page at the big domain (note, needs to be in the <hea></head> tags)

<meta http-equiv="refresh" content="0;url=http://www.somebigdomain.com/actualpage.php">

Posted: Tue Jul 01, 2003 12:51 am
by Tubbietoeter
first youll need a database with the links in it, and then you implement a php site that takes a given variable, and pulls the link for the given variable out of the database.

you call your php site with http://www.thisistheurl.com/get_link.php?linkid=1

or

you call your php site with http://www.thisistheurl.com/get_link.php?linkid=5

or

....

the php script "get_link.php" must take the content of the variable $_GET['linkid'] and search for it in the db.

"select link from linktable where linkid = ".$linkid

then you either include the link or you reference it lile m3rajk told you to