The problem is “When the data managed by the plugin is edited. You have to set your own dirty-flag (e.g. a value in a hidden input field, setup a js-variable) and check your dirty-flag if the user leave the page. But how could you check if the data in the metabox is edited? Are there some suitable hooks in the plugin? If not, you can use jQuery/JS OnChange events if the metabox contains input fields. Our simply check the input fields in the metabox (empty or not).
It would be fine to know what the metabox contains or the plugin itself.
Related Posts:
- Hook the Keydown Event in the TinyMCE Post Editor
- Is it possible to reuse wp.media.editor Modal for dialogs other than media
- How to provide translations for a WordPress TinyMCE plugin?
- Making a custom widget that includes a tinymce and works in Site Origin Page Builder
- How to run a external JavaScript file on wp-admin if admin, and other if normal user?
- Inserting code to HTML view from a pop up initiated from visual view
- Multiple TinyMCE on button click is initialized and appended but why only last one is writeable?
- Issue with iframe in TinyMCE
- How can I add an image upload field directly to a custom write panel?
- How do i best handle custom plugin page actions?
- Adding Custom Text Patterns in the WP 4.5 Visual Editor
- How do I improve this admin query snippet to avoid generating duplicate results on non-meta searches?
- Using TinyMce with textareas in meta boxes on custom post types
- Can I use the wp media uploader for my own plugin?
- Include third party Javascript library which is not included in WordPress
- How do you create a custom edit.php / edit pages page
- Cancel post save
- Create a clickable name in WP_List_Table for Plugin Admin
- Utilize TinyMCE hyperlink chooser outside of TinyMCE
- `wp_set_script_translations` with `wp.i18n` does not return translated strings in simple plugin
- creating elements/innerblocks via rangecontrol
- How to add custom content under plugin row in WordPress admin plugin list?
- How to put placeholder text in the main post input area?
- Can’t get JS code to work with shortcode
- How to load the plugin only when logged in?
- How do I add a javascript file to all admin pages via a plugin?
- WYSIWYG editor in WP 3.2 plugin
- Gutenberg – What is the best way to save/update post meta?
- WP AJAX is not working, always returns 0
- add a class when login
- Add a panel to edit post
- Using the default wordpress uploader inside plugin
- Modify users.php page to create page/post on button clicked
- Replacing Scripts in Admin Load_Scripts
- TinyMCE 4.7.11 custom styles using styleselect – what does the ‘attributes’ argument do?
- Problems with: manage_${post_type}_posts_columns
- WordPress Plugin with a shortcode that dynamically generates javascript. Can I use add_action without wrapping the javascript in a function?
- Rich text editor settings persist throughout all rich text editors
- Creating a custom Gutenberg block with columns
- “import declarations may only appear at top level of a module” when importing WooCommerce API node module
- Prevent third party plugin’s admin page access based on user type
- How to add WordPress Admin “Insert Link” UI (searches through existing posts for URL) and functionality into a custom plugin?
- Gutenberg: import dependency or assign from global variable?
- Admin – Handle data before creating or updating a post, page or custom post
- wp_filesystem put_contents issue with owner/group
- How can I replace content in the WP Admin area before an admin page is rendered?
- tinymce.get() returns error after ajax request
- How to load library scripts in admin from plugins in noConflict wrapper?
- add javascript files only when plugin is called?
- Translate MCE button text/tooltip in custom plugin
- Enqueue script globally
- How do I add a favicon that only shows during viewing of my plugin’s admin panel?
- WordPress Admin Login Custom Logo
- 400 Bad Request, in wordpress theme development, wp_ajax
- How to import the css in the plugin admin area?
- Displaying “One Time” Notification in Plugins
- Run JavaScript validation script on form submit in plugin
- Custom Plugin – CSS works, JS doesn’t
- Wp-admin Custom User Management
- Admin Subpages without Menu entry
- Data not insert and update through ajax and jQuery in admin page?
- Catching Form Submission in WordPress Admin Panel
- How to add a panel/box/widget/are/screen to the right side of edit post/page confusion
- Insert Into Post Not Working For Audio File Using jQuery
- Service Worker Uncaught (in promise) DOMException
- Disable Auto-Expanding Menu in WordPress Admin Menus
- About a programming language starts with [closed]
- How do I force a download in the admin area?
- Plugin Development – Get Admin Url (Including cases where wp-admin is not used)
- Should I put my plugin javascript inline?
- Remove Permalink Meta Box not working?
- How do I duplicate a single post, with all its properties, and save it as a different post?
- wp.media libary pdf type
- Query String Filtering API
- WordPress admin panel not working
- jQueryUI draggable doesn’t work in WordPress plugin
- I cant add is_admin control to plugin
- 400 Bad Request and illegal invocation in wp_ajax based on processData set to false or true
- Load script on frontend from widget plugin
- Append php file to footer
- XMLHttpRequest to open PHP file responds with Missing Page
- Change Label of custom post type
- Filterable posts using categories
- Stop unauthorised file access
- Redirect with message after admin_post.php
- Plugin dev: How to multiply instances of a plugin in the same metabox?
- Add Button to TinyMCE Custom Menu
- Forcing ALL plugin Admin menus into a separate menu
- Why if i enqueue the tinymce script i get undefined error
- How to get the value entered in the input field in wordpres
- How can create a custom plugin to call my webapi after any registration or membership plugin functionality
- Insert meta-description into Yoast-SEO input-field via JavaScript
- Reinitiate Gutenburg’s blocks using javascript
- Javascript function defined in view.js not reachable from save.js
- How to move custom gutenberg block controls from settings to styles tab?
- How to apply a javascript code on certain parts of elementor made pages?
- How to use native wordpress translation domain inside a custom plugin?
- Select a Text for CSS
- WordPress – Filter users list count
- Customize Message