running a function on theme activation in functions.php
-
I’ve made plugins before that ran a function on plugin activation, by hooking into the activate action, like this:
add_action('activate_plugin-name.php', 'function-name');
but I was wondering if there was a action I could hook into to run a function in the functions.php file of a theme, to run that function when the theme is activated (specifically, to build a table in the database).
Can anyone help?
Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
- The topic ‘running a function on theme activation in functions.php’ is closed to new replies.