Quote from: sottwell at Apr 20, 2007, 01:29 AM
The only way to do that is to use a javascript validation script. There are a number of them freely available; Google is the best way to find a bunch of them. I’ve used several, and can’t really specifically recommend any one of them. They all pretty much do the job.
Here is one that I haven’t tried yet, but I believe it uses MooTools v1.0
http://www.phatfusion.net/formvalidation/
I likely will make a switch to this one should it test out ok, as others I have tried continually conflict with QuickEdit, Moo, and others (as some require prototype and scriptaculous)
NOTE: During a quick review of the validate.js file from the demo page, I noticed this code:
if(!valid){
this.messageBox.setStyle('display','block');
document.location = '#'+this.formAnchor.name;
...If you happen to be using <base href=""> in your MODx sites (I personally always do), then this piece of code my not function as intended:
document.location = '#'+this.formAnchor.name;
it might need to be updated to the following (for base href usage) or commented out altogether.
document.location = document.location.href+'#'+this.formAnchor.name;