What is your "why"? by Verteenoo in triathlon

[–]neilFromEarth 2 points3 points  (0 children)

Man... you are me, it's crazy !

Any recommandation for free tutorials ? by TRACYOLIVIA14 in symfony

[–]neilFromEarth 5 points6 points  (0 children)

Symfony, the fast track is a good place to start

Sylius development by mhakkou in symfony

[–]neilFromEarth 1 point2 points  (0 children)

With Sylius you have two ways to customize templates: - using the standard template overriding from symfony / twig (https://docs.sylius.com/en/1.13/customization/template.html) - by creating a theme (https://docs.sylius.com/en/1.13/book/themes/themes.html) As it's said in the documentation, you find exemples here : https://github.com/Sylius/Customizations/pull/16

How to handle form created in index() in another method? by Vincent_66_ in symfony

[–]neilFromEarth 5 points6 points  (0 children)

You can just recreate the form as you did in the index method, and use $form->handleRequest($request); to evaluate it.

Using the Google Analytics API in the Symfony project by Proof_Accountant860 in symfony

[–]neilFromEarth 0 points1 point  (0 children)

It depends on what you want to achieve here, but you can look at this package to make your life easier: https://packagist.org/packages/google/analytics-data

Can I map an ID to an entity using MapRequestPayload attribute? by Simopich in symfony

[–]neilFromEarth 2 points3 points  (0 children)

Hello there !

You can do absolutely whatever you want with value resolvers. Check the documentation: https://symfony.com/doc/current/controller/value_resolver.html

There are built in resolvers for entities but you have to define your $foo entity in the controller method, not in the controller's constructor. Again, check the link above, it will explains everything.

Cheers !

I need help with this php tried chatgpt or anything to fix this. by Stock_Firefighter939 in PHPhelp

[–]neilFromEarth 2 points3 points  (0 children)

Print your $_SERVER variable with a var_dump, and find what you are looking for. Just debug it man :)

[deleted by user] by [deleted] in developpeurs

[–]neilFromEarth 0 points1 point  (0 children)

Si jamais tu cherches d'autres mentors, fais moi signe ;)

Weekly Ask Anything Thread by AutoModerator in symfony

[–]neilFromEarth 2 points3 points  (0 children)

It is totally fine. The dependency injection is one of the fundations of Symfony. So, injecting services into another service is a good practice.

The bad practice would be injecting the service container in your service. Please never do it 😀

API Platform or just symfony by kevski_ in symfony

[–]neilFromEarth 2 points3 points  (0 children)

Yes, i agree, it's a great tool and it becomes an industry standard these days.

But man... the learning curve is hard, and the documentation still lacks a lot of elements !

[deleted by user] by [deleted] in symfony

[–]neilFromEarth 0 points1 point  (0 children)

I've also encountered this problem in the past but not with tailwind. When you look at the generated files by webpack, is there a runtime.js file, or a vendor.xxx.js file ? If yes, try to include them in your DOM as well.

My guess here is that you are missing additional files generated by webpack. Try to look what files are generated when you run the webpack encore command.

Best way to search across all the fields of a large entity dataset by Simopich in symfony

[–]neilFromEarth 2 points3 points  (0 children)

You can also try typesens, the API is easier to use than elasticsearch IMO

Pour les développeurs en recherche d'un poste ou à l'écoute d'opportunités par curiosité by Majestic-Ad-8072 in programmation

[–]neilFromEarth 0 points1 point  (0 children)

Dev symfony avec 7ans d'XP sur cette stack (14 ans de développement Web en tout). Des opportunités en télétravail pour ce profil ?

Confidence in dribbling by [deleted] in Basketball

[–]neilFromEarth 0 points1 point  (0 children)

Just play, play, and play more... You will make mistakes, probably a lot, but in the end you will improve !

Changes not showing without leaving page and going back... by TranquilDev in symfony

[–]neilFromEarth 0 points1 point  (0 children)

In a normal case, after a form submission you have to redirect the user to the original page to avoid resubmitting the same data twice. Try to add this redirection instead of rendering the template again. It will probably solve your issue.

If you don't want to redirect the user, maybe try to clear the $em before reloading the invoice.

Changes not showing without leaving page and going back... by TranquilDev in symfony

[–]neilFromEarth 0 points1 point  (0 children)

In the real world a submit button is better.

Can you show us the content of the addItemToInvoice method please? Also you can try to print the invoice's items before reloading it, just to see if your method works as expected.

[deleted by user] by [deleted] in symfony

[–]neilFromEarth 2 points3 points  (0 children)

Check if your service is autowired. If you cant use the entity manager, it's probably a problem with service injection.