I have a page where I am going to let a user call it like this below
test.php?id=1,2,3,4,5
On my php page I am taking the value of $_GET['id'] and using it like this
$sql = 'SELECT * FROM friend WHERE auto_id in('.$id.')';
$result2= executequery($sql);
So can someone help me to make sure this variable is always good, for instance I want to make sure it never ends with , because if it's like this 1,2,3,4, it would give errors from mysql