Take the 2-minute tour ×
WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

If you write a title, then move away from (blur) that input field, WordPress will auto-save a draft for you, likely in order to create a post slug placeholder for you.

I'm looking to possibly extend this functionality to also save on blurring of the content body TinyMCE pane. The logic is not entirely straightforward -- for example, it appears to saves a draft only when the post is yet unpublished -- so I need to look further into the logic.

In order to scope this change, I need to find where in the JavaScript (?) codebase WordPress does this auto-saving. Having trouble so far. Does anyone know?

share|improve this question

1 Answer 1

up vote 2 down vote accepted

I believe the file responsible is wp-includes/js/autosave.js. There is a dev version for easy reading.

share|improve this answer

Your Answer

 
discard

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.