Page 1 of 1
Formbuilder - radiobuttons group list - Help
Posted: Fri Apr 23, 2010 6:27 pm
by mayo
Hi there.
I'm raally new in the smarty stuff and I desperately seeking for help with formbuilder e-mail template.
I have one radiobutton group $radios. How i can send values and names from this array to e-mail?
When i write {$radios} in template, it returns just comma separated values. I need radiobutton name and value.
Plz help.
Re: Formbuilder - radiobuttons group list - Help
Posted: Sat Apr 24, 2010 3:49 am
by Dr.CSS
When making form send email you need to run the "Make email Template" to generate the template that gets sent in email...
Re: Formbuilder - radiobuttons group list - Help
Posted: Sat Apr 24, 2010 11:43 am
by mayo
That is what I did. But checkbox group outputs just comma separated values. I need make something like list of names and values from that group called $radios.
name1 value1
name2 value2
name3 value3
But i don't know, how to list those names and values out from that checkbox group.
Re: Formbuilder - radiobuttons group list - Help
Posted: Sat Apr 24, 2010 4:34 pm
by Dr.CSS
Hitting the "make template" button will generate the necessary code needed to output the data from the radio buttons...
Re: Formbuilder - radiobuttons group list - Help
Posted: Sun Apr 25, 2010 8:55 am
by mayo
Thx.
But this automaticaly generated code output just values of checkboxes separaded by comma: value of checkbox1, value of checkbox2, value of checkbox... etc.
Exist some trick how to tweak this smarty teplate to output checkbox group in format like:
{name of check group}
{label of checkbox1}: {value of checkbox1}
{label of checkbox2}: {value of checkbox2}
{label of checkbox3}: {value of checkbox3}
{label of checkbox4}: {value of checkbox4}

Re: Formbuilder - radiobuttons group list - Help
Posted: Sun Apr 25, 2010 8:57 am
by Dr.CSS
Once it outputs all the values then you can tweak it to have ul li or whatever you want...
Re: Formbuilder - radiobuttons group list - Help
Posted: Sun Apr 25, 2010 12:43 pm
by mayo
Thx.
Exactly this is my problem. It outputs just values not the
labels. I need help with this part of code which is similar for the frontend html - where are checkoboxes and their labels rendered. Plz take a look on this url, where is the form:
http://joskopartner.lexmed.sk/pre-projektantov
It is slovak webpage, but you will see there part of form with checkboxes and their labels. And i need something similar in the e-mail, where checkoboxes are changed by the user checked values like X/- (checked / unchecked)
Mám záujem o:
Drevené, drevohliníkové okná, FixFrame X
Plastové okná -
Vstupné dvere -
Interiérové dvere X
Re: Formbuilder - radiobuttons group list - Help
Posted: Sun Apr 25, 2010 8:55 pm
by Dr.CSS
What does your email template look like when you tell it to generate it for you?...
Re: Formbuilder - radiobuttons group list - Help
Posted: Mon Apr 26, 2010 6:50 am
by mayo
Thx for your time Dr.CSS.
Here is my automaticaly generated e-mail template:
{if $fld_34 != "" && $fld_34 != "[unspecified]" }Oslovenie: {$fld_34}
{/if}
{if $reg_titul != "" && $reg_titul != "[unspecified]" }Titul: {$reg_titul}
{/if}
{if $reg_first_name != "" && $reg_first_name != "[unspecified]" }Meno: {$reg_first_name}
{/if}
{if $reg_second_name != "" && $reg_second_name != "[unspecified]" }Priezvisko: {$reg_second_name}
{/if}
{if $reg_company != "" && $reg_company != "[unspecified]" }Firma: {$reg_company}
{/if}
{if $reg_street != "" && $reg_street != "[unspecified]" }Ulica, číslo: {$reg_street}
{/if}
{if $reg_city != "" && $reg_city != "[unspecified]" }PSČ, obec: {$reg_city}
{/if}
{if $reg_country != "" && $reg_country != "[unspecified]" }Krajina: {$reg_country}
{/if}
{if $reg_phone != "" && $reg_phone != "[unspecified]" }Telefón: {$reg_phone}
{/if}
{if $reg_fax != "" && $reg_fax != "[unspecified]" }Fax: {$reg_fax}
{/if}
{if $reg_usersmail != "" && $reg_usersmail != "[unspecified]" }E-mail: {$reg_usersmail}
{/if}
{if $reg_interest != "" && $reg_interest != "[unspecified]" }Mám záujem o: {$reg_interest}
{/if}
{if $reg_message != "" && $reg_message != "[unspecified]" }Poznámka: {$reg_message}
{/if}
{if $reg_send != "" && $reg_send != "[unspecified]" }Send: {$reg_send}
{/if}
This bold part generates:
Mam zaujem o: yes/no,yes/no,yes/no,yes/no
and i want it to generate
Mam zaujem o:
Drevené, drevohliníkové okná, FixFrame - Yes/No
Plastové okná - Yes/No
Vstupné dvere - Yes/No
Interiérové dvere - Yes/No