Last active
May 1, 2019 16:11
-
-
Save jlittlejohn/cb94928237477d6558d4 to your computer and use it in GitHub Desktop.
WP: Remove Default Linking on Images
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // Remove Default Linking to Media Items | |
| function wpb_imagelink_setup() { | |
| $image_set = get_option( 'image_default_link_type' ); | |
| if ($image_set !== 'none') { | |
| update_option('image_default_link_type', 'none'); | |
| } | |
| } | |
| add_action('admin_init', 'wpb_imagelink_setup', 10); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment