Install Yii On Centos 6.4

I got the following error when I try to install a yii project on Centos 6.4, Can anyone help me? This project works well on Ubuntu though.

setTimezone(new DateTimeZone(Yii::app()->params[‘timezone’])); return $dt->format($format); } # Convert date in UTC to local timezone for application public static function dateToLocal($date) { $dt = new DateTime($date, new DateTimeZone(“UTC”)); $dt->setTimezone(new DateTimeZone(Yii::app()->params[‘timezone’])); return $dt->format(‘Y-m-d’); } public static function addDays($days, $datetime=’’) { if ($datetime) { $time = strtotime($datetime) + (60 * 60 * 24 * $days); } else { $time = time() + (60 * 60 * 24 * $days); } return date(‘Y-m-s H:i:s’, $time); } public static function get($array, $key, $default = null) { return isset($array[$key]) ? $array[$key] : $default; } public static function supportedLanguages() { return self::get(Yii::app()->params, ‘languages’, array()); } public static function isLanguageSupported($language) { return in_array($language, array_keys(self::supportedLanguages())); } public static function changeLanguage($language) { if (Utils::isLanguageSupported($language)) { Yii::app()->session[‘language’] = $language; Yii::app()->language = $language; } } public static function languageChangingLinks($base = ‘/site/changeLanguage’) { $languages = self::supportedLanguages(); $items = array(); foreach($languages as $id => $name) $items []= CHtml::link($name, array($base, ‘lang’ => $id), ($id !== Yii::app()->language)? array(‘style’ => ‘margin: 0px 5px;’) :array(‘style’ => “font-weight:bold;margin: 0px 5px;”)); return implode(’|’, $items); } public static function newSphinxClient() { $s = new SphinxClient; $s->setServer(Yii::app()->params[‘sphinx_servername’], Yii::app()->params[‘sphinx_port’]); $s->setMaxQueryTime(5000); $s->setLimits(0, 5000); $s->setMatchMode(SPH_MATCH_EXTENDED); return $s; } public static function convertDate($date){ date_default_timezone_set(‘America/Los_Angeles’); return @strtotime($date); } } ?>

The code it related seems like the following one,

    /* Set the app language if the session's language is supported */

    $language = Utils::get(Yii::app()->session, 'language', Yii::app()->params['language']);

    if (Utils::isLanguageSupported($language))

        Yii::app()->language = $language;

The log says, could not find the class "Utils".

I do need help, thanks a lot.

Can anyone help? It looks like I see this msg for every webpage.

Same problem happened for my CentOS 6.5 installation. After several days working on the debug, I realized the issue was caused by the stupid human error. By default the php installation on CentOS not supporting the short tag ‘<?’ and required the long tag ‘<?php’. If you want to use the short tag, please change php.ini and set short_opentag=On. But definitely, I will recommend to use the long tag.