grab properly the id from the url