I am trying to build a template for an Ebay ad and I am stuck.
How do I write inline CSS for anchor tags using this as a guide
a.index2:link {color: #FFFFFF ; text-decoration: none ; font-size: 1em ; font-family: arial ; }
a.index2:visited {color: #FFFFFF ; text-decoration: none ; font-size: 1em ; font-family: arial ; }
a.index2:active {color: #FFFFFF ; text-decoration: none ; font-size: 1em ; font-family: arial ; }
a.index2:hover {color: #E3170D ; text-decoration: underline ; font-size: 1em ; font-family: arial ; }
I just dont know how to write the code with the pseudo classes.
Thanks for the help
There is no way to write that inline, sorry to tell you that :(. Even if you could there is no possible way you could think of writing it.
I was reading something about pre tags. How would I use that? Or does that work either?
<pre> tags keep the white-space and indentation in the markup. What exactly did you want to know about it? You can’t ever put pseudo classes in an inline style.
This is the source of the page that I was looking at.
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html lang="en">
<head>
<meta http-equiv="content-type" content="text/html; charset=utf-8">
<title>CSS and the anchor tag</title>
</head>
<body>
<h2>Dealing with the anchor tag</h2>
<p title="you should probably use all 5 of these each time">
Here is an example of the five (5) statements about anchors which
should be in a CSS file:
</p>
<pre>
a {
font: italic 100%/1.0 Georgia, serif;
}
a:link {
color: #0000FF;
}
a:visited {
color: #FF0000;
}
a:hover {
background: #FFFF00;
}
a:active {
color: #00FF66;
}
</pre>
<p>
And here is how to deal with images which are also anchors:
</p>
a:link IMG, a:visited IMG {
border-style: none;
}
</pre>
<h2>Examples</h2>
<p>
Without applying the above styles:<br/>
image-anchor linked to <a href="http://www.gotfuturama.com/" title="go to futurama site"><img
src="http://www.gotfuturama.com/img/topright1.gif" width="88" height="31"/></a><br/>
and text-anchor linked to the <a href="http://www.it.rit.edu/" title="go to IT Dept site">IT Dept</a>
</p>
<p>
<a href="./complete.html" title="same content with styles">Look here</a> for the same page with
style attached.
</p>
</body>
</html>
It just seemed that this was a different way to do anchor classes other than internal or external. Ebay will not allow those types of CSS so I was trying to find a way around it.
Ebay will not allow those types of CSS so I was trying to find a way around it.
You could use mouseover event to emulate the :hover, but I don’t really think it’s a big deal if everyone else is limited.
Are you sure that they don’t allow it because it isn’t working? Perhaps ebay is overriding those styles with some of their own.
Javascript has some useful tools but I doubt ebay would allow you to use it.
The mouseover idea was perfect. It is not ideal but it definitely works for this application. Thanks so much
Sure, though I wouldn’t advise too much scripting.
I’m surprised Ebay allows that because of all the insecurity it can bring depending on how advanced you use it…Weird.
Well it worked in the preview anyway. Sometimes these things have a way of breaking between the preview and the live version. Keep your finger crossed.
Ok let us know how that goes: chances are if preview worked then real live version would work also.