meco

jonas

Sep 20th, 2011
101
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.76 KB | None | 0 0
  1. /* js */
  2. $(document).ready(function(){
  3. function test(){
  4. var f9 = new LiveValidation('f9');
  5. f9.add( Validate.Numericality, { minimum: 2000, maximum: 2003, onlyInteger: true } );
  6.  
  7. var f10 = new LiveValidation('f10');
  8. f10.add( Validate.Numericality, { minimum: 3000, maximum: 3003, onlyInteger: true } );
  9.  
  10. if (document.GetElementById['f9'].value > '2000')
  11. {document.GetElementById['komfort'].disabled = true;}
  12. else {document.GetElementById['komfort'].disabled = false;}
  13. };
  14. $("input").live("onblur", function() { test();})});
  15.  
  16. /*html*/
  17. <input type="text" id="f9"><br />
  18. <input type="text" id="f10"><br /> <input type="button" id="komfort" name="komfort" value="komfort"><br /><input type="button" value="industri"><br /><input type="button" value="basis">
Advertisement
Add Comment
Please, Sign In to add comment