Created
July 8, 2013 20:30
-
-
Save ivandotv/5952231 to your computer and use it in GitHub Desktop.
Aktivacija plugina samo ako ga tema explicitno podrzava.
This file contains 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
add_action('after_setup_theme','theme_setup'); | |
function theme_setup() | |
{ | |
add_theme_support('prefix-someCPT'); | |
} |
This file contains 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
add_action('init','plugin_init'); | |
function plugin_init() | |
{ | |
if( current_theme_supports('prefix-someCPTq') ) | |
{ | |
// plugin code | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment