Thanks einsteinsboi for the reply. I am a bit of a n00b and have trouble to explain my question, sorry about that.
First of all let me make clear that the form is working, I just would like to put it all together inside a border, maybe add a background color too. But I am looking for the easiest way to do this, I just don’t have too much time to futzz around with the code. As a non-tech person, its very hard and really time consuming to get into some project like this. Hope that doesn’t come across wrong, I like working on the code but its just tough to do for me.
Anyway, let me show you what I am trying to understand:
Here is the first chunk of the form:
[+validationmessage+]
<form method="post" action="[~[*id*]~]">
<input type="hidden" name="formid" value="feedbackForm" />
<p><label accesskey="n" for="Name">Your Name</label>
<input type="text" name="Name" maxlength="60" eform="Your Name:Name:0" /></p>
<p><label accesskey="e" for="email">Your Email Address</label>
<input type="text" name="email" size="40" maxlength="40" eform="Your Email Address:email:1" /></p>
<p><label accesskey="s" for="department">Subject</label>
<select name="department">
<option value="1">Website feedback</option>
<option value="2">Support request</option>
<option value="3">Feature request</option>
</select></p>
<p><label accesskey="c" for="comments">Comments</label>
<textarea cols="40" rows="10" name="comments" eform="Comments:html:1"></textarea></p>
<p><input type="submit" name="submit" value="Send Feedback"></p>
</form>
So, I got a form there, which makes me think that I
should be able to style that form using code in the css like this:
form {
border: 1px solid #666699;
padding: 5px;
}
But it doesn’t seem to work.
I know I can’t use fieldset because there is no fieldset defined in the chunk. I also know that I can alter the chunk of the form to define some variables that I can then style. But I am trying to avoid that if possible.
So, my question is, when we have a defined form in the chunk, even though that form has no name in there, why can’t my styling of the form work?
Hope that explains it better, and thanks in advance for any advice!
Quote from: einsteinsboi at Feb 14, 2011, 04:12 AM
When you use eform you create a chunk with the html code specifying the fields and other elements of your form. You can add any classes or layout elements you want to that form, including fieldsets, and then style those in your css. Not sure what you mean by Form{}?
RTFM - an example of a simple contact form chunk: http://rtfm.modx.com/display/ADDON/eForm