timmywil
3ed4b22073
Run property names through propFix in removeProp
2011-05-04 11:40:46 -04:00
timmywil
480b88ca37
Set corresponding property to false when removing boolean attributes. Fixes #9094
2011-05-04 11:29:38 -04:00
timmywil
97144424cc
Update boolean check to avoid crashes, add all name fixes to propFix (properties are case-sensitive in all browsers), add tests for prop
2011-05-04 00:31:01 -04:00
John Resig
a9d9f8c542
If no hook is provided, and a boolean property exists, use that to return an attribute-style value for boolean attributes. Fixes #9079 .
2011-05-03 21:44:42 -04:00
timmywil
4ac2fdda2c
Fix setting value attributes on option elements. Fixes #9071 .
2011-05-03 14:48:36 -04:00
timmywil
24a8ffb3ea
Test for a colon in attribute names for IE6/7. Fixes #1591 .
2011-05-01 17:09:50 -04:00
Rick Waldron
bf678fd9d6
Restores var names to satisfy the crock-machine. Supplements #9008
2011-04-28 22:26:34 -04:00
timmywil
5165033883
Add tests data- and aria- attributes and the autofocus boolean attribute and some style updates in jQuery.attr
2011-04-25 12:41:12 -04:00
aFarkas
83e9ce95d7
handle data- and aria- special
2011-04-25 12:41:12 -04:00
aFarkas
9559b1a294
dealing with boolean content attribute
2011-04-25 12:41:12 -04:00
timmywil
15ccae91db
Switch the form nodeName check in attr to use jQuery.nodeName for consistency
2011-04-23 13:56:51 -04:00
timmywil
2942be780f
Combine the support tests for radioValue and appendChecked
2011-04-22 00:27:52 -04:00
timmywil
3ac9eb7ce3
Landing pull request [337]( https://github.com/jquery/jquery/pull/337 ). Value of radio inputs resets when type is set after the value in all IEs. Fixes #8570 ([bug]( http://bugs.jquery.com/ticket/8570 )).
2011-04-21 21:33:09 -04:00
timmywil
103d325887
Follow w3c standard for setting the common boolean attributes to the same name(selected, checked, readOnly, and disabled)
2011-04-19 17:48:07 -04:00
timmywil
825d3d96ce
Only use getAttributeNode on buttons when setting value
2011-04-19 13:17:38 -04:00
timmywil
34d80709ce
Fix value attribute and val for value on button elements. Fixes #1954
2011-04-17 18:17:31 -04:00
timmywil
b6d21592cb
Add support for setting the cellPadding attribute in IE6/7
2011-04-14 23:11:49 -04:00
timmywil
cb659c6054
retrieving list with getAttribute is fine, no need to add list here anymore
2011-04-11 19:30:20 -04:00
jeresig
92dfb53314
Merge branch 'attrhooks.1.6v2' of https://github.com/timmywil/jquery
2011-04-10 17:11:35 -04:00
timmywil
215c507f79
Added back support.js test for getSetAttribute and removed some duplicate code that crept into attributes.js
2011-04-10 17:08:18 -04:00
jeresig
f89edbc6e4
Merge branch 'modest_val_proposal' of https://github.com/timmywil/jquery into timmywil-modest_val_proposal
...
Conflicts:
src/attributes.js
2011-04-10 16:56:56 -04:00
jeresig
b92d2f0bc9
Merge branch 'attrhooks.1.6v2' of https://github.com/timmywil/jquery into timmywil-attrhooks.1.6v2
...
Conflicts:
src/attributes.js
2011-04-10 15:41:51 -04:00
timmywil
3a1b4661f5
#8150 - When removing the width and height attributes in IE6/7, setting to "" actually sets to 0 instead of auto
...
- Having fixed this automatically with the use of removeAttribute in browsers that support it, this will fix it for IE6/7 as well.
- This has no effect on width/height styles set elsewhere( test added to removeAttr )
- With this addition, I need to call attr in removeAttr for IE6/7, which means boolean calls like .attr("checked", "") will no longer remove the attribute, which I think is fine. .attr("checked", false) will still remove. If I had left it, it would have gone in an infinite loop since setting to empty string is the only way to remove it in these browsers.
- The hrefNormalized hooks were returning null if they weren't present. Added the null check to the getter.
- Now that the style support fails in IE8 as well due to uppercasing everything, no need to have style included with the hrefNormalized hooks
2011-04-09 17:25:06 -04:00
timmywil
d47c0ae422
Performance testing: localize val to each block and only set val to value when not a function
2011-04-05 22:40:12 -04:00
timmywil
94fff6ff62
Remove the unused radiocheck regex
2011-04-04 14:22:58 -04:00
timmywil
6f79bee3e3
Normalize css property names to lowercase for comparisons on a .attr('style') call since IE uppercases everything
2011-04-03 19:13:41 -04:00
timmywil
ad2b3bc9f9
Found a problem removing the style attribute in IE
...
- Style is now a special case in IE6/7 to set cssText. My goal is to avoid calling attr again for the performance benefit, and at this point it would also cause an infinite loop for the boolean attributes hooks such as selected & checked. Nevertheless, style seems to be the only one requiring a special call.
2011-04-03 19:13:41 -04:00
timmywil
2a8a2b6148
Move the if statement in jQuery.fn.removeAttr to jQuery.removeAttr
...
- Extra testing on removeAttr and IE form weirdness( all good )
2011-04-03 19:13:41 -04:00
timmywil
ff75767558
Minor adjustments and cleanup, including normalizing the value to a string when setting( list of changes below )
...
- Normalize set value to string to synchronize return type cross-browser
- Add style attrHook to propHooks to support style getting in all browsers for both attr and prop
- Extend the selected propHook instead of overriding a possible set function
- Remove selected propHook TODO since there is no selected content attribute and it should return null
2011-04-03 19:13:41 -04:00
timmywil
8cbf551a48
#5413 - Much shorter solution for getting width/height in ie6
...
- #8255 Added support for the list attribute in browsers that support it (it is automatically readonly, but can be set if using getAttribute( name, 2)
2011-04-03 19:13:41 -04:00
timmywil
5fc2281fcc
- Added a hook to swap display none for width and height in browsers that do not sufficiently support get/setAttribute
2011-04-03 19:13:41 -04:00
timmywil
1e9b3ef3d8
Move the check for the name attribute out of attr and down to the formHook definition
2011-04-03 19:13:41 -04:00
timmywil
a4d44979c6
Shorten the logic for hooks, ternary was unnecessary
2011-04-03 19:13:41 -04:00
timmywil
217a7abc43
Add name to prop hooks as well
2011-04-03 19:13:41 -04:00
timmywil
11c97bb066
Add attribute name to paramaters for hooks
2011-04-03 19:13:40 -04:00
timmywil
03da4c7ca7
Style formatting
2011-04-03 19:13:40 -04:00
timmywil
448111cbd4
No longer need to check for objects or string of null with the special form treatment and updates to removeAttr
2011-04-03 19:13:40 -04:00
timmywil
5caf7d8376
Clean up
2011-04-03 19:13:40 -04:00
timmywil
56014a1a00
Shorten even further
2011-04-03 19:13:40 -04:00
timmywil
479b28fb6a
Modularize special form code for IE6/7 and clean up attr again
2011-04-03 19:13:40 -04:00
timmywil
e0900a686d
Fix issue where non-existant attributes on forms in IE6/7 were throwing errors
2011-04-03 19:13:40 -04:00
timmywil
3892df207d
Add test for bug #3116
2011-04-03 19:13:40 -04:00
timmywil
9e05a0a37f
Fix #6562 , tighten up the special code for form objects, add name attrHook for IE6/7, and don't check for undefined with getting hook'd attr
2011-04-03 19:13:40 -04:00
timmywil
102053abd8
Fix #7472 and added test for #3113
...
- Forms with an input that has either name="action" or name="some-other-attr-on-the-form" caused problems in IE6/7. This is fixed.
- Changed check in $.attr for ret === null to typeof ret === "object" to catch any inputs that are accidentally retrieved in IE6/7, since attributes cannot be set to objects and typeof null === "object"
2011-04-03 19:13:39 -04:00
timmywil
11cfdb2394
Non-existent attribute for jQuery.attr no longer needs to check for "undefined"
...
- Remove an unnecessary var
- Use variable in removeAttr for better minification
2011-04-03 19:13:39 -04:00
timmywil
dfeeb872d6
Performance enhancement switching nodeType to a var
2011-04-03 19:13:39 -04:00
timmywil
d28922bc03
Pass jslint, 2 missing semicolons
2011-04-03 19:13:39 -04:00
timmywil
dbe3b7a9d0
Style edits according to comments from John and rwaldron.
2011-04-03 19:13:39 -04:00
timmywil
f578e0f997
Don't use extend when setting the action attrHook for IE6/7
2011-04-03 19:13:39 -04:00
timmywil
77c559c3cb
No, don't return this.
2011-04-03 19:13:39 -04:00