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


PHP SymfonyRequirements::getFailedRequirements方法代码示例

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


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

示例1: requirementsAction

 /**
  * Check System Requirements
  *
  * @return \Symfony\Component\HttpFoundation\Response
  */
 public function requirementsAction()
 {
     // include symfony requirements class
     require_once dirname(__FILE__) . '/../../../../app/SymfonyRequirements.php';
     $symfonyRequirements = new \SymfonyRequirements();
     // add additional requirement for mcrypt
     $symfonyRequirements->addRequirement(extension_loaded('mcrypt'), "Check if mcrypt ist loaded for RSA encryption", "Please enable mcrypt-Extension. See <a href='http://php.net/manual/de/mcrypt.setup.php'>http://php.net/manual/de/mcrypt.setup.php</a>");
     // fetch all data
     $aRequirements = $symfonyRequirements->getRequirements();
     $aRecommendations = $symfonyRequirements->getRecommendations();
     $aFailedRequirements = $symfonyRequirements->getFailedRequirements();
     $aFailedRecommendations = $symfonyRequirements->getFailedRecommendations();
     $iniPath = $symfonyRequirements->getPhpIniConfigPath();
     // render template
     return $this->render('SlashworksBackendBundle:Install:requirements.html.twig', array("iniPath" => $iniPath, "requirements" => $aRequirements, "recommendations" => $aRecommendations, "failedrequirements" => $aFailedRequirements, "failedrecommendations" => $aFailedRecommendations));
 }
开发者ID:RockKeeper,项目名称:control-bundle,代码行数:21,代码来源:InstallController.php

示例2: aboutAction

 /**
  * Display form for license activation
  *
  * @return \Symfony\Component\HttpFoundation\Response
  */
 public function aboutAction()
 {
     $oLicense = LicenseQuery::create()->findOne();
     // include symfony requirements class
     require_once dirname(__FILE__) . '/../../../../app/SymfonyRequirements.php';
     $symfonyRequirements = new \SymfonyRequirements();
     // add additional requirement for mcrypt
     $symfonyRequirements->addRequirement(extension_loaded('mcrypt'), "Check if mcrypt ist loaded for RSA encryption", "Please enable mcrypt-Extension. See <a href='http://php.net/manual/de/mcrypt.setup.php'>http://php.net/manual/de/mcrypt.setup.php</a>");
     // fetch all data
     $aRequirements = $symfonyRequirements->getRequirements();
     $aRecommendations = $symfonyRequirements->getRecommendations();
     $aFailedRequirements = $symfonyRequirements->getFailedRequirements();
     $aFailedRecommendations = $symfonyRequirements->getFailedRecommendations();
     $iniPath = $symfonyRequirements->getPhpIniConfigPath();
     $sVersion = file_get_contents(dirname(__FILE__) . '/../../../../version.txt');
     return $this->render('SlashworksAppBundle:About:about.html.twig', array("license" => $oLicense, "version" => $sVersion, "iniPath" => $iniPath, "requirements" => $aRequirements, "recommendations" => $aRecommendations, "failedrequirements" => $aFailedRequirements, "failedrecommendations" => $aFailedRecommendations));
 }
开发者ID:slashworks,项目名称:control-bundle,代码行数:22,代码来源:AboutController.php

示例3: exit

<?php

if (!isset($_SERVER['HTTP_HOST'])) {
    exit('This script cannot be run from the CLI. Run it from a browser.');
}
if (!in_array(@$_SERVER['REMOTE_ADDR'], array('127.0.0.1', 'fe80::1', '::1'))) {
    header('HTTP/1.0 403 Forbidden');
    exit('This script is only accessible from localhost.');
}
require_once dirname(__FILE__) . '/../app/SymfonyRequirements.php';
$symfonyRequirements = new SymfonyRequirements();
$majorProblems = $symfonyRequirements->getFailedRequirements();
$minorProblems = $symfonyRequirements->getFailedRecommendations();
?>
<!DOCTYPE html>
<html lang="en">
    <head>
        <meta charset="UTF-8" />
        <link rel="stylesheet" href="bundles/sensiodistribution/webconfigurator/css/install.css" media="all" />
        <title>Symfony Configuration</title>
    </head>
    <body>
        <div id="symfony-wrapper">
            <div id="symfony-content">
                <div class="symfony-blocks-install">
                    <div class="symfony-block-logo">
                        <img src="bundles/sensiodistribution/webconfigurator/images/logo-big.gif" alt="Symfony logo" />
                    </div>

                    <div class="symfony-block-content">
                        <h1>Welcome!</h1>
开发者ID:robzienert,项目名称:symfony-standard,代码行数:31,代码来源:config.php

示例4: checkSf2Requirements

 public function checkSf2Requirements()
 {
     $symfonyRequirements = new SymfonyRequirements();
     $errors = $symfonyRequirements->getFailedRequirements();
     return $errors;
 }
开发者ID:M03G,项目名称:PrestaShop,代码行数:6,代码来源:system.php


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