百度NOTORM找到该库的官网 :http://www.notorm.com/
打开E:AppServphp7php.ini
找到extension=php_pdo_mysql.dll
解开前面的;
demo:
强烈注意:索引是从1开始的
include "NotORM.php"; $pdo = new PDO("mysql:host=localhost;dbname=myshop","root","202063sb"); $db = new NotORM($pdo); //shop_news为表名 foreach ($db->shop_news() as $news) { echo $news["news_title"]; }