- 相關(guān)推薦
php中zend相對(duì)路徑問(wèn)題
php下使用zend相對(duì)路徑的處理方法。如何使用呢?就跟隨百分網(wǎng)小編一起去了解下吧,想了解更多相關(guān)信息請(qǐng)持續(xù)關(guān)注我們應(yīng)屆畢業(yè)生考試網(wǎng)!
<?php
define ('P_S', PATH_SEPARATOR);
define ('ROOT', "../");
set_include_path(ROOT .P_S .'Zend' .P_S .ROOT.get_include_path());
require_once ROOT.'Zend/Loader.php';
Zend_Loader::loadClass('Zend_Db');
Zend_Loader::loadClass('Zend_Config_Ini');
Zend_Loader::loadClass('Zend_Page');
$config = new Zend_Config_Ini('../inc/config.php', 'general');
$db = Zend_Db::factory($config->db->adapter,$config->db->config->toArray());
?>
<?
//查詢
$select=$db->select();
$select->from("UserGroup","*");
$action_log=$db->fetchAll($select);
foreach ($action_log as $arr){
?>
<input type="checkbox" name="usergroup[]" id="usergroup[]" value="<?=$arr['lsh']?>"> <? echo $arr['Name'];?>
<?
}
?>
【php中zend相對(duì)路徑問(wèn)題】相關(guān)文章:
php內(nèi)核分析之ZTS和zend-try03-20
完美解決PHP中文亂碼問(wèn)題12-06
php字符串截取問(wèn)題11-17
PHP中this關(guān)鍵字03-28
PHP前端開(kāi)發(fā)中的性能03-28
PHP中實(shí)現(xiàn)頁(yè)面跳轉(zhuǎn)12-06
php中引用的用法分析04-01