I was wondering which method is best for passing users information from page to page. For instance, the unique user ID, would it be best to encrypt it and then pass it into the url,like this
$id= md5($row['user_id'])
http://siteName.com?ud=$id
or would it be better to use sessions to store the variable, like this
$_SESSION['user_id'] = $row['user_id']
I would like to know which is best and why, but I think both would work just fine, but I do not know for security issues.... Thanks