text format with css

J

JJ

I have a small box on the right side of the page. The title has a image
behind it. The title is 150px wide. The text that I type below it is to be
150px wide, but it just keeps getting bigger as I type. It does not stay in
the confines of 150px. I have the css for the sidebar, the sidetitle, the
sidenews (which is the text that won't stay to 150px)

any suggestions

thanks
jj



---------html--------
<Div id="sidebar">

<Div id="sidetitle">
Breakfast Menu
</div>

<Div id="sidenews">
<P>tttttteeeeeeeeeeeeeeessssssssstttttttttttt</p>
<p>www</p>
</div>
</div>


-------css----------
#sidebar {
background: transparent;
color: #000000;
font: 12px Verdana, Arial, Helvetica, sans-serif;
font-weight: normal;
text-align: center;
width: 210px;
float: right;
margin: 0px 8px 0px 0px;
}
#sidetitle {
background-image: url('../images/Class_Pages/Cafeteria/title.jpg');
background-repeat: repeat-x;
border: 1px solid #840403;
width: 150px;
}
#sidenews {
background-color: #FFFFFF;
border: solid;
border-color: #A3A78E #840403 #840403;
border-width: 0px 1px 1px;
color: #000000;
margin: 0px auto;
}
#sidenews p{
background: transparent;
font: 10px Verdana, Arial, Helvetica, sans-serif;
width: 150px;
margin-top: 0;
padding-top: 0;
}
 
J

Jens Peter Karlsen [FP-MVP]

You haven't specified a width for sidenews so it just grows to
accomodate what you put in it.
Setting a width on <p> wont help when you enter text that can't be
kept within this width.

Regards Jens Peter Karlsen. Microsoft MVP - Frontpage.
 
M

Murray

In other words, this is fubar - it will not work. Even if it worked it
woudn't work! 8) By that I mean that all one would have to do to break such
an arrangement would be to increase the browser's text display size.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top