By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
443,665 Members | 1,258 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 443,665 IT Pros & Developers. It's quick & easy.

Selector for text or <p> after <H2>?

P: n/a
I run the web site for a University department. A few of
my authors will carefully write:

<h3>Title</h3>
<p>Some text here.</p>
<p>Second paragraph.</p>

Most of us can't be bothered(!):

<h3>Title</h3>
Some text here.
<p>Second paragraph.

I would like my margin under the <h3> to be a little less than my
margin between paragraphs. My problem is that I can't seem to come up
with a selector that distinguishes between the two cases above, ie <h3>
immediately followed by <p> and <h3> followed by text then <p>.

A selector like: h3 + p matches both. Is there a selector for 'naked'
text?

Thanks

John
Jul 21 '05 #1
Share this Question
Share on Google+
1 Reply


P: n/a
Will this not be matched by rules for "body"?

--
####################
## PH, London
####################
"John Rowe" <ro**@excc.ex.ac.uk> wrote in message
news:vn************@kenny.ex.ac.uk...
I run the web site for a University department. A few of
my authors will carefully write:

<h3>Title</h3>
<p>Some text here.</p>
<p>Second paragraph.</p>

Most of us can't be bothered(!):

<h3>Title</h3>
Some text here.
<p>Second paragraph.

I would like my margin under the <h3> to be a little less than my
margin between paragraphs. My problem is that I can't seem to come up
with a selector that distinguishes between the two cases above, ie <h3>
immediately followed by <p> and <h3> followed by text then <p>.

A selector like: h3 + p matches both. Is there a selector for 'naked'
text?

Thanks

John

Jul 21 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.