$con = new PDO("mysql:host=localhost;dbname=test",'root',''); $start = 1; $rows = 5; $sql = "select * from users limit :start,:rows"; $sth = $con->prepare($sql); $sth->execute(array(':start'=>$start,':rows'=>$rows)); $arr = $sth->fetchAll(); print_r($arr); $con = null;
请问大神这个是哪儿出问题了
一朵大白天