当前位置: 首页>>代码示例>>PHP>>正文


PHP Installer::checkDependency方法代码示例

本文整理汇总了PHP中Installer::checkDependency方法的典型用法代码示例。如果您正苦于以下问题:PHP Installer::checkDependency方法的具体用法?PHP Installer::checkDependency怎么用?PHP Installer::checkDependency使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Installer的用法示例。


在下文中一共展示了Installer::checkDependency方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: testInstallerCheckDependency

 public function testInstallerCheckDependency()
 {
     $dependency = Installer::checkDependency();
     $this->assertTrue($dependency['curl'], 'cURL is installed');
     $this->assertTrue($dependency['gd'], 'gd lib is installed');
     $this->assertTrue($dependency['pdo'], 'pdo lib is installed');
     $this->assertTrue($dependency['pdo_mysql'], 'pdo mysql lib is installed');
     $this->assertTrue($dependency['json'], 'json lib is installed');
     $this->assertTrue($dependency['hash'], 'hash lib is installed');
     $this->assertTrue($dependency['simplexml'], 'simplexml lib is installed');
 }
开发者ID:ravi-modria,项目名称:ThinkUp,代码行数:11,代码来源:TestOfInstaller.php

示例2: step1

 /**
  * Step 1 - Check system requirements
  */
 private function step1()
 {
     $this->setViewTemplate('install.step1.tpl');
     // php version check
     $php_compat = false;
     if ($this->installer->checkVersion()) {
         $php_compat = true;
     }
     $this->addToView('php_compat', $php_compat);
     $requiredVersion = $this->installer->getRequiredVersion();
     $this->addToView('php_required_version', $requiredVersion['php']);
     // libs check
     if (isset($this->reqs)) {
         //testing only
         $libs = $this->installer->checkDependency($this->reqs);
     } else {
         $libs = $this->installer->checkDependency();
     }
     $libs_compat = true;
     foreach ($libs as $lib) {
         if (!$lib) {
             $libs_compat = false;
         }
     }
     $this->addToView('libs', $libs);
     // path permissions check
     $permissions = $this->installer->checkPermission();
     $this->addToView('permission', $permissions);
     $permissions_compat = true;
     foreach ($permissions as $perm) {
         if (!$perm) {
             $permissions_compat = false;
         }
     }
     $this->addToView('permissions_compat', $permissions_compat);
     $this->addToView('writable_data_directory', FileDataManager::getDataPath());
     // session save path permissions check
     $session_permissions_compat = $this->installer->isSessionDirectoryWritable();
     $this->addToView('session_permissions_compat', $session_permissions_compat);
     $this->addToView('writable_session_save_directory', ini_get('session.save_path'));
     // other vars set to view
     $requirements_met = $php_compat && $libs_compat && $permissions_compat && $session_permissions_compat;
     $this->addToView('requirements_met', $requirements_met);
     $this->addToView('subtitle', 'Check System Requirements');
     //If all requirements are met, go to step 2
     if ($requirements_met) {
         $this->addSuccessMessage("<strong>Great!</strong> Your system has everything it needs to run ThinkUp.", null, true);
         $this->step2();
     }
 }
开发者ID:jkuehl-carecloud,项目名称:ThinkUp,代码行数:53,代码来源:class.InstallerController.php

示例3: step1

 /**
  * Step 1 - Check system requirements
  */
 private function step1()
 {
     $this->setViewTemplate('install.step1.tpl');
     // php version check
     $php_compat = false;
     if ($this->installer->checkVersion()) {
         $php_compat = true;
     }
     $this->addToView('php_compat', $php_compat);
     $requiredVersion = $this->installer->getRequiredVersion();
     $this->addToView('php_required_version', $requiredVersion['php']);
     // libs check
     if (isset($this->reqs)) {
         //testing only
         $libs = $this->installer->checkDependency($this->reqs);
     } else {
         $libs = $this->installer->checkDependency();
     }
     $libs_compat = true;
     foreach ($libs as $lib) {
         if (!$lib) {
             $libs_compat = false;
         }
     }
     $this->addToView('libs', $libs);
     // path permissions check
     $permissions = $this->installer->checkPermission();
     $this->addToView('permission', $permissions);
     $permissions_compat = true;
     foreach ($permissions as $perm) {
         if (!$perm) {
             $permissions_compat = false;
         }
     }
     $this->addToView('permissions_compat', $permissions_compat);
     $writeable_directories = array('compiled_view' => $this->view_mgr->compile_dir, 'cache' => $this->view_mgr->compile_dir . 'cache');
     $this->addToView('writeable_directories', $writeable_directories);
     // other vars set to view
     $requirements_met = $php_compat && $libs_compat && $permissions_compat;
     $this->addToView('requirements_met', $requirements_met);
     $this->addToView('subtitle', 'Check System Requirements');
     //If all requirements are met, go to step 2
     if ($requirements_met) {
         $this->addSuccessMessage("<strong>Great!</strong> Your system has everything it needs to run ThinkUp.", null, true);
         $this->step2();
     }
 }
开发者ID:randi2kewl,项目名称:ThinkUp,代码行数:50,代码来源:class.InstallerController.php

示例4: step1

    /**
     * Step 1 - Check system requirements
     */
    private function step1() {
        $this->setViewTemplate('install.step1.tpl');

        // php version check
        $php_compat = 0;
        if ( $this->installer->checkVersion() ) {
            $php_compat = 1;
        }
        $this->addToView('php_compat', $php_compat);
        $requiredVersion = $this->installer->getRequiredVersion();
        $this->addToView('php_required_version', $requiredVersion['php']);

        // libs check
        $libs = $this->installer->checkDependency();
        $libs_compat = true;
        foreach ($libs as $lib) {
            if (!$lib) {
                $libs_compat = false;
            }
        }
        $this->addToView('libs', $libs);

        // path permissions check
        $permissions = $this->installer->checkPermission();
        $this->addToView('permission', $permissions);
        $permissions_compat = true;
        foreach ($permissions as $perm) {
            if (!$perm) {
                $permissions_compat = false;
            }
        }
        $this->addToView('permissions_compat', $permissions_compat);
        $writeable_directories = array(
            'compiled_view' => $this->view_mgr->compile_dir,
            'cache' => $this->view_mgr->compile_dir . 'cache');
        $this->addToView('writeable_directories', $writeable_directories);

        // other vars set to view
        $requirements_met = ($php_compat && $libs_compat && $permissions_compat);
        $this->addToView('requirements_met', $requirements_met);
        $this->addToView('subtitle', 'Check System Requirements');
    }
开发者ID:rkabir,项目名称:ThinkUp,代码行数:45,代码来源:class.InstallerController.php

示例5: testInstallerCheckDependency

 public function testInstallerCheckDependency()
 {
     $dependency = Installer::checkDependency();
     $this->assertTrue($dependency['curl'], 'cURL is installed');
     $this->assertTrue($dependency['gd'], 'gd lib is installed');
 }
开发者ID:rayyan,项目名称:ThinkUp,代码行数:6,代码来源:TestOfInstaller.php


注:本文中的Installer::checkDependency方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。