symfony 3.4 under ubuntu - symfony

Hello I have installed Symfony 3.4 under ubuntu using composer - however instead of the usual symfony welcome I get the following:
I am running PHP 7 as can be seen here:
Anyone know how I can get this symfony running properly??

Move into your project directory and run this command:
php -S 127.0.0.1:8000 -t public

Related

Command " symfony new my_project " don't usable

Good morning,
after change my PC (windows 10 Pro), I have a few problems… to use symfony.
If I do composer create-project symfony/website-skeleton my_project all is good,
but if I do symfony new my_project --full , I obtain :
screenshot
And C:/ProgramData/ComposerSetup/bin/composer.phar exists :
screenshot-2
I don't undestand if you have an idea…
Thank you in advance.
Which Php version(s) do you have?
Try symfony local:php:list and symfony php -v commands please.
• You can force Php version 7.4.0 for example with this command: echo 7.4.0 > .php-version inside your project folder.

"symfony" command don't work on fedora (symfony : command not found)

I'm working on Linux fedora and I want to use Symfony for a project.
I already installed Symfony, but when I use Symfony commands it doesn't work (command not found).
My goal is to run a server by using this command symfony server:start
The 2 commands I tried (sorry my shell is in French)
package php-symfony-2.8.52-3 already installed
Dependencies solved
Nothing to do
bash : symfony : command not found
You have installed a very old version of the Symfony framework but, you are trying to use the Symfony CLI binary.
Run this installer to create a binary called symfony:
wget https://get.symfony.com/cli/installer -O - | bash
— https://symfony.com/download
Check the setup guide for further reference.

I can't start a Symfony project in PhpStorm

After 3 years I start using PhpStorm again, my first think is using Symfony 4.x with PhpStorm. But I can't start any project from Terminal on MacOS Mojave.
I have installed all plugins: Symfony, PHP Annotation, PHP Toolbox
Also I have install Symfony from Terminal also Composer.
When I search with ls in the Terminal Symfony isn't shown there.
In Finder I can see it as hidden file .symfony
trying to go in the director like cd /.symfony also not found also does not work
I think you are speaking about the symfony cli which does not have anything to do with PHPstorm.
Go to https://symfony.com/download and install the symfony cli
curl -sS https://get.symfony.com/cli/installer | bash
The symfony cli should work without any problems after following these steps.
EDIT:
Don't forget to follow the steps written after installing the cli
Add this to your shell configuration file:
export PATH="$HOME/.symfony/bin:$PATH"
Start a new shell, and then run 'symfony'
you have to add that line at the end of your ~/.bashrc file

Symfony: command not found

I am trying working with symfony since past couple of months. Last night I did an auto remove to purge not needed repositories. After that I have not been able to create a new symfony project using the symfony command. When I run Symfony new SecurityDemo 2.8.1 in the terminal,
I get the error
Symfony: command not found
I tried installing the Symfony Installer again as directed in the documentation http://symfony.com/doc/current/setup.html. I went to my root directory and followed the installation procedure as shown in the screenshot
Still I get the same error.
All help is appreciated.
EDIT:
I am working with LAMP and am using PHP 5.6.
When I try to update the symfony Installer using symfony self-update I get the output
// Symfony Installer is already updated to the latest version (1.5.8).
Add the following line to your shell configuration file:
export PATH="$HOME/.symfony/bin:$PATH"
For me the fix was to reinstall symfony:
curl -sS https://get.symfony.com/cli/installer | bash
see here https://symfony.com/download
as far as I experienced, it does not tamper with the environment.
If you're sure you installed the symfony command properly you have to call it with lowercase s and not Symfony.
The correct command is:
$ symfony new SecurityDemo 2.8.1
http://symfony.com/doc/current/setup.html#basing-your-project-on-a-specific-symfony-version
Try call Symfony it in lowercase as example:
>symfony new SecurityDemo 2.8.1
Hope this help
I had the same problem. The right command would be:
php symfony new SecurityDemo 2.8.1
Not sure why it would not work without the word php even though the documentation does not prescribe it.
cd your-project/
composer require symfony/web-server-bundle --dev
php bin/console server:start
Working beautifully for me on Fedora 33 Workstation
base: https://symfony.com/doc/4.0/setup/built_in_web_server.html
Turns out that I cannot use capital 'S' in symfony. using symfony new project_name did the trick.
The Right Command is
symfony new SecurityDemo 2.8.1
If you can’t use the Symfony installer for any reason, you can create Symfony applications with Composer, the dependency manager used by modern PHP applications.
composer create-project symfony/framework-standard-edition SecurityDemo "2.8.1"
make sure you've already install composer.
When you run curl -sS https://get.symfony.com/cli/installer | bash to install Symfony CLI Installer. After installation run either of the next commands:
Use it as a local file:
/root/.symfony5/bin/symfony
Or add the following line to your shell configuration file:
export PATH="$HOME/.symfony5/bin:$PATH"
Or install it globally on your system:
mv /root/.symfony5/bin/symfony /usr/local/bin/symfony
Then start a new shell and run 'symfony'
try this
composer require symfony/flex
composer install

Change CLI's php

Im working with Symfony2. Im trying to execute the following command:
php app/console doctrine:database:create
The problem is that I get the following error:
PHP Warning: PHP Startup: Unable to load dynamic library '/opt/local/lib/php/extensions/no-debug-non-zts-20090626/apc.so' - dlopen(/opt/local/lib/php/extensions/no-debug-non-zts-20090626/apc.so, 9): image not found in Unknown on line 0
Could not create database for connection named <comment>symfony</comment>
could not find driver
APC is already installed, since the Symfony/web/config.php was OK, what I realised is that the version of php from CLI is different from the one Apache is running.
The one Apache is running has APC installed, so I would like CLI to run that same php, How can I do that?
in my case deleting the version that macports installed was enough to have CLI and Apache run the same PHP.
And that's:
sudo port uninstall php5

Resources