Welcome to the Question2Answer Q&A. There's also a demo if you just want to try it out.
+3 votes
in Plugins by
edited by

Especially here on question2answer.org I have lost several big texts by accidentally navigating away :-(

This plugin is the "text saver" ;-) Get it for free at github.com or at q2apro.com


Question2Answer Plugin: Warn On Leave


This is a plugin for Question2Answer that warns the user after he entered text in textarea or CKEditor and is leaving the page.


  1. Install Question2Answer if you haven't already.
  2. Get the source code for this plugin directly from github or from the q2apro plugin page.
  3. Extract the files.
  4. Optional: Change language strings in file q2apro-warnonleave-lang-*.php
  5. Upload the files to a subfolder called q2apro-warn-on-leave inside the qa-plugin folder of your Q2A installation.
  6. Navigate to your site, go to Admin -> Plugins. Check if the plugin "Warn On Leave" is listed.
  7. The plugin should work now. Enter some text in a question, answer or comment field and try to navigate away.


This is beta code. It is probably okay for production environments, but may not work exactly as expected. You bear the risk. Refunds will not be given!

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.


All code herein is OpenSource. Feel free to build upon it and share with the world.

About q2a

Question2Answer is a free and open source PHP software for Q&A sites.

Final Note

If you use the plugin:
  • Consider joining the Question2Answer forum, answer some questions or write your own plugin!
  • You can use the code of this plugin to learn more about q2a-plugins. It is commented code.
  • Visit q2apro.com to get more free and premium plugins.


All the best,


Q2A version: 1.6.3

2 Answers

0 votes
Thank you Kai

I had seen confirm plugin by NoahY for that goal before, and It is long time that this plugin doesn't get updated. It is very good to have a plugin that is newer and is supported for future updates.
NoahY's plugin is not working with CKEditor :) That's why I wrote a new one.
I didn't know that. I have seen some other plugins that conflict with CKEditor. Nice work.
+2 votes
Thank you very much for giving nice free plugin.

Please provide updates where it necessary. Observed some free plugins have no updates and can not use with latest q2a versions and newest versions of internet browsers.
Yes, I agree, some plugins seems to be "abandoned".. :-(
All plugins from q2apro that you find at http://www.q2apro.com/plugins?s=q2apro work with 1.5.x and 1.6.x and will very likely work with future releases too. I will keep them up-to-date ;) Kai