WordPress 2.5.X: Your attempt to edit this page/post has failed. Please try again.

Posted by Mikko at 24 May 2008

Category: How-To, Wordpress Stuff

Tags:

Are you looking for a fix on the WordPress error: “Your attempt to edit/save this page/post: [post/page title] has failed. Please try again.”? If you are, you are on the right page!

Yesterday, my WordPress for this blog went problematic after the server reboot at my web host’s end. The first problem I encountered was the corruption of the table wp_options of my WordPress database which resulted to WordPress asking me to reinstall the blog. I fixed it using the Repair DB functions of cPanel.

The next problem I saw was that I can’t post or edit any page. It keeps on dumping “Your attempt to edit this post [post title] has failed. Please try again.” I tried searching for the problem in the Internet and learned that it is caused by the WordPress autosave function.

To fix it, you should have access to your WordPress blog from cPanel file manager or FTP. Browse to [blog_root]/wp-admin/ and locate the file post-new.php. After locating the file, edit it directly thru your File Manger (cPanel) or download it thru FTP. Edit the file using your favorite text editor such as NotePad if you downloaded it thru FTP.

Locate the following section of the code:

$parent_file = 'post-new.php';
$editing = true;
wp_enqueue_script('autosave');
wp_enqueue_script('post');

The function wp_enqueue_script(‘autosave’) should be commented or escaped. To comment/escape it, put double slashes (//) before the line. After doing so, the section of the file should look like this:

$parent_file = 'post-new.php';
$editing = true;
//wp_enqueue_script('autosave');
wp_enqueue_script('post');

Save the file. If you downloaded it thru your FTP, reupload it on the same folder.

Publishing should work well now. If you still encounter problems, feel free to leave a comment to this post and I’ll try to look for other solutions.

If you found this post useful, you may want to subscribe to my feeds.

======================================

Related posts:

  1. Upgraded to WordPress 2.3
  2. First post using WordPress app for Android
  3. How to Speed Up Your WordPress With PHP Speedy
  4. Migrating A WordPress Blog to Another Host
  5. WordPress 2.3 Annoyances

27 Comments

  1. jhay says

    Nice fix. I’m glad I had not yet encountered that problem on any of my blogs.

    But now that you’ve disabled the autosave function in WP, how do you then get it back without having this problem return once you want the autosave function again?

    jhay’s last blog post..invisibleSHIELD.com is now ZAGG.com

    Reply
  2. Muhd says

    Thank you very much. You save my day

    Reply
  3. happyman says

    not work. i got this error with wordpress.com blog. This is wordpress.com own blog ! Nothing we can do.

    Reply
  4. happyman says

    working solution using firefox is disable javascript, view — page style — no style.

    happyman’s last blog post..Caj Happy VS telco lain

    Reply
  5. Nelson García says

    Excelente respuesta ! Gracias.

    Reply
  6. [...] So to avoid this problem, we need to be patient, and waiting for a couple seconds before click the Save or Publish button, or deactivating WordPress Auto Save capability like done by conradmiquel. [...]

    Reply
  7. Freddy says

    You just saved my day!! It works!! Thanks.

    Reply
  8. Danny says

    It works!! Thank you very much.

    Reply
  9. [...] WordPress 2.5.X: Your attempt to edit this page/post has failed. Please try again. [...]

    Reply
  10. Alex(hungary) says

    Thanks a lot its working!

    Reply
  11. Jim says

    I tried the fix and it worked! I’m very glad to have found this page. This error had been bothering me for a long time and no other website had a fix that worked.. thanks.

    Reply
  12. Daniel says

    omg you save my live tanks for fix =)

    Reply
  13. tom says

    thank you ,you saved my life

    Reply
  14. Jordan says

    Hihi
    You’re great Man
    Thx so much
    FIXED
    Jor L

    Reply
  15. mridul says

    you rock man !!! it works…

    mridul’s last blog post..MTNL Landline and Dolphin Customer Care

    Reply
  16. Fitz says

    Hi Mikko. Sorry, this one didn’t work for me. I can post and edit blog posts but not blog pages. Hmmm. Can this be a webhost error? Will try to contact them and see if they can help.

    Fitz’s last blog post..Discover Your Strengths, Find Your Passion

    Reply
  17. johnny says

    bx4Hoo Thanks for good post

    Reply
  18. Angola Xyami says

    Hey Man!
    This hack don’t work for me.
    However… Thanks!
    Xyami!

    Angola Xyami’s last blog post..Frases de Ano Novo; Frases de Fim de Ano; Sms para Ano Novo: “A partir de hoje nada mais será igual, prometo!”

    Reply
  19. Scott W Govoni says

    Same here. It worked for post but not for pages.

    Reply
  20. Raaj says

    Here is the solution. Just download this plug in and activate it thats all… So simple..

    http://help2design.com/wordpress/your-attempt-to-edit-this-post-has-failed-wordpress-fix/

    Reply
  21. tsm says

    link doesn’t work- having problem in 2.8

    Reply
  22. RKyle2 says

    Another great post here (includes disabling revisions): http://www.vinatips.com/disable-wordpress-autosave-and-revisions

    Note: you might want to disable WordPress AutoSave in your wp-admin directory for these pages.
    post.php
    post-new.php
    page.php
    page-new.php

    Reply
  23. Jamie says

    Hmm this is really useful fix – now autosave is disabled so you havent compromised your wordpress installation at all?????????????

    Reply
  24. Jordan McClements says

    Thanks for that!

    Works well…

    Reply
  25. Jen says

    thank u!!! this is the only thing that worked for my client’s blog! http://nootritious.com/

    you’re a genius!

    Jen

    Reply
  26. Epifania Agers says

    I must say that this posting may be the most relevant write-up I’ve ever examine and saw. It’s a great assist to every person who is searching for this details.

    Reply
  27. graphic design careers says

    I don’t agree with this particular article. Nevertheless, I had researched with Google and I’ve found out that you’re right and I was thinking in the improper way. Keep on producing high quality material similar to this.

    Reply

Leave a Reply

Leave a Reply
  • (required)
  • (required) (will not be published)