CarolW
11-21-2005, 02:44 PM
I just realized the forms on my site are a bit crude (to say the least!) I learn slowly (but much faster with help from here!)
So - I'm just adding a Quick Survey on one of my pages. I have some CSS for the entire form (see code examples below), but not for the varied content of the form.
So, for now, for this particular code, what I'd like to do is assign probably a class for:
radio button input fields (I'll leave checkbox fields for later)
textarea field
I don't know if I'll need a special class for the headings or paragraphs contained in the form.
Here's the HTML code for the form I want to format:
<div class="feedput">
<form method="post" action="/cgi-bin/mailit">
<!-- Validator requires a div here -->
<!-- and also closing of tags -->
<div class="questions">
<input type="hidden" name="login" value="cwhitney" />
<!-- next line returns visitor to original page following survey fill-out -->
<input type="hidden" name="reply" value="thanks11.htm" />
<input type="hidden" name="date" id="date" value="<!--#echo var='DATE_LOCAL' -->" />
<input type="hidden" name="date" value="date" />
<input type="hidden" name="file" value="quicksurvey1" />
<input type="hidden" name="format" value="human" />
<input type="hidden" name="fields" value="date message" />
<!-- end questions div here; it seems no longer needed by Validator after this -->
</div>
<div id="surveyquest">
<h3 id="survey">Quick Survey</h3>
<h4>Where are you from?</h4>
<div id="radio1">
<p>East</p>
<p><input type="radio" name="where" value="East" checked="checked" /></p>
<p>West</p>
<p><input type="radio" name="where" value="West" /></p>
<p>South</p>
<p><input type="radio" name="where" value="South" /></p>
<p>North</p>
<p><input type="radio" name="where" value="North" /></p>
</div>
<h4>Do you have a dog?</h4>
<div id="radio2">
<p>Yes, I have one or more.</p>
<p><input type="radio" name="havedog" value="Yes" checked="checked" /></p>
<p>No; I don't have any dogs.</p>
<p><input type="radio" name="havedog" value="No" /></p>
</div>
<h4>You may leave a comment if you like</h4>
<p><textarea name="message" rows="4" cols="40">Comment here</textarea></p>
<p><input type="submit" value="Reply to survey" /></p>
<p><strong>or</strong></p>
<p><input type="reset" value="Quit" /></p>
</div>
</form>
<!-- close feedput div here -->
</div>
(I'm not sure I need all those divs, and might take some out; I put in the "radio1" and "radio2" divs when I coudn't get the "checked" value to work, but Robert Wellock helped me sort that one out! - but maybe I will need them to assign a class for the CSS).
The only CSS I have that affects this form and the others on my site (about three or four others) is as follows:
CSS code
.feedput {
font-family: Verdana,Geneva,Arial,Helvetica,sans-serif;
font-size: 100%;
margin: 1em;
padding: 2em;
text-align: left;
}
.feedbutton {
margin: 1em;
padding: 2em;
font-family: Verdana,Geneva,Arial,Helvetica,sans-serif;
font-weight: normal;
font-size: 100%;
text-align: center;
}
Can anybody make suggestions about how I might format the two sets of radio-buttons, and also, maybe, if need be, the textarea part? The textarea boxes all seem to look fine anyway, but the headings and the paragraphs of text that label the boxes are a bit sloppy.
One example of what Im talking about is at:
http://www.coherentdog.org/comments.htm
Thanks!
Mon, 21 Nov 2005 11:39:23
So - I'm just adding a Quick Survey on one of my pages. I have some CSS for the entire form (see code examples below), but not for the varied content of the form.
So, for now, for this particular code, what I'd like to do is assign probably a class for:
radio button input fields (I'll leave checkbox fields for later)
textarea field
I don't know if I'll need a special class for the headings or paragraphs contained in the form.
Here's the HTML code for the form I want to format:
<div class="feedput">
<form method="post" action="/cgi-bin/mailit">
<!-- Validator requires a div here -->
<!-- and also closing of tags -->
<div class="questions">
<input type="hidden" name="login" value="cwhitney" />
<!-- next line returns visitor to original page following survey fill-out -->
<input type="hidden" name="reply" value="thanks11.htm" />
<input type="hidden" name="date" id="date" value="<!--#echo var='DATE_LOCAL' -->" />
<input type="hidden" name="date" value="date" />
<input type="hidden" name="file" value="quicksurvey1" />
<input type="hidden" name="format" value="human" />
<input type="hidden" name="fields" value="date message" />
<!-- end questions div here; it seems no longer needed by Validator after this -->
</div>
<div id="surveyquest">
<h3 id="survey">Quick Survey</h3>
<h4>Where are you from?</h4>
<div id="radio1">
<p>East</p>
<p><input type="radio" name="where" value="East" checked="checked" /></p>
<p>West</p>
<p><input type="radio" name="where" value="West" /></p>
<p>South</p>
<p><input type="radio" name="where" value="South" /></p>
<p>North</p>
<p><input type="radio" name="where" value="North" /></p>
</div>
<h4>Do you have a dog?</h4>
<div id="radio2">
<p>Yes, I have one or more.</p>
<p><input type="radio" name="havedog" value="Yes" checked="checked" /></p>
<p>No; I don't have any dogs.</p>
<p><input type="radio" name="havedog" value="No" /></p>
</div>
<h4>You may leave a comment if you like</h4>
<p><textarea name="message" rows="4" cols="40">Comment here</textarea></p>
<p><input type="submit" value="Reply to survey" /></p>
<p><strong>or</strong></p>
<p><input type="reset" value="Quit" /></p>
</div>
</form>
<!-- close feedput div here -->
</div>
(I'm not sure I need all those divs, and might take some out; I put in the "radio1" and "radio2" divs when I coudn't get the "checked" value to work, but Robert Wellock helped me sort that one out! - but maybe I will need them to assign a class for the CSS).
The only CSS I have that affects this form and the others on my site (about three or four others) is as follows:
CSS code
.feedput {
font-family: Verdana,Geneva,Arial,Helvetica,sans-serif;
font-size: 100%;
margin: 1em;
padding: 2em;
text-align: left;
}
.feedbutton {
margin: 1em;
padding: 2em;
font-family: Verdana,Geneva,Arial,Helvetica,sans-serif;
font-weight: normal;
font-size: 100%;
text-align: center;
}
Can anybody make suggestions about how I might format the two sets of radio-buttons, and also, maybe, if need be, the textarea part? The textarea boxes all seem to look fine anyway, but the headings and the paragraphs of text that label the boxes are a bit sloppy.
One example of what Im talking about is at:
http://www.coherentdog.org/comments.htm
Thanks!
Mon, 21 Nov 2005 11:39:23