I'm using $id = intval( $_REQUEST['id'] );
, to get ID of the news/posts on my website, and the link to the news is article.php?id=XXX. So when someone type ?id=1 and there's nothing it's empty, no posts, it should go to index page (index.php) instead showing blank page. Is it possible? I've tried via isset something but it didn't worked. Can anyone help me with this, please.
if($ArticleSQL = $mysqli->query("SELECT * FROM articles WHERE id='$id' ")){
...
}