May 30
Do you want to crash your visitors IE6?
Add <div id="tags">anything</div> to your page and suggest them to print it.
To avoid printing crash for IE6 just avoid id name tags
It seems it works (umm, crashes) to “native” IE6 and doesn’t work to IE6 within MultipleIE installation.
May 29
Simplest JS function to add/remove custom classname with carrying about another classes.
just to remember.
function toggleClassName(obj,sClassName,switcher){
if(switcher){
if(obj.className.indexOf(sClassName)==-1)
obj.className=obj.className + ' ' + sClassName;
}else{
var re = new RegExp(sClassName,'g');
obj.className=obj.className.replace(re,'');
}
}
sapienti sat
Apr 16
links:
MipTV Media Market
Content 360 Pitching Competition @ MipTV
our project/concept:
Cont-Act! Content Actual. Link Different! is in BBC’s category “On-demand Participation”
Support us!
P.S. We won!
Oct 25
There is no brand new subject, really.
even 2 old articles (Vertical centering using CSS and CSS Vertical Centering again) from this blog.
2 problems:
1) Small height: if browser height is smaller than main container (for all browsers):
function adjustHeight(){
if(document.body.offsetHeight > 450){
document.body.style.height='100'+'%';
}else{
document.body.style.height='450px';
}
}
onload and onresize, of course.
2) IE7: this rule:
#ContainerDiv {position: relative; top: -50%;}
moves the #ContainerDiv above the top browser’s border for 50%. Reasonable, huh.
The cure:
#ContainerDiv {position: relative; top: expression(document.body.offsetHeight/2-this.offsetHeight/2);}
for custom IE7 CSS file using cond. comments:
<!--[if IE 7]>
<link rel="stylesheet" href="/css/ie7.css" type="text/css" media="screen" />
<![endif]-->
Sep 13
Don’t use em for font-size. Use %.
Usually 1em=100%.
Create a model:
<p style="font-size: 1em;">1 em Lorem Ipsum text</p>
<p style="font-size: 100%;">100% Lorem Ipsum text</p>
Then try to change text size (IE: View -> Text Size or Ctrl+Scroll) and you’ll get the difference.
But better just save the time and don’t use ems
Disclamer: of course px is EVIL
We don’t talk about fixed font-sizes at all.
Disclamer #2. Of course Opera and FireFox are best browsers and they change not only font-size but everything. I am talking about damn IE.
Recent Comments