• HI,

    Interesting issue I’m having.

    I’ve set up a metabox class which I’m trying to allow for the ability of cloning metaboxes within via javascript. Each metabox is a new instance of this class.

    I’ve set up a standard wp_ajax call. The functions are executing correctly.

    However, the issue I have is that when I have more than one metabox then the wp_ajax call is highjacked by the first metabox instance, so it always returns the incorrect metabox html code.

    What I need to figure out is how to get a javascript call from say the second metabox to be resolved by that metaboxes constructing class.

    Any ideas on how to approach getting around this?

  • The topic ‘Admin Ajax to clone metabox’ is closed to new replies.