pseudo-element: first-line

B

bongo

I'm trying the pseudo-element: first-line, but i can't succeed in use it.
This is my sintax in an external CSS:


..autore:first-line { font-weight: bold }


In my page I have various div and, among them, I have:

<div class="autore">abcdefghilmno pqrstuvz ad so on</div>


The pseudo-element listed above does not work, can you tell me why?

Thanks
 
C

Chris Vogel

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
I'm trying the pseudo-element: first-line, but i can't succeed in use it.
This is my sintax in an external CSS:


.autore:first-line { font-weight: bold }


In my page I have various div and, among them, I have:

<div class="autore">abcdefghilmno pqrstuvz ad so on</div>


The pseudo-element listed above does not work, can you tell me why?

Thanks

It looks fine to me. Try validating the CSS
<http://jigsaw.w3.org/css-validator/> and fixing the errors. (Don't
worry about the warnings right now.) You might have a syntax error
higher up in the stylesheet that's causing your browser to skip over it.
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.2.2 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFFes4w7s5PbTgRmZARAiQ6AJ9wL5MJz83Gd8iqHG9XBONk4K4IYQCcCvaj
b3ju6O0U8LKJlcrNdfXHs+s=
=NU+a
-----END PGP SIGNATURE-----
 
J

Jonathan N. Little

bongo said:
I'm trying the pseudo-element: first-line, but i can't succeed in use it.
This is my sintax in an external CSS:


.autore:first-line { font-weight: bold }


In my page I have various div and, among them, I have:

<div class="autore">abcdefghilmno pqrstuvz ad so on</div>


The pseudo-element listed above does not work, can you tell me why?

1) Maybe it is working but your DIV content is so short that only one
line is showing that you don't realize that it is bold. Add more content
that forces the content to wrap...

2) The font that you are using doesn't have a "bold" version on your
machine or the bold is very subtle.

3) What browser are you testing with? Maybe it does not support
"first-line" pseudo-element, IE before 5.5 does not.
 
B

Bergamot

bongo said:
The pseudo-element listed above does not work, can you tell me why?

Post a URL showing the problem. Then people won't have to guess why it
isn't working for you.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,755
Messages
2,569,536
Members
45,013
Latest member
KatriceSwa

Latest Threads

Top