Merge branch 'devel' of dev.sourcefabric.org:airtime into devel
This commit is contained in:
commit
23ee726cfd
|
@ -1,6 +1,6 @@
|
|||
<?php
|
||||
class Application_Common_Database{
|
||||
public static function prepareAndExcute($sql, $paramValueMap, $type='all'){
|
||||
public static function prepareAndExecute($sql, $paramValueMap, $type='all'){
|
||||
$con = Propel::getConnection();
|
||||
$stmt = $con->prepare($sql);
|
||||
foreach ($paramValueMap as $param => $v) {
|
||||
|
|
|
@ -27,7 +27,7 @@ set_include_path(APPLICATION_PATH . '/models' . PATH_SEPARATOR . get_include_pat
|
|||
set_include_path(APPLICATION_PATH . '/controllers/plugins' . PATH_SEPARATOR . get_include_path());
|
||||
|
||||
//Zend framework
|
||||
if (file_exists('/usr/share/php/libzend-framework-php')){
|
||||
if (file_exists('/usr/share/php/libzend-framework-php')) {
|
||||
set_include_path('/usr/share/php/libzend-framework-php' . PATH_SEPARATOR . get_include_path());
|
||||
}
|
||||
|
||||
|
@ -39,5 +39,14 @@ $application = new Zend_Application(
|
|||
APPLICATION_ENV,
|
||||
APPLICATION_PATH . '/configs/application.ini'
|
||||
);
|
||||
$application->bootstrap()
|
||||
|
||||
$sapi_type = php_sapi_name();
|
||||
if (substr($sapi_type, 0, 3) == 'cli') {
|
||||
set_include_path(APPLICATION_PATH . PATH_SEPARATOR . get_include_path());
|
||||
require_once("Bootstrap.php");
|
||||
} else {
|
||||
$application->bootstrap()
|
||||
->run();
|
||||
}
|
||||
|
||||
|
||||
|
|
Loading…
Reference in New Issue