TalkPHP
 
 
Account Login
Latest Articles
» The basic usage of PHPTAL, a XML/XHTML template library for PHP
» Vulnerable methods and the areas they are commonly trusted in.
» Simple way to protect a form from bot
» The Basics On: How Session Stealing Works
» How to keep your forms from double posting data
IRC Channel
IRC Speech Bubble Join the friendly bunch on IRC...
(#TalkPHP on Freenode)

...Also available via a web interface.

See this thread for information on the TalkPHP Free Hugs Initiative™. Subject to availability.
Associates
Associates
CSS Tutorials
Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old 04-17-2008, 02:18 AM   #1 (permalink)
The Wanderer
 
Join Date: Apr 2008
Posts: 15
Thanks: 0
kororo203 is on a distinguished road
Default email link validation (need hekp)

er.. i got a problem...

can think of how i can get a link to be valid... i know that i can make use of parse url and split to get the info about the url but how about redirecting it to my site.. how would it be a valid link

take this for example...

http://linlk/link/link

now i'm gonna add a hash code for the account activation..


http://linlk/link/link/hashcode
then i'm gonna split it,...

now how can i make this code be a link to my logon site..
consider that my login site is
www.site/logon.php
the adding the code www.site/logon.php(linkandhashcode)

er.. don;tknow how it will work

thanks in advance.. your help is deeply appriciated
kororo203 is offline  
Reply With Quote
Old 04-17-2008, 06:48 AM   #2 (permalink)
The Acquainted
 
EyeDentify's Avatar
 
Join Date: Nov 2007
Location: Sweden
Posts: 106
Thanks: 13
EyeDentify is on a distinguished road
Default

Well just put together a string that you send to the new users email. You could put it together like this perhaps ?
PHP Code:
<?PHP

$szValHash 
md5(microtime());

$szMyLoginUrl 'http://www.mysite.com/login.php?hash=';

$szValUrl $szMyLoginUrl $szValHash;


// Insert $szValUrl where you want to echo the url.

echo('<A HREF="' $szValUrl '" target="_blank">Validate your new account</a>');
?>
Above echo will print something like this:
Code:
<A HREF="http://www.mysite.com/login.php?hash=1f3870be274f6c49b3e31a0c6728957f" target="_blank">Validate your new account</a>
I hope thats whats your after.

Good luck :)
__________________
Of course the whole point of a doomsday machine, would have been lost if you keep it a secret.
EyeDentify is offline  
Reply With Quote
Old 04-17-2008, 07:33 AM   #3 (permalink)
The Wanderer
 
Join Date: Apr 2008
Posts: 15
Thanks: 0
kororo203 is on a distinguished road
Default

hehhehe i think i got that part already butmy problem is really ob how to get the url from the browser address bar.. i had search already in google and yahoo and most of them said that using the parse_url is not a reliable method... but they had suggested using $_GETS where i find it a bit complicated because on most example that i had seen the url is already stored in a variable and they don't say it on the tutorial on how to get it in the address bar.. btw thanx so much...

all helps are appreciated
kororo203 is offline  
Reply With Quote
Old 04-17-2008, 07:45 AM   #4 (permalink)
The Acquainted
 
sjaq's Avatar
 
Join Date: Nov 2007
Location: Netherlands
Posts: 113
Thanks: 11
sjaq is on a distinguished road
Default

$_SERVER['REQUEST_URI']?
sjaq is offline  
Reply With Quote
The Following User Says Thank You to sjaq For This Useful Post:
wiifanatic (04-17-2008)
Old 04-17-2008, 07:48 AM   #5 (permalink)
The Wanderer
 
Join Date: Apr 2008
Posts: 15
Thanks: 0
kororo203 is on a distinguished road
Default

$page = $_SERVER['REQUEST_URI'];
echo $page;

hehehe this works fine thanx....
kororo203 is offline  
Reply With Quote
Reply



Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

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

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


All times are GMT. The time now is 04:48 PM.

 
     

Powered by vBulletin® Version 3.6.8
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.1.0
Inactive Reminders By Icora Web Design