Sonata AdminType fields are not validated
I have two admins UserAdmin and UserSettingsAdmin. In the UserAdmin I added a AdminType field that embeds UserSettingsAdmin form fields:// AppBundle\Admin\UserAdmin.php$formMapper ->add('settings',...
View ArticleWhere do you store user uploaded content within a Symfony 4 application?
I have a section within my site where the user can upload their own profile pictures which is stored in the output directory and tracked in the database like so: $form =...
View ArticleMy profiler toolbar isn't showing up in symfony 4.3.1
In my .env file, I have specified my app environment to be dev and debug to be true like so:APP_ENV=devAPP_DEBUG=trueIn my config/packages/dev/web_profiler.yaml file I have the following:web_profiler:...
View ArticleSymfony4: Doctrine2 works but no connection in PHPUnit test (kernel booted)
Strange issue in Symfony4: Doctrine works, I can validate the schema, create the database etc using php bin/console doctrine:schema:create. But my PHPUnit test does not have a connection. By running...
View Articlechunk.sortModules is not a function when running yarn run encore production...
i Just run $yarn run encore productioni have this error:TypeError: chunk.sortModules is not a functionat...
View ArticleUncaught PHP Exception...
I just started following a symfony 4 tutorialI set up the whole project with composer and got the index file showing up in browser http://127.0.0.1:8000/I'm stuck on the very first...
View ArticleAPI platform filters with uuid
I recently set up a project where I use api-platform in correlation with ramsey/uuid-doctrine in accordance with https://api-platform.com/docs/core/identifiers/.Al the basic CRUD stuff works but I'm...
View ArticleMy custom Form Type Template is ignored when rendering form
I created a custom field type class BootstrapToggleType extends AbstractType which is child of CheckboxType I also prefixed it just in case as followspublic function getBlockPrefix(): string{ return...
View ArticleHow to fix error "Failed to load ressource : Acces-control-allow-origin...
We have recently engaged an external company to develop a mobile application for us.We've made an API available for them, but they're having problems compiling the iOS executable. (Everything works...
View ArticleExpected argument of type "string", "null" given at property path
Actually when I try to edit the form by sending empty fields, the above error comes on ,My UserType class looks like: class UserType extends AbstractType{ public function buildForm(FormBuilderInterface...
View ArticleErreur : An exception has been thrown during the rendering of a template ("Some
In my project I have members who each have different galleries. I'm looking to make a method that allows me to have all the showrooms associated with my member. I have a OneToMany relationship between...
View ArticleConfirming form after form has been submitted and validated in Symfony
I have a appointment form once it has been submitted you get a confirmation of the data you've filled in, The confirmation has a button that when pressed on it it should insert the data to the...
View ArticleSymfony service decoration, what does it actually mean?
I am new to Symfony. I read about service decoration but I don't still understand it. What does it actually mean to decorate a service in Symfony?
View ArticleWhy "Notice: Undefined index:" exceptions occur for all Beans after composer...
I am dealing with a step-by-step Symfony upgrade starting from Symfony 4.2.7 to recommended latest Symfony 4.x (namely, 4.4) before major upgrade to 5.x and so on.The site has an ORM layer enabled by...
View ArticleI've defined a bundle Controller and Routing, but I get "Error: the...
I have created a controller class under a module directory in Symfony 4. My bundle's routing file references it. My root's routing file includes the bundle's routing file.However I get an error 500,...
View ArticleSymfony 4.3 PHP: How to read the cookie from a 302 redirection response?
What I want to do (in the controller)Receive a request, based on whichSend an external HTTP requestParse the response, based on whichReturn a responseI plan to have multiple functions that all follow...
View ArticleSymfony LTS: how to upgrade from 3.4 to 4.4?
Tell me please, what steps are required in order to upgrade Symfony from 3.4 to 4.4 LTS?
View ArticleSymfony JWT - Change the login way using symfony lexik JWT Authentication Bundle
In the Symfony Lexik JWT Authentication bundle, It is explained how to authenticate users using a table in the database.In my case, My users aren't in the database but are in another application that I...
View ArticleSymfony 4 Form file upload field does not show selected filename with...
Using Symfony 4.2.5, I made a Form with a FileType file upload field as described at upload file. I used the Bootstrap 4 theme as described at form_themes and bootstrap4.config/packages/twig.yaml...
View ArticleWhat are the steps to upgrade Symfony from 3.4 to 4.4 on Ubuntu 24.04
I’m in the process of upgrading Symfony from 3.4 to 4.4, but I’ve hit some roadblocks. My current setup is quite outdated:Ubuntu version: 14.04PHP version: 5.5This configuration worked fine for Symfony...
View Article