Help My good fellows please!

im trying to tidying up label elemts with css but it doesn’t work

1st Style.css label {
font-weight: label;
font-size: small;
color: blue;
} label. fixedwidth {
display: block;
width: 240;
float: left;

2nd contact.html <div>
<label for=“contactname” class=“fixedwidth”>Contact
<input type=“text” name=“contactname” id=“contactname”/>
<label for=“telephone” class=“fixedwidth”>Telephone
<input type=“text” name=“telephone” id=“telephone”/>
<label for=“email” class=“fixedwitdh”>Email Address</label>
<input type=“text” name=“email” id=“email”/>
<label for=“eventname” class=“fixedwidth”>What’s the event
<input type=“text” anme=“eventname” id=“eventname”/>
<label for=“eventdate” class=“fixedwidth”>When’s the event
<input type=“text” name=“eventdate” id=eventdate’/>

what did i do wrong in here?


  1. You’re missing an ‘f’ on the first line.
  2. I guess there shouldn’t be a space between ‘label.’ and ‘fixedwidth’

Where is the <form> tag?

This also doesn’t mean anything:

font-weight: label; 

You can have

font-weight: bold;


font-weight: normal;

You have loads of typos in both of the CSS examples. I assume you are now at [p 278] in which case: label.fixedwidth {
display: block;
width: 240px;
float: left;

Is what you should be writing.

As for the other part:
[FONT=Courier New] label {
font-weight: bold;
font-size: small;
color: blue;

[/FONT]Is what it asked you to write.

[FONT=Courier New]


ok im trying to put form button in my form but it won’t work for some reason.
here is my code .buttonarea {
text-align: center;
padding: 4px;
background-color: #0066ff;


is that ok?

im trying to create a special area for buttons. but it’s not working does any one know y? .buttonarea {
text-align: center;
padding: 4px;
background-color: 0066ff;

Without the associated HTML, there’s no way to check if that CSS is targeting the elements appropriately, so post that too. :slight_smile:

&lt;!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" 
&lt;html xmlns="". 
    &lt;title&gt;Contact Us at Bubble Under&lt;/title&gt; 
    &lt;meta http-equiv="Content-Type" 
        content=text/html; charset=utf-8"/&gt; 
  &lt;link href="style1.css" rel="stylesheet" type="text/css"/&gt;
  &lt;div id="header"&gt;
    &lt;div id="sitebranding"&gt;
    &lt;div id="tagline"&gt; 
      &lt;p&gt;Diving club for the south-west UK-let's make a 
  &lt;/div&gt; &lt;!--end of header div --&gt;
  &lt;div id="navigation"&gt; 
      &lt;li&gt;&lt;a href="index.html"&gt;Home&lt;/a&gt;&lt;/li&gt;
      &lt;li&gt;&lt;a href="about.html"&gt;About Us&lt;/a&gt;&lt;/li&gt;
      &lt;li&gt;&lt;a href="events`.html"&gt;Club Events&lt;/a&gt;&lt;/li&gt;
      &lt;li&gt;&lt;a href="contact.html"&gt;Contact Us&lt;/a&gt;&lt;/li&gt;
      &lt;li&gt;&lt;a href="gallery.html"&gt;Image Gallery&lt;/a&gt;&lt;/li&gt;
  &lt;/div&gt; &lt;!-- end of navigation div--&gt; 
  &lt;div id="bodycontent"&gt;
    &lt;h2&gt;Contact Us&lt;/h2&gt;
    &lt;p&gt;To let us know about a forthcoming dive event, please use
        the form below.&lt;/p&gt; 
    &lt;form action="" method="post" class="contact"&gt; 
        &lt;legend&gt;Tell us about a Dive Event&lt;/legend&gt; 
          &lt;label for="contactname" class="fixedwidth"&gt;Contact 
          &lt;input type="text" name="contactname" id="contactname"/&gt; 
          &lt;label for="telephone" class="fixedwidth"&gt;Telephone 
          &lt;input type="text" name="telephone" id="telephone"/&gt; 
          &lt;label for="email" class="fixedwidth"&gt;Email Address&lt;/label&gt; 
          &lt;input type="text" name="email" id="email"/&gt; 
          &lt;label for="eventname" class="fixedwidth"&gt;What's the event
          &lt;input type="text" anme="eventname" id="eventname"/&gt; 
          &lt;label for="eventdate" class="fixedwidth"&gt;When's the event 
          &lt;input type="text" name="eventdate" id=eventdate'/&gt; 
         &lt;label for="region" class="fixedwidth"&gt; What region is the event 
         &lt;select name="region" id="region"&gt; 
           &lt;option&gt;Northern Ireland&lt;/option&gt; 
           &lt;option&gt;International (see details below)&lt;/option&gt; 
      &lt;p&gt;Please provide any other details you think will be useful to 
          us in the text area below (it may save us calling or 
          emailing you, and help avoid delays).&lt;/p&gt; 
      &lt;label for="details class="fixedwidth"&gt;More details (as much as 
          you think we'll need!)&lt;/label&gt; 
      &lt;textarea id="details" name="details" cols="30" 
      &lt;p&gt;If we need to call you back gor any more info, what would be
          the best time to call you on number supplied?&lt;/p&gt; 
      &lt;input type="radio" name="timetocall" id="morning" 
      &lt;label for="morning"&gt;In the morning&lt;/label&gt; 
      &lt;input type="radio" name="timetocall" id="afternoon" 
      &lt;label for="afternoon"&gt;In the afternoon&lt;/label&gt; 

      &lt;input type="radio" name="timetocall" id="evening" 
      &lt;label for="evening"&gt; In the evening&lt;/label&gt;

      &lt;input type="radio" name="timetocall" id="never" value="never" 
      &lt;label for="never"&gt; No calls please&lt;/label&gt; 
      &lt;p&gt;Bubble Under may share information you give us here with 
          other like-minded people or web sites to promote the event. 
          Please confrim if you are happy for us to do this.&lt;/p&gt; 
      &lt;input type="checkbox" name="publicize" id="publicize" 
      &lt;label for="publicize"&gt;I am happy for this event to be 
          publicized outside of and beyond, where 
    &lt;p&gt;If you need to get in touch urgently, please call Bob 
        Dobalina on 01793 641207. For anything else, please &lt;a 
        href=""&gt;drop us a line by 
      &lt;p&gt;Please provide any other details you think will be useful to 
          us in the text area below (it may save us calling or 
          emailing you, and help avoid delays).&lt;/p&gt; 
    &lt;/div&gt; &lt;!-- end of bodycontent div --&gt;

this is the html for contact. thank you for helping

There’s no class=“buttonarea” in your HTML, so the styles you posted in your first post can’t apply to anything. What element(s) did you want it to apply to?

You styles are saying:

Look for a form element with a class of “contact”, and inside that form find elements with the class “buttonarea”, and apply these styles to them.

Also, make sure to fix this line at the top of your HTML:

<html xmlns="". 

It shouldn’t have a period at the end:

<html xmlns="" lang="en" xml:lang="en">

I assume you are talking about [p288] and if so then that CSS is correct but you might have a typo somewhere else in the CSS or XHTML.

[note: two threads merged, as they both ask the same question. :slight_smile: ]

Yes, the merge confused me but the following should go just before the closing fieldset, i.e. </fieldset>

<div class="buttonarea">
  <input type="submit" value="Send Us the Info" />

You also have some other typos within the markup like LU instead of UL.

Plus some missing quotes for example: id=eventdate’ should be: id=“eventdate” and <label for="details class=“fixedwidth”> should be: <label for=“details” class=“fixedwidth”> so they’ll need fixing too.