• Prior to WP3.0 I was using this code in a plugin to execute my function when I was creating or editing a page:

    add_action('load-page.php', array($instance, 'function'));
    add_action('load-page-new.php', array($instance, 'function'));

    However, I see that page.php and page-new.php are no longer in the core and it’s all piped through post.php and post-new.php to handle custom post types, which is understandable.

    The URL in WP3.0 for creating a new page is {adminurl}/post-new.php?post_type=page

    Does anyone know how I can use the ‘load-‘ functionality for pages in WP3.0 – I have had a really good Google around and have even tried some trial and error hacking up of my plugin (like just putting ‘load-post-new.php?post_type=page’ in – which didn’t work of-course!), but sadly no luck so far

    I was wondering if someone could point me in the right direction on this little problem, it seems so simple, but I can’t find any documentation on it at-all cheers!

Viewing 1 replies (of 1 total)
  • Thread Starter ninjaboy

    (@ninjaboy)

    I just noticed that a very resourceful WordPress developer has just posted a blog article on how to rectify this – it may be of use if someone comes across this forum thread with similar issues: Simon Wheatley blog post

Viewing 1 replies (of 1 total)
  • The topic ‘load-page.php and load-page-new.php broken in WP3.0’ is closed to new replies.