Skip to main content

Bug Tracker

Side navigation

#13046 closed bug (notabug)

Opened December 13, 2012 10:57AM UTC

Closed December 13, 2012 01:22PM UTC

Attribute Not Equal Selector does not work properly

Reported by: Alex Tokar <alex.tokar@gmail.com> Owned by:
Priority: undecided Milestone: None
Component: unfiled Version: 1.8.3
Keywords: Cc:
Blocked by: Blocking:
Description

Attribute Not Equal Selector does not work if element selector is not set explicitly. Fo the next sample color is set for all elements:

<div id="a">a</div>
<span id="b">b</span>
<a id="c" href="#">c</div>
		
<script type="text/javascript">
	$(function(){
		$('[id!="a"]').css('color', 'red');
	})
</script>
Attachments (0)
Change History (2)

Changed December 13, 2012 11:05AM UTC by Alex Tokar <alex.tokar@gmail.com> comment:1

Changed December 13, 2012 01:22PM UTC by dmethvin comment:2

resolution: → notabug
status: newclosed

You're setting the color on ALL elements, including the body, which is where a inherits its color from.