6.7.Propel-smart,easyobjectpersistence

玄學醬發表於2017-12-27

ORM ( object relation mapping )

即將資料庫表對映成對像,實現通過例項化對像來訪問資料庫

本文主要介紹Propel – smart, easy object persistence

6.7.1. 環境配置

配置php.ini

在php.ini檔案中加入:

extension=php_pdo.dll

6.7.2. PEAR Installer

$> pear channel-discover pear.phpdb.org
$> pear install phpdb/propel_generator
$> pear install phpdb/propel_runtime
			

Adding Channel

D:>pear channel-discover pear.phpdb.org
Adding Channel "pear.phpdb.org" succeeded
Discovery of channel "pear.phpdb.org" succeeded
			

propel_generator 安裝日誌

D:php-5.1.4-Win32>pear install phpdb/propel_generator
phpdb/propel_generator requires package "channel://pear.phing.info/phing" (versi
on >= 2.2.0)
downloading creole-1.1.0.tgz ...
Starting to download creole-1.1.0.tgz (92,633 bytes)
.....................done: 92,633 bytes
install ok: channel://pear.phpdb.org/creole-1.1.0
			

propel_runtime 安裝日誌

D:php-5.1.4-Win32>pear install phpdb/propel_runtime
downloading propel_runtime-1.2.0.tgz ...
Starting to download propel_runtime-1.2.0.tgz (45,959 bytes)
.............done: 45,959 bytes
install ok: channel://pear.phpdb.org/propel_runtime-1.2.0

D:php-5.1.4-Win32>
		

原文出處:Netkiller 系列 手札
本文作者:陳景峰
轉載請與作者聯絡,同時請務必標明文章原始出處和作者資訊及本宣告。