-
AuthorPosts
-
August 13, 2013 at 12:25 pm #27694
How do I modify the default rows number for the contact form message box? Since it’s not at the .css, w/o touching the PHP.
From the dafault, to:
<textarea name=”avia_message_1″ class=”text_area is_empty” cols=”40″ rows=”3″ id=”avia_message_1″ style=”background-image: none; background-position: 0% 0%; background-repeat: repeat repeat;”></textarea>
Found this https://kriesi.at/support/topic/contact-form-make-input-fields-thinner and it works like a charm but not the solution for the height of the message text-field.
August 13, 2013 at 7:24 pm #135016Hi,
You can change specify the minimum height of the contact form fields:
#top .ajax_form .text_input, #top .ajax_form .select, #top .ajax_form .text_area {
min-height: 100px;
}You can find the css style of the form on css > base.css > #Forms.
Regards,
Ismael
August 13, 2013 at 8:33 pm #135017Thanks Ismael,
This I have tried before asking here, it doesn’t work for this, It’s a minimal height, but it’s not the actual default height(num of rows).
What I need is the default rows of the message area to be 2 or 3 or whatever.
class=”text_area is_empty” cols=”40″ rows=”3″ – as I see it’s “inlined” how to w/o touching PHP file, may be some !important, or something?
August 13, 2013 at 11:55 pm #135018Hi,
Edit framework > php > class-form-generator.php, find this code on line 434:
$this->elements_html .= ' <textarea name="'.$id.'" class="text_area '.$element_class.'" cols="40" rows="7" id="'.$id.'" >'.$value.'</textarea>';
Change rows to 2 or 3.
Regards,
Ismael
August 14, 2013 at 3:27 pm #135019It’s exactly what I need! but. This way I modify the theme php file and it becomes non-updateable, or I need to remember all the changes I made to the files.
What is the way to do this on child-theme?
August 16, 2013 at 3:18 am #135020Hi vadi4ek,
This isn’t really something you can add to a child theme easily as if you do, it means you won’t actually be updating the framework file in which in turn causes big problems when the framework is updated.
So for this, you’ll need to keep a changelog.txt of your own and just put a link to this topic, the file name and location you changed and the line of code you modified.
Regards,
Devin
-
AuthorPosts
- The topic ‘CSS for Contact Form’ is closed to new replies.