git.asbjorn.biz
/
jquery.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (from parent 1:
269ff25
)
Added fix for multiple attribute selectors w/ test cases.
author
John Resig
<jeresig@gmail.com>
Tue, 15 Aug 2006 04:40:21 +0000
(
04:40
+0000)
committer
John Resig
<jeresig@gmail.com>
Tue, 15 Aug 2006 04:40:21 +0000
(
04:40
+0000)
src/jquery/jquery.js
patch
|
blob
|
history
diff --git
a/src/jquery/jquery.js
b/src/jquery/jquery.js
index
bdb46a8
..
da0e582
100644
(file)
--- a/
src/jquery/jquery.js
+++ b/
src/jquery/jquery.js
@@
-1089,6
+1089,9
@@
jQuery.extend({
* @test t( "Attribute Equals", "a[@rel='bookmark']", ["simon1"] );
* @test t( "Attribute Equals", 'a[@rel="bookmark"]', ["simon1"] );
* @test t( "Attribute Equals", "a[@rel=bookmark]", ["simon1"] );
* @test t( "Attribute Equals", "a[@rel='bookmark']", ["simon1"] );
* @test t( "Attribute Equals", 'a[@rel="bookmark"]', ["simon1"] );
* @test t( "Attribute Equals", "a[@rel=bookmark]", ["simon1"] );
+ * @test t( "Multiple Attribute Equals", "input[@type='hidden'],input[@type='radio']", ["hidden1","radio1","radio2"] );
+ * @test t( "Multiple Attribute Equals", "input[@type=\"hidden\"],input[@type='radio']", ["hidden1","radio1","radio2"] );
+ * @test t( "Multiple Attribute Equals", "input[@type=hidden],input[@type=radio]", ["hidden1","radio1","radio2"] );
*
* @test t( "Attribute Begins With", "a[@href ^= 'http://www']", ["google","yahoo"] );
* @test t( "Attribute Ends With", "a[@href $= 'org/']", ["mark"] );
*
* @test t( "Attribute Begins With", "a[@href ^= 'http://www']", ["google","yahoo"] );
* @test t( "Attribute Ends With", "a[@href $= 'org/']", ["mark"] );
@@
-1286,7
+1289,7
@@
jQuery.extend({
.replace( 'S', "([a-z*_-][a-z0-9_-]*)" )
// Look for something (optionally) enclosed with quotes
.replace( 'S', "([a-z*_-][a-z0-9_-]*)" )
// Look for something (optionally) enclosed with quotes
- .replace( 'Q', " *'?\"?([^'\"]*)'?\"? *" ), "i" );
+ .replace( 'Q', " *'?\"?([^'\"]*?)'?\"? *" ), "i" );
var m = re.exec( t );
var m = re.exec( t );