Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Symfony2 set up

I'm trying to set up sample Symfony2 project as shown here http://symfony.com/doc/current/quick_tour/the_big_picture.html

and after accessing config.php I have this:

Major problems have been detected and must be fixed before continuing:
Add "phar" to suhosin.executor.include.whitelist in php.ini*.

I added this:

suhosin.executor.include.whitelist="phar"

into php.ini, but config.php still show the same message.

like image 531
Herokiller Avatar asked Sep 18 '12 11:09

Herokiller


People also ask

How do I run an existing Symfony project?

Running your Symfony ApplicationOpen your browser and navigate to http://localhost:8000/ . If everything is working, you'll see a welcome page. Later, when you are finished working, stop the server by pressing Ctrl+C from your terminal.

How to start Symfony server with Composer?

Open a terminal and run once: symfony server:ca:install . This will install a local SSL certificate authority that allows you to run the local webserver on https:// . Inside the terminal, move into your project directory and run symfony serve . A local webserver will start; by default on https://localhost:8000/ .

How to Install Composer in Symfony?

Install Composer on WindowsDownload the installer from getcomposer.org/download, execute it and follow the instructions.


2 Answers

1) Check that you edited the correct php.ini, usually a PHP installation has several php.ini (one for CGI, one for CLI, one for APACHE2). Have a look in /etc/php5 for instance.

2) Check in phpinfo() that the parameter is taken in account.

3) Refer to this blog post: [Solved] symfony 2 Major problems Major problems have been detected and must be fixed before continuing: Add “phar” to suhosin.executor.include.whitelist in php.ini*.

The post suggests ensuring suhosin is installed with

sudo apt-get install php5-suhosin
like image 187
Bgi Avatar answered Oct 19 '22 00:10

Bgi


I had the same problem.

What you did is right, as skonsoft says you should check if you have installed suhosin and then add "phar" in your php.ini OR conf.d/suhosin.ini

I did this too and the problem persisted

I found the solution here, it was a problem with my libxml2 library

I have now solved this.

Tracked it down to a libxml2 incompatibility.

Seems that /vendor/symfony/src/Symfony/Component/DependencyInjection/Loader/XmlFileLoader.php doesn't like libxml2-2.6.22. An upgrade to 2.8.0 has fixed it - with the required PHP recompile to pick up the new libxml2.

Hope this helps someone!

I'm using Debian 6

like image 27
Ulises Avatar answered Oct 19 '22 01:10

Ulises