Symfony(8)Update Version to 2.5

本文介绍了如何将 Symfony 版本更新到 2.5,并详细记录了 PHP 5.6.2 的安装过程及配置方法。解决了一系列安装过程中出现的问题,包括配置文件错误与 OpenSSL 相关的依赖问题。同时,还介绍了 Composer 的安装与配置步骤,并通过一个实践项目展示了 Symfony 的使用。

Symfony(8)Update Version to 2.5

1. Installation Latest PHP
http://us1.php.net/distributions/php-5.6.2.tar.gz

Download the unzip the file
>tar zxvf php-5.6.2.tar.gz

preinstall and config the files
>./configure --prefix=/home/carl/tool/php-5.6.2 --with-openssl

Error Message:
configure: error: xml2-config not found. Please check your libxml2 installation.

Solution:
http://drewsymo.com/2013/11/php-configure-error-xml2-config-not-found-please-check-your-libxml2-installation/
>sudo apt-get install libxml2-dev

Error Message:
configure: error: Cannot find OpenSSL's <evp.h>
Solution:
http://www.sudosu.in/2013/05/complile-and-install-php-from-source.html
>sudo apt-get install libssl-dev

>./configure --prefix=/home/carl/tool/php-5.6.2 --with-openssl

Success.

>make
>make install

Put the php/bin in path.

The installation on PHP is good now.
>php --version
PHP 5.6.2 (cli) (built: Oct 29 2014 11:49:10)
Copyright (c) 1997-2014 The PHP Group
Zend Engine v2.6.0, Copyright (c) 1998-2014 Zend Technologies

Set up Timezone
copy the php.ini-development from the unzip php directory
>cp php.ini-development /opt/php/lib/php.ini

>sudo ln -s /opt/php/lib/php.ini /etc/php.ini
>vi /etc/php.ini
; http://php.net/date.timezone
date.timezone = America/North_Dakota/Center


2. Get and Set up Composer
>curl -sS https://getcomposer.org/installer | php

Prepare the directory and place the right file in right place
>mv composer.phar /home/carl/tool/composer/bin/composer

>composer --version
Composer version 1.0-dev (a309e1d89ded6919935a842faeaed8e888fbfe37) 2014-10-20 19:16:14

3. Set up Mysql Database
http://sillycat.iteye.com/blog/2090147
http://sillycat.iteye.com/blog/562672


4. Practice a Symfony Project 2.5.6
>composer create-project symfony/framework-standard-edition myfirstproject/ ~2.5

Check all the configuration
>php app/check.php

Run that server
>php app/console server:run



References:
Symfony 1 ~ 7
http://sillycat.iteye.com/blog/2076067
http://sillycat.iteye.com/blog/2076480
http://sillycat.iteye.com/blog/2078154
http://sillycat.iteye.com/blog/2078553
http://sillycat.iteye.com/blog/2078564
http://sillycat.iteye.com/blog/2078572

 

评论
成就一亿技术人!
拼手气红包6.0元
还能输入1000个字符
 
红包 添加红包
表情包 插入表情
 条评论被折叠 查看
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值