Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

Form Questions

Customizing output in email.


Reply

707 Views

Avatar
me.yay

26 February 2010 at 3:57am Community Member, 14 Posts

Hi Silverstripers,

i created my own contact form following the ssbits tutorial.

This is the ContactForm_method() from the page_Controller

new CheckboxSetField($name = "myField", $title = "myField Description", $source = array(
"Choise1" => "Choise1", "Choise2" => "Choise2", "Choise3" => "Choise3"))

The email-template is populated and $myField is available and shown in the emails that are send.

When i receive the email $myField is replaced with 'Array( "Choise1" => "Choise1", "Choise2" => "Choise2", "Choise3" => "Choise3")'

When i try to use a flat array ( Array("Choise1", "Choise2", "Choise3")) the first checkbox is allways preselected.

How can i change the output from $myField during population of the email template?
I need an output like: "choise1, choise2, choise3" without any php specific output like Array().

Kind regards
Metin