[wp-hackers] Activation hook exist for themes?
kksharma1618
kksharma1618 at gmail.com
Thu Jan 20 21:13:42 UTC 2011
I was looking for activation/deactivation hook for themes. Yours was the best
approach but it is a bit unreliable as admin can refresh the page after
activating theme and activation code can run multiple times. I have written
a code which provides a reliable activation/deactivation theme hooks. Please
check it out and let me know what you guys think!
http://www.krishnakantsharma.com/2011/01/activationdeactivation-hook-for-wordpress-theme/
Ozh wrote:
>
> Last time I checked there was no such hook
>
> A simple workaround is:
> if ( is_admin() && isset($_GET['activated'] ) && $pagenow == "themes.php"
> ) {
> // do your stuff
> }
>
> On Sun, Aug 30, 2009 at 2:08 PM, rajasekharan<websweetweb at gmail.com>
> wrote:
>> Similar to register_activation_hook for plugins, do activation hooks
>> exist
>> for a themes in wordpress?
>>
>
>
>
> --
> http://planetOzh.com ~ Blog and WordPress Stuff
> http://FrenchFragFactory.net ~ Daily Quake News
> _______________________________________________
> wp-hackers mailing list
> wp-hackers at lists.automattic.com
> http://lists.automattic.com/mailman/listinfo/wp-hackers
>
>
--
View this message in context: http://old.nabble.com/Activation-hook-exist-for-themes--tp25211004p30702227.html
Sent from the Wordpress Hackers mailing list archive at Nabble.com.
More information about the wp-hackers
mailing list