I've got a strange problem going on with Symfony. Today I made brand new project using composer create-project symfony/website-skeleton gall command and right after installation, before doing anything in code I go to the website and the only thing that is said on webprofiler toolbar is "An error occurred while loading the web debug toolbar." I don't even get to see what kind of error is this.
The server I'm running is PHP v. 7.2.3, program is Xampp for Windows.
I thought maybe this default starting page is bugged, so I made some test controller and the error is exactly the same. Have you encountered such problem with latest symfony?
I would never figure it out myself, but adding index.php to browser address resolved the issue.
Much better solution is to use command
composer require symfony/apache-pack
As the .htaccess file is not included in the website-skeleton by default :)
Thanks for pointing me in the right direction guys!
Related
I know there is a thread on it ("Symfony fresh installation is not working on my localhost") but the solution didnt helped me.
I'm new to Symfony and I tried to create my first project. I installed a fresh copy of Symfony and then tried to start the server but I can't access localhost:8000, its loading forever and nothing happens.
My folder :
Screen installation
I ran this command :
php bin/console server:run
It says everything is okay and I can now access it.
Command Result
..but when I try to access it, the tab is loading forever.
Tab loading forever
Server status
I already tried to start the server on another port php bin/console server:start *:8080 for example, but same problem happen. Am I doing something wrong ? Thanks for helping and sorry for my bad english.
Quick Reply,
Thanks to people answering this thread.
I found the solution. I removed my antivirus protection and now its working perfectly. I recently installed Avast and I tried to removed it and seems to be the problem. Sorry for bothering.
I want to use Symfony 4.x for a new project, I have installed composer and used it to create a new project. My php version is 7.0.10 & I have wamp as well.
In this tutorial (https://symfony.com/doc/master/setup.html), it says after you run the server "Open your browser and navigate to http://localhost:8000/". When I do so, I get a No route found for "GET /" error.
the pictures bellow display what I get as an error more precisely :
as well as
I have installed everything following the guide on their official page. I have seen this problem being discussed on github (https://github.com/symfony/symfony-docs/issues/9178) but I don't understand their "quick fix" nor what they're talking about.
I want to know how to get my project running without that problem.
Thanks for any help
It’s strange but It’s totally normal and the error proved that Symfony is well installed
It’s not a « compile » or « configuration » error it’s just a logical error that means you don’t have route defined at
url / so keep learning and define a route (see doc and you see the result)
There is a project in a bitbucket repository where I am developing with 3 more other people. We have the development branch where we close versions and it is the main branch of the project. The thing is that in my computer all files pulled from that branch works fine and I can navigate trough all pages without getting any exception. On the other hand the other 3 people are getting this error in some pages:
Like I said, in my computer this page and some other ones work fine so my guess is that's most likely an error in a file that has .gitignore or individual computer file.
Already tried:
running composer update, composer dump-autoload, php artisan optimize;
clearing cache;
searching into real syntax error in controller (didn't find anything. If there really was this syntax error i'd be getting it too because files are pulled from git);
deleting logic inside controllers to check if it was syntax error (didn't find anything again);
replacing their vendor folder with my vendor folder;
cloning the project again in their machines
These exceptions occur mainly in namespaces after /admin/editar_paginas/vantagens
We are using AdminLTE package, not sure if there is something related with it.
Honestly I have no ideia what's going on. How can it work specifically in my computer and on theirs not? Let me know if it's not clear enough.
yesterday i got stuck on a similar situation where i was not getting what the error was all about, so what i did was i deleted the controller,model ,request and migration and recreated it all it removed the error. it worked for me and if there is not much data in the database you could give it a try, laravel does produce such errors from time to time.
It was really PHP version. They had PHP 5.6 in their machines. Upgrading it to ^7.0 solved the issue.
I have a problem with Symfony 2. trying the example from the book. I have written a controller but when i go to the URL specified in the route i get an error. The server can't find the page. When i run app_dev.php i get an error that the file boostrap.php.cache is missing.
searched on the internet but found nothing relevant so far. I don't know if the front-controller is already written or if that is something that still has to be done by me.
I can't get the application to run.
Found the solution. I followed the guidelines installing sf2 in netbeans. Instead of running the application as a local website i used the build-in server option wich gave me access to the cli commands. There i could use the command run server and all of my problems were gone.
So I've recently developed a CMS with Laravel and its all working great - on my local machine that is...
When I upload it to my webserver I start getting file not found errors from what I believe is composer's autoloader.
The errors originate from the require $file on line 52 (I think, I'm not at the computer right now) in the vendor/composer/autoload_real.php.
I'm not familiar with composer at all so I'm not really sure where to start. All I do know is that it works fine on my localhost but doesn't work on my server with the exact same files. I am just lost as to what to try. Any ideas?
Thanks to everyone for their support. I've got it working now.
I deleted the vendor directory, installed composer on the server, updated my files to the ones provided at laravels github, ran composer install and finally re-uploaded my config, controllers and views.
This was necessary as composer update was giving me even more errors. Either way, I've finally got it working and you guys helped a lot.