Solved

Left Justify a Page

Posted on 2006-07-24
6
364 Views
Last Modified: 2010-04-06
Please can anyone tell me the best way to left justify a web page?  So that, the left edge of the page sits against the left edge of the screen (with 10px of padding).

Thanks!!

Ubee...
0
Comment
Question by:a466-ub52
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
6 Comments
 
LVL 13

Accepted Solution

by:
Mark_FreeSoftware earned 250 total points
ID: 17166474
using just a little css, this can be done fairly easy:

<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Q_21929293.html</title>
<style type="text/css">
<!--
body,html {
margin:0px;
padding:0px;
padding-left:10px;
}
-->
</style>
</head>

<body>
<p>Hello, this text aligns directly to the top,<br>
and 10 px from the left.</p>
<hr>
<p>&nbsp; </p>
<div style="background-color:#00FF00;">
  <p>This div is also aligned 10px from the left,</p>
  <p>just like the &lt;hr&gt; above </p>
</div>
</body>
</html>
0
 
LVL 30

Expert Comment

by:callrs
ID: 17173597
Awesome dude. I gotta learn more CSS!
0
 
LVL 13

Expert Comment

by:Mark_FreeSoftware
ID: 17174557

this is not part of the Q,
but here are some tuts to get you started:

http://www.practicalpc.co.uk/webbuilding/design/css1.htm
http://www.wise-women.org/tutorials/csstut/

0
 
LVL 5

Assisted Solution

by:floorman67
floorman67 earned 250 total points
ID: 17177106
great solution for a few pages but if it is for jsut a single page you can do it with fewer keystrokes by adding this to the body tag

<BODY LEFTMARGIN=10>
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Node js - send response after all promises are resolved 1 73
WordPress/WooCommerce security best practices? 2 121
website content maintenance 3 137
Problem to copy file 14 91
This article covers the basics of the Sass, which is a CSS extension language. You will learn about variables, mixins, and nesting.
Shoutout to Emily Plummer (http://www.experts-exchange.com/members/eplummer26.html) for giving me this article! She did most of it, I just finished it up and posted it for her :)    Introduction In a previous article (http://www.experts-exchang…
Viewers will learn one way to get user input in Java. Introduce the Scanner object: Declare the variable that stores the user input: An example prompting the user for input: Methods you need to invoke in order to properly get  user input:
Video by: Mark
This lesson goes over how to construct ordered and unordered lists and how to create hyperlinks.

751 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question