Hello,
I was wondering if it is possible to add a specific css class to the form?
I'm using the plugin to call a form in an article.
The form code begins with :
<form id="chronoform_Book" class="Chronoform hasValidation" method="post" name="Book" action="http://myweb.fr/misc/send-us-inquiry.html?chronoform=Book&event=submit">
Is it possible to add in the class value another css class?
So the class value would be: class="Chronoform hasValidation mystyle"
Thanks for your help
I was wondering if it is possible to add a specific css class to the form?
I'm using the plugin to call a form in an article.
The form code begins with :
<form id="chronoform_Book" class="Chronoform hasValidation" method="post" name="Book" action="http://myweb.fr/misc/send-us-inquiry.html?chronoform=Book&event=submit">
Is it possible to add in the class value another css class?
So the class value would be: class="Chronoform hasValidation mystyle"
Thanks for your help
Not sure why you don't just apply whatever styles you wanted on the .myStyle to .Chronoform, or #chronoform_Book id if you don't want other form to be affected. Not really what you want, but it should do the job shouldn't it?
You're right, but I'm using a Yoo template which have a predefined style for forms, if you specify the correct css class.
I could change the stylesheet to add .chronoform to the yoo classes, but if theere was a way to add a css class to the chronoform forms, it will be much more easier🙂
I could change the stylesheet to add .chronoform to the yoo classes, but if theere was a way to add a css class to the chronoform forms, it will be much more easier🙂
Hi pmarty,
You could do it with JavaScript easily enough. There's no other easy way of adding a class to the <form> tag that I can think of :-(
Bob
You could do it with JavaScript easily enough. There's no other easy way of adding a class to the <form> tag that I can think of :-(
Bob
Ok Bob, Thanks you for this suggestion.
Maybe this possibility to add custom css class could be a new feature for the next release of Chronoform?😉
Maybe an option of the "Show html" action?
Thanks for all this job
Maybe this possibility to add custom css class could be a new feature for the next release of Chronoform?😉
Maybe an option of the "Show html" action?
Thanks for all this job
Helllo again,
In fact my last reply made me think to a possible way: modifiying the show html event myself.
So I opened the following file:
/administrator/components/com_chronoforms/form_actions/show_html/cfaction_show_html.php
And change the line 123 from:
to:
And it's perfect🙂 My form is now using "my_own_class" as css class.
So I really think, this could be defined as a parameter in the "show html" action:
"CSS class of the form:"
With a default value "Chronoform", that could be modified for user own use.
Hope it helps
Phil
In fact my last reply made me think to a possible way: modifiying the show html event myself.
So I opened the following file:
/administrator/components/com_chronoforms/form_actions/show_html/cfaction_show_html.php
And change the line 123 from:
$form_tag_array[] = 'class="Chronoform"';
to:
$form_tag_array[] = 'class="my_own_class"';
And it's perfect🙂 My form is now using "my_own_class" as css class.
So I really think, this could be defined as a parameter in the "show html" action:
"CSS class of the form:"
With a default value "Chronoform", that could be modified for user own use.
Hope it helps
Phil
Hi pmarty,
I've updated my Show HTML [GH] action to include an option to set a form Class attribute.
Bob
I've updated my Show HTML [GH] action to include an option to set a form Class attribute.
Bob
This topic is locked and no more replies can be posted.