[thelist] CSS and NN4.x series - solid border on input field

Alastair Murdoch alastair at mtbtuned.freeserve.co.uk
Wed May 16 07:05:45 CDT 2001


Isn't there issues about using @import with some versions of IE??

You could use a small piece of JavaScript to add the style if the browser
supports it.

Something like:

if (document.getElementById)
{
document.write('<style type="text/css"><!--')
document.write('.yourclassname { yourstyles}')
document.write('--></style>')
}

worked for me on the newer 5+ browsers.  You may want to elaborate a bit
depending on what browsers your targeting.

cheers

Alastair

 -------------------------------
A l a s t a i r   M u r d o c h
c o n s u l t a n t  @  c u b e

    [t:]  01292 27 00 99
    [m:]  07974 323 551
    [w:] www.cubeit.co.uk


-----Original Message-----
From: thelist-admin at lists.evolt.org
[mailto:thelist-admin at lists.evolt.org]On Behalf Of Niklaus Haldimann
Sent: 16 May 2001 12:42
To: thelist at lists.evolt.org
Subject: Re: [thelist] CSS and NN4.x series - solid border on input
field


Elfur Logadóttir wrote:
> http://elfur.com/penninn/index.html
>
> that looks just beautiful in ie (at both 5.x and 6beta) but barfs when
entered
> using NN4.x
>
> the barfing part occurs at the bottom of the left column where the input
field
> is supposed to have style in IE - but just nothing in NN.
>
> Does not using the border on input fields have to be my solution?

I have never been able to make CSS borders work in NN4.x. Somebody
correct me if I'm wrong, but I think it's just not possible. There's a
workaround though: Make a separate class with just the border definition
and put it in a separate external style sheet, and include this style
sheet using @import. NN4.x will ignore the border class, since it
doesn't know @import. All other browser capable of CSS will display the
border as you intend.

Good luck,
N.

--
Niklaus Haldimann, Frontend Engineer
At Work: http://www.rosa.com
At Play: http://www.ubique.ch

---------------------------------------
For unsubscribe and other options, including
the Tip Harvester and archive of TheList go to:
http://lists.evolt.org Workers of the Web, evolt !





More information about the thelist mailing list