Id AND class in a tag, does one have to come before the other?


#1

are
<div id="best_friend" class="friend"></div>
and
<div class="friend" id="best_friend"></div>
both acceptable and equivalent?


#2

Both are acceptable, the order of attributes doesn't matter (class and id are both attributes)