Category "symfony"

How to access Session in PHPUnit WebTestCase (Symfony 5)

I'm trying to test methods which requires Sessions in my PHPUnit WebTestCase, with no success. PHP 8.0, Symfony 5.4 Here's my code: When user log-in, I'm saving

Cannot retrieve error message using Symfony HttpClient if the response is not "ok"

I use Symfony HttpClient to call an external API. When the status code is 200 I can use getContent() method to retrieve the API response. If the API response is

Symfony / Doctrine: OneToMany insert results in null id

I have two entities that I'm trying to apply a OneToMany / ManyToOne relationship to (one Game has many GameContent). Game /** * @ORM\OneToMany(targetEntity=

Symfony there are no commands defined in the "make" namespace

Following the documentation found here I enter php bin/console make:entity Product in Terminal and get the following error: [Symfony\Component\Console\Exceptio

Uncaught Error: Class "Symfony\Bundle\DebugBundle\DebugBundle" not found

I trying to deploy my application (Symfony 6 and php 8) through the Gandi.net french service. When I run the command to deploy the app by ssh I get the followin

react-datepicker css not being applied

I'm using a Symfony-based react application and am trying to include a datepicker using the react-datepicker module. I can create the datepicker object, but it

Symfony redirect if already loggedin from login page

I'm using FOSUser Bundle to login. Now if user is already loggedin, how can I redirect user to homepage ('/'), if user visit to /login url. I have copied Secur

How to remove Deprecated Symfony\Component\Debug\DebugClassLoader?

I have upgrade Symfony 3.4 to 4.4. The only Deprecation warning left is this: php.INFO: User Deprecated: The "Symfony\Component\Debug\DebugClassLoader" class i

Is it possible to read a csv file column by column with League csv?

I wondered if it was possible to read a csv file written like this in symfony using League csv or something else. water_level,2,456,345 wind_speed,2

Docker "Invalid mount path app/symfony" must be absolute

Im trying to setup Webpack to run with docker. I'm looking to put it in its own container, build the files and then nginx will serve that produced code on its c

Symfony 5 mail not send - MailHog

When I try to send a local mail I do not get anything and yet I have no mistake. Normally I should receive the mail on Mailhog. I tested by sending an email wit

Why is webpack encore required only in dev

I'm currently configuring some docker images for a symfony 5 project and trying to deal with the production build. Doing so, I noticed that webpack encore is in

Why is webpack encore required only in dev

I'm currently configuring some docker images for a symfony 5 project and trying to deal with the production build. Doing so, I noticed that webpack encore is in

Error : The entity passed to the choice field must be managed

In a search form, when I submit for the second time the datas containing a equipment criterion, I receive this error : Entity of type "App\Entity\Equipment"

Lexik JWT authentication problem "Invalid credentials"

I am new to symfony and I am using LexikJWTAuthenticationBundle for authorization. I am using symfony 6.0.2 and 2.14 lexic version. I am using Postgresql 12.9.

Unable to read the "../.dev.env" environment file in Dotenv.php:symfony

I want To run a symfony project in my computer but I get all times errors , and now I get this error and i didn't find any solution for my problem Problem Fail

Doctrine2 DBAL Exists query

I would like to ask for your help with Doctrine2 DBAL query built with QueryBuilder. I'm used to ORM, but I think it's an overkill for such query which is being

How can I stop a symfony process which is listening on http://127.0.0.1:8000

I am trying to run a basic Symfony installation which I generated using this command : $ symfony new basic When I run the following commands : $ cd basic $

SQLSTATE[23000]: Integrity constraint violation: 1048 Column 'id_utilisateur_id' cannot be null

I am a computer science student. And I have a problem while creating an API. Here is my controller allowing the addition of a "Personnage". (POST) #[Route('/api

Symfony Error: You have requested a non-existent parameter "file_path" [closed]

This is my stack trash, I am getting this when doing the existing Symfony project. stack trash : Symfony\Component\DependencyInjection\E