I am making something like a forum in symfony where people can make stories in common, a bit like a roleplaying game.
When someone is showing that one character is talking the line will be shown with a font and color set by the owner of the character. So I write a sentence, select it and press a button with the name of the character, and internally wraps that sentence in a span with a classname that is the name of the character, so when the css reads that line it is formated.
Now the problem I have, my idea is that the owner of the character can modify the font or the style, so when I do that the controller generates a css file named like the character in a special folder. Then I can use the assetic component from symfony to load all the css files from that folder. The problem is that if I want to use them in production I need to run a special command from symfony (php bin/console assetic:dump --env=prod --no-debug).
The question now is, can I run that command from the controller? I guess not for security reasons.
I know that I can always make just one css with all the classes of the characters, but I would need to parse the file looking for the class and modifying it instead of just overwrite the file and let symfony do the rest.
If it isn't possible do you know someway my idea could be "easily" done?
Hi hope you can understand me, thanks