The Web Design Group

... Making the Web accessible to all.

Welcome Guest ( Log In | Register )

> <pre> giving unwanted line breaks
Old Timer 99
post Oct 26 2019, 05:48 PM
Post #1





Group: Members
Posts: 2
Joined: 26-October 19
Member No.: 27,024



I am a total newcomer to HTML and CSS. I was told that I should not use HTML tags because of deprecation. I'm having a great deal of difficulty achieving what I need to.

I am trying to create a rather simple text email in HTML. I am using <pre> to preserve whitespace and line feeds. The <pre> itself is causing unwanted linefeeds. I've googled for a solution and see that using either margin:0; or display:inline; should solve the problem but I cannot figure out how to implement that fix.

I have worked many, many hours on this but don't have much to show for it. I've tried many different approaches to solve this extra linefeed problem but can't find anything that will stop it. This is what I have so far, I don't know if the way I am doing this is dumb or not.

<!DOCTYPE html>
<html>
<head>
<style>
pre.a {
font-family: arial;
font-size: 16px;
font-weight: normal;
color: blue;
margin: 0px;
}
pre.b {
font-family: Courier New;
font-size: 12px;
font-weight: normal;
color: black;
margin: 0px;
}
pre.blue {
font-family: Courier New;
font-size: 12px;
font-weight: normal;
color: blue;
margin: 0px;
}
</style>
</head>
<body>
<pre class="a">
ESXi Server Summary Report v3.8
Generated 10-25-2019
</pre><pre class="blue">


I will very much appreciate any suggestions.
Thank you in advance.
User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post

Posts in this topic


Reply to this topicStart new topic
1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members:

 



- Lo-Fi Version Time is now: 16th April 2024 - 06:59 AM