In draft form, please forgive the poor grammar and spelling mistakes. :-)
Please note that this is not a page to find hacks for IE 8 but rather how to target IE 7 without also targeting IE 8. All hacks are valid CSS. Please use wisely.
In particle physics there is a term used to describe a pool of subatomic particles that are composed of elementary particle. There are many of them and they are referred to as a whole as the Hadron Zoo. Early on only a few were known but further test showed that these particles were predictable. Knowing this we can relate this to IE hacks.
Composite subatomic particles
Flavor: Up, Down, Charm, Strange, Top and Bottom.
Spin: Being either matter or antimatter.
Color: Red, Green or Blue.
Weird and Wonderful world of IE Hacks
Comment format: No comment, /**/, /*\*/, /*/, /*\*//*/, /*/*/.
Target or Filter.
Type: Simple (universal or type), Child or Adjacent selector.
Luckily for us we don't need a particle accelerator to discover the hacks but just a browser named Internet Explorer.
In March 2000 IE 5/Mac was released and was considered the most standard compliant browser of it's time.
Filtering IE 5 and IE 6
Browser
html>body
head+body
2~3
html>body
head+body
TargetingIE5/Mac
Target
star html>body
star star head+body
4~5
* html>body
* * head+body
The IE 5/Mac band Pass Fliter
/*\*//*/
E {property: value;}
/* */
In hindsight I wonder what Tantek Çelik will think of this filter that he created. It was in July 2004 as he was leaving his employment at Microsoft where he was the manager of the development of IE 5/Mac. At the request of Douglas Bowman he created the IE 5/Mac band pass filter. Already once opening Pandora's box of hacks, little did Tantek know that four years later and three version later of IE that this latent filter was going to open the new Pandora's Box with IE 8.
Along comes IE 7
The end of star html was beckoning, Chris Wilson was going to kill the bug but alas it was not a complete job. Very quick a new hack arrived. Now the universal selector was going to select the Doctype.
<!DOCTYPE> + <html>
Targeting IE7 and IE8
Target
star+html
6
*+html
Not that the star html was completely dead, just triggered in a new way.
The flavours of the filters became more colorful since we could filter each version of IE.
Filtering IE5~IE6
Filter
html>body
head+body
7~8
html/**/>body
head/**/+body
Filtering IE5~IE7
Filter
html>body
head+body
9~10
html>/**/body
head+/**/body
Filtering IE5~6 & IE8
Filter
html>body
head+body
11~12
html/*/*/>body
head/*/*/+body
Filtering all versions of IE/Win
Filter
html>body
head+body
13~14
html >/*/*/body
head +/*/*/body
Along comes IE8 and the opening of pandora's box
More to come.....
Targeting IE5~IE6 and IE 8
Target
star html or star+html
15
* /*/+ /**/html
Targeting IE5~IE6 and IE 8
Target
star html or star+html
16
* /*\*//*/+ /**/html
Targeting IE8 and Opera 9.0~9.2
Target
Star+html
17
/*\*//**/*+/**/ html
Targeting IE 8
Target
Star+html
18
head/*/+body/**/
19
head/*\*//*/+body/**/
Filtering IE 8
Filter
IE5~6 & IE8
20
html>head/*/*/+body
Targeting IE7 and Opera 9.0~9.2 and filtering IE8
Target
star*+html>head+body
21
*+html>head/*/*/+body
Filtering IE 8
Filter
IE8
IE8
22
html/*/>/**/ body
html/*/>/**/
23~24
html/*/+/**/ body
html/*/+/**/
25~26
html/*/*/ body
html/*/*/
27~28
html/*/ * /**/ body
html/*/* /**/
Targeting IE 7 and filtering IE 8
Target
star+html+ body
star+html>, star+html+ & star+html
29
-
*+html/*/>/**/
30~31
*+html/*/+/**/ body
*+html/*/+/**/
32~33
*+html/*/*/ body
*+html/*/*/
34~35
*+html/*/ * /**/ body
*+html/*/* /**/
Filtering all IE versions
Filter
IE5~IE8
IE5~IE8
36
html/*\*/>/*/*/body
html/*/*/>/*/*/body
37
head/*\*/+/*/*/body
head/*/*/+/*/*/body
Justin Rogers announced that star+html and comments will not be selected.