[jQuery] AND OR Expression

2009-12-10 Thread evanbu...@gmail.com
I having trouble with this line if (td4th.text() '4') || (td4th.text() '2' (activeCEO == 'Yes')) In plain English, I want it to be true if td4th 4 OR td4th 2 AND activeCEo = 'Yes' Thanks $('#tblBoardDirectors tr').each(function() { var relStatus = ($('td:nth-child(5)',

Re: [jQuery] AND OR Expression

2009-12-10 Thread Richard D. Worth
Convert with parseInt and then compare int to int instead of strings https://developer.mozilla.org/En/Core_JavaScript_1.5_Reference/Global_Functions/ParseInt - Richard On Thu, Dec 10, 2009 at 12:26 PM, evanbu...@gmail.com evanbu...@gmail.comwrote: I having trouble with this line if

[jQuery] jquery and regular expression

2009-10-10 Thread Otis Harrison
Hi, I have a question about how could I create a textbox that will use jquery to add a regular expression that a user passes in. I want to be able to us a variable to pass in regular expression using jquery. Any help please. thanks

[jQuery] Re: Regular Expression validation

2009-08-12 Thread nouky
Thank you I resolved my issue.. On Aug 10, 2:47 pm, Eduardo Pinzon edcpin...@gmail.com wrote: jQuery.validator.addMethod(notNumber, function(value, element, param) {                        var reg = /[0-9]/;                        if(reg.test(value)){                              return

[jQuery] Re: Regular Expression validation

2009-08-10 Thread nouky
I'm not that good with javascript. If the textboxt name is txtname, how do you incorporate it in the code above???

[jQuery] Re: Regular Expression validation

2009-08-10 Thread nouky
What I really wanted to do is use the jQuery validator and in the function set a validation that numbers are not allowed in a text input. For example I have this code: $(document).ready(function() { // validate signup form on keyup and submit var validator =

[jQuery] Re: Regular Expression validation

2009-08-10 Thread Eduardo Pinzon
jQuery.validator.addMethod(notNumber, function(value, element, param) { var reg = /[0-9]/; if(reg.test(value)){ return false; }else{ return true;

[jQuery] Re: Regular Expression validation

2009-08-09 Thread KeeganWatkins
With all due respect, I think karl's solution is somewhat less than elegant, and could be improved by refactoring to: // test for anything but numbers var isValid = /[^\d]/g.test(textareaValString); if (isValid) { // proceed with confidence } else { // note to user: no numbers allowed!

[jQuery] Re: Regular Expression validation

2009-08-09 Thread Karl Swedberg
Hi KeeganWatkins, Here is what the OP (nouky) wrote: I would like to validate a textbox that numbers cannot be entered into the text input That sounds to me like he doesn't want any numbers to be allowed anywhere within the value. I'm interested to hear why you think /[^\d]/g is more

[jQuery] Re: Regular Expression validation

2009-08-08 Thread Karl Swedberg
On Aug 7, 2009, at 2:53 PM, Michael Lawson wrote: yes, you can grab the value of the textbox and match it against a regular expression var reg = new RegExp(/[a-zA-Z]/); if(reg.test(string)) { return valid; } else { return not valid; } Hey Michael, I don't think that regular expression is

[jQuery] Re: Regular Expression validation

2009-08-07 Thread Michael Lawson
Subject:[jQuery] Regular Expression validation I would like to validate a textbox that numbers cannot be entered

[jQuery] Basic Selector expression only work on Chrome, no other browsers

2009-04-15 Thread Tao
Hi, I have the follow simple html code: div style=FILTER: progid:DXImageTransform.Microsoft.Gradient (GradientType=1, StartColorStr=#, EndColorStr=#7E003366); WIDTH: 794px; HEIGHT: 685px Hello /div And I try to use follow code to get the div element:

[jQuery] [autocomplete] Regular Expression

2009-04-07 Thread Franck Y
Hello, Is there anyway to implement a regular expression feature. It does not need to be full regxp butat leat soemthing like star *ek will match Creek Thanks

[jQuery] Re: Regular Expression

2009-04-07 Thread Scott
you can always use the RegExp object in JavaScript. On Apr 7, 3:26 pm, Franck Y franck...@gmail.com wrote: Hello, Is there anyway to implement a regular expression feature. It does not need to be full regxp butat leat soemthing like star *ek will match Creek Thanks

[jQuery] Re: Regular Expression

2009-04-07 Thread Jordon Bedwell
...@googlegroups.com] On Behalf Of Scott Sent: Tuesday, April 07, 2009 4:48 PM To: jQuery (English) Subject: [jQuery] Re: Regular Expression you can always use the RegExp object in JavaScript. On Apr 7, 3:26 pm, Franck Y franck...@gmail.com wrote: Hello, Is there anyway to implement a regular

[jQuery] Re: Regular Expression that works everywhere but in jQuery

2009-03-07 Thread ricardobeat
this seems to work: scrubbed = code.html().replace(/!--[^--]*--/gi,); The expression you had would eat everything between the first !-- and the last --. There's probably a more elegant way to do it, but I can't help any further. cheers, - ricardo On Mar 6, 4:10 pm, Adam adamhow...@gmail.com

[jQuery] Re: Regular Expression that works everywhere but in jQuery

2009-03-07 Thread Karl Swedberg
On Mar 7, 2009, at 4:20 PM, ricardobeat wrote: this seems to work: scrubbed = code.html().replace(/!--[^--]*--/gi,); I don't think that is going to work, either (at least, it didn't for me in firebug). You're probably expecting the character set, [^--], to negate the string --, but it

[jQuery] Re: unrecognized expression after jquery update to 1.3.1

2009-01-23 Thread Mauricio (Maujor) Samy Silva
-feira, 23 de janeiro de 2009 19:26 Assunto: [jQuery] unrecognized expression after jquery update to 1.3.1 After I upgrade to Jquery.1.3.1 , I received this error in my code uncaught exception: Syntax error, unrecognized expression: [...@id*=countryidentifier_] http://ajax.googleapis.com/ajax/libs

[jQuery] Re: filter expression with multiple class names

2008-12-08 Thread Hector Virgen
You can add a second class to your CSS rule by appending another dot and the class name: // Finds child elements that contain both classes $('div').find('.class-one.class-two'); -Hector On Mon, Dec 8, 2008 at 7:28 PM, mgl [EMAIL PROTECTED] wrote: Hello again, Does anyone know how (or if it

[jQuery] Re: filter expression with multiple class names

2008-12-08 Thread mgl
Hah, ok. I suppose I should have guess that one. Thanks for pointing it out. On Dec 9, 5:41 pm, Hector Virgen [EMAIL PROTECTED] wrote: You can add a second class to your CSS rule by appending another dot and the class name: // Finds child elements that contain both classes

[jQuery] Re: find expression and removing from the page

2008-11-07 Thread MorningZ
There is no $find object (unless you made one) it'd be $(#bigul #placeholder).remove(); On Nov 7, 1:56 pm, Dan B. [EMAIL PROTECTED] wrote: So lets say I have this simple HTML structure someonwheres in my document: ul id=bigul    li id=placeholder        some text   /li /ul and I

[jQuery] Re: reg expression for finding url [more of a javascript question]

2007-06-26 Thread sozzi
Hi Benjamin, I think you can find what you need right here in this blog: http://badassery.blogspot.com/2007/02/parseuri-split-urls-in-javascript.html I put up his code for testing purposes: http://www.sozzi.cn/tests/ParseUri.htm hope that is what you were looking for regards Angelo On Jun

[jQuery] Re: reg expression for finding url [more of a javascript question]

2007-06-26 Thread Benjamin Sterling
Angelo, that is awesome. I really do appreciate it. On 6/26/07, sozzi [EMAIL PROTECTED] wrote: Hi Benjamin, I think you can find what you need right here in this blog: http://badassery.blogspot.com/2007/02/parseuri-split-urls-in-javascript.html I put up his code for testing purposes:

[jQuery] Re: regular expression question

2007-05-20 Thread Jörn Zaefferer
Kush Murod wrote: If I have filter for example: var filter = progid:DXImageTransform.Microsoft.AlphaImageLoader(enabled=true,sizingMethod=crop,src='images/blah.gif'); I would like to extract src value which is images/blah.gif This seems to do the trick pretty well: var src =