WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

As the title says, I want to trigger the autosave function of wordpress manually or just disable the "unsaved changes" dialog.

The reason for this: I'm developing a plugin which reloads the post edit page after doing some stuff and it's just annoying that the "unsaved changes" popup always pops up before reloading.

share|improve this question

You could disable it with: source

function disableAutoSave(){
add_action( 'wp_print_scripts', 'disableAutoSave' );

Also not a real answer, edit the interval in the WP-config:

The autosave function itself is in wp-includes/js/autosave(.dev).js

share|improve this answer
Thanks for the answer but that doesn't really help me since I don't want to turn of the auto save function. I'll have a look at the js file and see what I can do. – Stephan S. Dec 6 '12 at 20:39
Yes I know :( I'm pretty sure the answer is in the js file but I'm not very skilled in JS so I can't figure it out. You might be able to trigger autosave() a function that might work – janw Dec 7 '12 at 7:02

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.