requirements.php 1.71 KB
Newer Older
1 2
<?php
/**
3
 * These are the Yii core requirements for the [[YiiRequirementChecker]] instance.
4
 * These requirements are mandatory for any Yii application.
5 6
 *
 * @var $this YiiRequirementChecker
7 8 9 10 11
 */
return array(
	array(
		'name' => 'PHP version',
		'mandatory' => true,
12
		'condition' => version_compare(PHP_VERSION, '5.3.7', '>='),
13
		'by' => '<a href="http://www.yiiframework.com">Yii Framework</a>',
14
		'memo' => 'PHP 5.3.7 or higher is required.',
15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40
	),
	array(
		'name' => 'Reflection extension',
		'mandatory' => true,
		'condition' => class_exists('Reflection', false),
		'by' => '<a href="http://www.yiiframework.com">Yii Framework</a>',
	),
	array(
		'name' => 'PCRE extension',
		'mandatory' => true,
		'condition' => extension_loaded('pcre'),
		'by' => '<a href="http://www.yiiframework.com">Yii Framework</a>',
	),
	array(
		'name' => 'SPL extension',
		'mandatory' => true,
		'condition' => extension_loaded('SPL'),
		'by' => '<a href="http://www.yiiframework.com">Yii Framework</a>',
	),
	array(
		'name' => 'MBString extension',
		'mandatory' => true,
		'condition' => extension_loaded('mbstring'),
		'by' => '<a href="http://www.php.net/manual/en/book.mbstring.php">Multibyte string</a> processing',
		'memo' => 'Required for multibyte encoding string processing.'
	),
41 42
	array(
		'name' => 'Intl extension',
43
		'mandatory' => false,
44
		'condition' => $this->checkPhpExtensionVersion('intl', '1.0.2', '>='),
45
		'by' => '<a href="http://www.php.net/manual/en/book.intl.php">Internationalization</a> support',
46
		'memo' => 'PHP Intl extension 1.0.2 or higher is required when you want to use <abbr title="Internationalized domain names">IDN</abbr>-feature of EmailValidator or UrlValidator or the <code>yii\i18n\Formatter</code> class.'
47
	),
resurtm committed
48
);