0

I was just assigned to an ongoing project at my job, wherein I had to set it up so a few options were automatically set when a new site was created. I found the 'wpmu_new_site' hook, and created a local multisite install, writing up a brief script that essentially worked as such:

add_action('wpmu_new_blog', 'update_blogOptions');

function update_blogOptions($blogID) {
    // Do actions
}

On the local install, this worked as expected.

When I moved the code to the active project, it does nothing. I even replaced all the code in the body of the function with just an error log, but it did nothing.

Any advice if I'm using the right hook? Why it may be working on one site and not the other? Things I can look at to look for conflict?

3
  • How exactly are you using this code?
    – brasofilo
    Oct 8, 2013 at 21:49
  • Not sure I follow brasofilo. I have it in a general actions/filters file (all other actions in the file are working), and in the code was just a few update_site_option.
    – Rohit
    Oct 9, 2013 at 14:42

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Browse other questions tagged or ask your own question.