We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
  • Well, actually (hey, I’m a new convert here; they say you need to lock up and muzzle every new convert for a while!) it wouldn’t take all that much. The onChange event already triggers the javascript Confirm dialog, which then submits the form which goes and does whatever needs to be done in the database, reloading the page (well, frame) in the process.

    All it needs to do is have the Confirm dialog trigger the XMLHTTPRequest object instead , which will call exactly the same processor script to do exactly the same thing to the database and return OK or any errors, meanwhile doing absolutely nothing to the page unless it needs to create a text node to display an error message. So really, the only modification needs to be to add a bit of javascript to do the Ajax thing. I’m using a library called CPAINT that makes it a piece of cake! And since it’s all asynchronous, the user goes on about his business editing or whatever. It probably should disable the Save button until the process is completed, though, just in case of errors.
      Studying MODX in the desert - http://sottwell.com
      Tips and Tricks from the MODX Forums and Slack Channels - http://modxcookbook.com
      Join the Slack Community - http://modx.org