I've been looking at RegEX's and don't know how to combine 2 regex statements together, for example
I have this JQuery code:
开发者_StackOverflow$('.numeric').keyup(function () { 
    $(this).toggleClass('field-error', /\D/.test(this.value));
}); 
How do I combine this with the regex ^0 ...means any number begining with zero
Any help would be greatly appreciated, Thanks
You could use:
/^0|\D/
Which simply matches ^0 or \D.
/^0|\D/
Use the pipe (|) character to symbolize you want either the left or the right side.
e.g. to match apple, orange or banana you can use:
/apple|orange|banana/
 
         
                                         
                                         
                                         
                                        ![Interactive visualization of a graph in python [closed]](https://www.devze.com/res/2023/04-10/09/92d32fe8c0d22fb96bd6f6e8b7d1f457.gif) 
                                         
                                         
                                         
                                         加载中,请稍侯......
 加载中,请稍侯......
      
精彩评论