Post metabox with custom submit button issue on submit
-
Hi,
I am developing a plugin, that adds a metabox to my custom post type.
Inside this metabox is a submit button for the post.
This button saves the post and some other code is executed, when the button is set in the $_POST request.
Everything works fine, however I get the browser alert asking if I want to leave the site. When I confirm that, everything works fine, I just don’t understand why I get the alert.My metabox:
<?php if($post->post_status !== 'publish'): ?> <div class="wpt-verify-post-submit"> <input type="submit" name="wpt-verify-post" id="wpt-verify-post" class="button" value="<?php _e('Some name', 'my_plugin_domain') ?>" /> <div style="clear: both"></div> </div> <div class="wpt-verify-post-status"> Status: <span id="wpt-verify-status-display">@status</span> </div> <?php else: ?> <span>Some text</span> <?php endif;
Do I need to add some additional information for WordPress or something?
Viewing 6 replies - 1 through 6 (of 6 total)
Viewing 6 replies - 1 through 6 (of 6 total)
- The topic ‘Post metabox with custom submit button issue on submit’ is closed to new replies.