In order to generate and log a warning message about a deprecated Symfony feature, use the trigger_error()
function as follows:
trigger_error('The enctype method of the form helper was removed. You should use the new method start instead.', E_USER_DEPRECATED);
Please, be as explicit as possible in the deprecation message and always explain the alternative way to use that feature, property, method or class.