0

here want i want

html file

    home       about us      log in

iam thing puting in <p> tag and than do

word-spacing:30px;

in css.

but problem with this is that it will do this:

home        about         us           log          in

also i dont want to do <pre>

4
Contributors
4
Replies
5
Views
5 Years
Discussion Span
Last Post by hwoarang69
4

@hwoarang69

puting space in words css

Is this a navigation menu bar?

You can't used <p> or <pre> tags to adjust CSS with it because it will affect other <p> tags.

Votes + Comments
To Rectify what some retard did to LastMitch
3

Here try this:

HTML:

<div id="menu">
  <ul>
    <li><a href="#">Home</a></li>
    <li><a href="#">About Us</a></li>
    <li><a href="#">Log In</a></li>
  </ul>

  <span></span>
</div>

CSS:

#menu {
  text-align: justify;
}

#menu * {
  display: inline;
}

#menu span {
  display: inline-block;
  position: relative;
  width: 100%;
  height: 0;
}

Or just follow along with this: Click Here

Hope it helps!

1

While I am sure that you can make further adjustments to get this to work using a paragraph element, you are trying to create a navigational menu. So i dont recommend the use of a paragraph element. Semantics should be considered when you develop. For one, when a web spider tries to index your site, you want to help the spider understand the context of the data it's collecting.

If you are new to developing, you may want to consider learning HTML5. There are new elements such as the nav element as well as many others that bring semantics into the design.

In any case, if you are looking for a standard navigational menu, I have some examples that you are free to use and modify for your purposes.

http://www.itgeared.com/articles/1420-css-multi-level-navigation-menu-tutorial/

Edited by JorgeM

This question has already been answered. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.