-
Notifications
You must be signed in to change notification settings - Fork 10
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Use underscores instead of hyphens in shortcode names #26
Comments
joostthehost
changed the title
Use underscore instead of dash in shortcode names
Use underscore instead of hyphens in shortcode names
Mar 1, 2017
joostthehost
changed the title
Use underscore instead of hyphens in shortcode names
Use underscores instead of hyphens in shortcode names
Mar 1, 2017
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
According to Wordpress:
The use of the dash in the shortcodes can throw issues with other plugins and potential custom code that sees it as an invalid shortcode (the widely used Visual Composer for example, doesn't accept shortcode names with hypens in them. It blocks users from adding those shortcodes to their setup).
More info on what exactly can go wrong when using hyphens:
https://codex.wordpress.org/Shortcode_API#Hyphens
I'm aware this change would not be backwards compatible, and would thus be a breaking change for existing installations. An option to overcome this is to do a search and replace on the database to update existing shortcodes to the new style, and displaying a message in the admin interface to notify editors of the updated shortcodes.
The text was updated successfully, but these errors were encountered: