_deprecated_argument for constants

Unfortunately there is no way to trigger WP deprecation warning for PHP constants. What I can suggest – to use your constants and “theme support” options together. First for backward compatibility, second for customization facilities. Your theme will have to rely on “theme support” options only, and keep constants only for child theme. The trick … Read more

How to replace bloginfo(template_url)

bloginfo($option) echos out a value whereas get_template_directory_uri() returns a string – did you maybe forget to echo get_template_directory_uri()? Also are you passing a string with quotes i.e. bloginfo(template_url) vs bloginfo(‘template_url’)? Both bloginfo(‘template_url’) and get_template_directory_uri() should work, they aren’t deprecated.

Deprecating functions in a plugin class

Non existing Callbacks One of the nice things is, that neither do_action(), nor apply_filters() do trigger an error if a callback isn’t present. This means that its the safest way to insert plugin data into templates: If a plugin is turned off and do_action()/apply_filters() don’t find the callback in the global $wp_filters array, nothing happens. … Read more