This is Interesting: Free Magazines for Graphics designers and webmasters  


Home > Archive > Stylesheets > October 2007 > Proper way to do hovers?





You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

Author Proper way to do hovers?
laredotornado@zipmail.com

2007-10-15, 6:16 pm

Hi,

I have this table cell

<td class="contextMenu"> </td>

and then this definition in my stylesheet

..contextMenu {
width: 16px;
height: 16px;
background-image:url('../images/menu_arrow.JPG');
cursor: pointer;
}

..contextMenu:hover {
width: 16px;
height: 16px;
background-image:url('../images/menu_arrow_hover.JPG');
cursor: pointer;
}

But, as you can probably guess, on PC Firefox, when I move my cursor
over the table cell, the background graphic does not change. What's
hte proper way to make the background image appear? I have verified
the path is correct.

Thanks, - Dave

Ben C

2007-10-15, 6:16 pm

On 2007-10-15, laredotornado@zipmail.com <laredotornado@zipmail.com> wrote:
> Hi,
>
> I have this table cell
>
><td class="contextMenu"> </td>
>
> and then this definition in my stylesheet
>
> .contextMenu {
> width: 16px;
> height: 16px;
> background-image:url('../images/menu_arrow.JPG');
> cursor: pointer;
> }
>
> .contextMenu:hover {
> width: 16px;
> height: 16px;
> background-image:url('../images/menu_arrow_hover.JPG');
> cursor: pointer;
> }
>
> But, as you can probably guess, on PC Firefox, when I move my cursor
> over the table cell, the background graphic does not change. What's
> hte proper way to make the background image appear? I have verified
> the path is correct.


You're probably not using the strict doctype. As François discovered the
other day, :hover doesn't work in Firefox quirks mode.

Put this at the top of each HTML file, first thing:

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN"
"http://www.w3.org/TR/REC-html40/strict.dtd">
Rik Wasmus

2007-10-16, 6:20 pm

On Mon, 15 Oct 2007 23:35:54 +0200, Ben C <spamspam@spam.eggs> wrote:
....
> Content-Type: text/html; charset=3DUTF-8

---------------------^^^^
Man, that header f*ks up the display here....

-- =

Rik Wasmus
Ben C

2007-10-16, 6:20 pm

On 2007-10-16, Rik Wasmus <luiheidsgoeroe@hotmail.com> wrote:
> On Mon, 15 Oct 2007 23:35:54 +0200, Ben C <spamspam@spam.eggs> wrote:
> ...
> ---------------------^^^^
> Man, that header f*ks up the display here....


Yes I got that wrong, I meant text/plain, but realized my mistake too
late.

I was using the name "François" as an excuse to test UTF-8 posting.
Rik Wasmus

2007-10-16, 6:20 pm

On Tue, 16 Oct 2007 16:51:26 +0200, Ben C <spamspam@spam.eggs> wrote:

> On 2007-10-16, Rik Wasmus <luiheidsgoeroe@hotmail.com> wrote:
>
> Yes I got that wrong, I meant text/plain, but realized my mistake too
> late.
>
> I was using the name "François" as an excuse to test UTF-8 posting.


OK, as long as it's not some weird client setting :)

(BTW: I saw 2 content-type headers, this one was followed by Content-Type:
text/plain; charset=iso-8859-1, so regardless all bets about what it was
going to do anywhere were off.. Weird opera remembered the text/html but
seems to have obeyed the iso-8859-1)
--
Rik Wasmus
Ben C

2007-10-16, 6:20 pm

On 2007-10-16, Rik Wasmus <luiheidsgoeroe@hotmail.com> wrote:
> On Tue, 16 Oct 2007 16:51:26 +0200, Ben C <spamspam@spam.eggs> wrote:
>
>
> OK, as long as it's not some weird client setting :)
>
> (BTW: I saw 2 content-type headers, this one was followed by Content-Type:
> text/plain; charset=iso-8859-1, so regardless all bets about what it was
> going to do anywhere were off.. Weird opera remembered the text/html but
> seems to have obeyed the iso-8859-1)


Thanks for the info! Looks like my newsreader/writer was putting the
ISO-8859-1 in for itself, which is its default. This is why I am
conducting such tests.

I shall now go and RTFM like I should have done in the first place...
Blinky the Shark

2007-10-16, 6:20 pm

Ben C wrote:

> Thanks for the info! Looks like my newsreader/writer was putting the
> ISO-8859-1 in for itself, which is its default. This is why I am
> conducting such tests.
>
> I shall now go and RTFM like I should have done in the first place...


After doing so, keep in mind the group news.software.readers. Small and
manageable and contians slrn gurus (and the author). See you there if
you pick it up. (To others: it's not specific to slrn, though.)

--
Blinky RLU 297263
Killing all posts from Google Groups
The Usenet Improvement Project - http://improve-usenet.org
Sponsored Links


Copyright 2003 - 2008 forum4designers.com  Software forum  Computer Hardware reviews