Forums

How to uppercase a text field

fgrasso 03 Jun, 2013
Hi,
i have a form that works fine.

Now i need to send a mail with some fields transformed in UPPERCASE ?

Attached my events panel

Please note im a very unskilled programmer...😟

thansk for help
Fabio
marcinwolejko 07 Jun, 2013
In your email template try adding this insinde the <td></td>
<font style="text-transform: uppercase;">{your field}</font> 



I'm not sure if this will work though...
GreyHead 07 Jun, 2013
1 Likes
Hi Fabio,

You could also use a Custom code action to process the results after the form is submitted:
<?php
$inputs = array(
  'input_name_a',
  'input_name_b',
  'input_name_c'
);
foreach ( $inputs as $v ) {
  if ( isset($form->data[$v]) && $form->data[$v] ) {
    $form->data[$v] = strtoupper($form->data[$v]);
  } else {
    $form->data[$v] = '';
  }
}
?>

Bob
This topic is locked and no more replies can be posted.