Parameterized Queries
问题 I am currently learning parametrized queries as there are advantages to using them. Could someone give some pointers by converting this block of code to a parametrized version? Thanks. if(isset($_GET['news_art_id']) && (!empty($_GET['news_art_id']))) { $news_art_id = htmlentities(strip_tags($_GET['news_art_id'])); $news_art_id = validate_intval($news_art_id); //echo $news_art_id; $_SESSION['news_art_id'] = $news_art_id; // Assign value to status. $onstatus = 1; settype($onstatus, 'integer');