Hello, I have
text-decoration:line-through;
in my css code, so it will strike through the word, however, the line is in the middle of the word, how do I make the line strike through lower part of the word?
Any trick on that?
Thanks for your help!
vinpkl
March 29, 2010, 4:15pm
2
do you want
text-decoration:underline
vineet
PaulOB
March 29, 2010, 4:18pm
3
You can’t actually change the position of the line-through and browsers do place it at slightly different positions.
You could hack it like this but has no effect in IE.
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Untitled Document</title>
<style>
span {
text-decoration:line-through;
position:relative;
top:3px;
}
b {
position:relative;
top:-3px;
font-weight:normal;
}
</style>
</head>
<body>
<p><span><b>Lorem ipsum text</b></span> lorem ipsum text</p>
</body>
</html>
Unless you really wanted an underline as suggested by vineet above