473,405 Members | 2,167 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,405 software developers and data experts.

Remove the space before a paragraph

I am new to CSS and have spent many unsuccessful hours trying to find a way to remove the space above the beginning of a paragraph. What I want to do is to have a bold heading <H3> in 12pt followed immediately on the next line by text in normal 10pt. I'm sure there is a simple answer that escapes me but how do I do it?
Oct 5 '06 #1
7 21925
drhowarddrfine
7,435 Expert 4TB
To remove the margin, just put margin:0 in your css for both elements.
Oct 5 '06 #2
Thank you for your response. That's exactly what I tried but got not result - still have space above and below. ??
Oct 6 '06 #3
Is this correct - in my style sheet?
P.nospace { margin-top:0;
margin-bottom:0;
padding:0;
margin-left:50px;
font-family:Arial, sans-serif;
font-size:10pt;
color:white }

In the text: <P class="nospace">Text of paragraph</P>

Thanks for your help.
Oct 6 '06 #4
Seith
16
Just like in a book, a paragraph is given a new line

Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Praesent luctus. Sed eget nulla. Proin erat velit, porttitor vitae, laoreet vel, facilisis et, nisi. Fusce id neque eu est lacinia venenatis. Vivamus nec dolor nec purus placerat tincidunt. Fusce erat. Nunc imperdiet suscipit risus. Pellentesque mauris. Vivamus ligula. Morbi bibendum convallis lacus. Etiam mi. Morbi eget pede nec velit fringilla posuere. Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Nunc risus.
paragraph break
Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Praesent luctus. Sed eget nulla. Proin erat velit, porttitor vitae, laoreet vel, facilisis et, nisi. Fusce id neque eu est lacinia venenatis. Vivamus nec dolor nec purus placerat tincidunt. Fusce erat. Nunc imperdiet suscipit risus. Pellentesque mauris. Vivamus ligula. Morbi bibendum convallis lacus. Etiam mi. Morbi eget pede nec velit fringilla posuere. Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Nunc risus.


To have it just move onto another line, you use <br> for a BREAK and not a new paragraph =)
Oct 7 '06 #5
Sorry, perhaps I haven't made it clear. I know about <BR> but what I want to do is to follow text immediately after <H3>Heading</H3> i.e. not have space before the line that follows and it should not be bold and be a smaller font as specified in the style sheet. All text and headings are white on a maroon background. Thanks
Oct 7 '06 #6
ronverdonk
4,258 Expert 4TB
To simplify it:

[HTML]

<h3 style="margin:0;line-height:12pt;font-size:12pt;">Hello there</h3>
<p style="margin:0;font-size:10pt;line-height:10pt">and to you too</p>

[/HTML]

Ronald :cool:
Oct 7 '06 #7
Thanks, all, for the help. Success!
Oct 10 '06 #8

Sign in to post your reply or Sign up for a free account.

Similar topics

8
by: JT | last post by:
i have written some asp that reads a fixed length text file, line by line, inserting each line into my database. my problem is that the text file format seems to have extra space at the end of the...
9
by: Daniel | last post by:
Hi I'd like to discuss the following problem: How to remove the space between two images (img)? <img alt="First" src="first.gif"> <img alt="Second" src="second.gif"> I tried:
8
by: Joseph | last post by:
I have a textBox that people writes stories in it. They can use for format. I have Aspell installed on the server, so people can make correction to their text. Sometimes, they forget to add a...
2
by: Beffmans | last post by:
Hi How do i remove the space below the 'hello'? <TABLE> <tbody> <tr> <td> <asp:panel id="pnlTop" Runat="server"> <TABLE>
8
by: voroojak | last post by:
i want to remove space in my table. it is a text box and i want to remove the space after the character. the field is integer thanks aot
9
by: voroojak | last post by:
I cant remove the space in my table. i used Trim and replace. but still it sis not working. Dim campign_number As Integer campaign_number = Trim(Me.tbx_campaign_number) With rst ...
5
by: Steve | last post by:
I'm getting string returned from my Database with a space in front of it, it sometimes it looks like this 8 9 10 1 and so one, how can I remove the white space in front of the numbers? Its...
4
by: ashish1779 | last post by:
hi I am new in PHP, i have face one problem when I crawl any site and i have to save the whole HTML content in database, on that time all the HTML tags are changes into the extra space in content...
2
by: akshaycjoshi | last post by:
I want to remove the image from ToolStripMenuItem but i can't.I set the DisplayStyle to 'Text' but nothing happens.The blank space before the text remains visible. I actually wanted to get rid of...
6
by: Mladen Mavrovic | last post by:
Hi everyone, I have to fix this asap, and I tried all I know, but there was no joy. Please, take a look at http://stampamajica.in.rs/ There are 3 html pages there. Can anybody tell me how to...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.