hello i use an old chronoform i know but i can't change
is it possible to add php code in email template to change some information on fly ?
regards
is it possible to add php code in email template to change some information on fly ?
regards
Hi micker,You can use PHP in a Custom PHP action before the Email action to build custom for data that you can
then include in the email.
Bob
then include in the email.
Bob
cool did you have a small tuto or documentation about this ?
for now i have a field {extensions}
and i want to create some small php check to return good result in email ?
regards
for now i have a field {extensions}
and i want to create some small php check to return good result in email ?
regards
hi
i have field (checkbox)
{extensions}
in email its return some arrays with value
i want to convert some value in readable value for recipeir like
i hope its more clear
i have field (checkbox)
{extensions}
in email its return some arrays with value
i want to convert some value in readable value for recipeir like
$myvlaue = data in extension field;etc ....
if (!empty ($myvlaue){
if ($myvlaue == 1);
echo = 'My texte dljflmsdgjdmfgjmlfgj in body email';
} elseif ($myvlaue == 2){
echo = 'My texte 2 dljflmsdgjdmfgjmlfgj in body email';
}
i hope its more clear
Hi micker,
Please check the CFv5 manual if you have a copy - I think the answer is there.
You can use Custom PHP something like this:
Bob
Please check the CFv5 manual if you have a copy - I think the answer is there.
You can use Custom PHP something like this:
<?phpThen the value of mytext will be added to the form data and can be used in your email.
if ( !empty ($form-data['myvalue']) ) {
if ( $form-data['myvalue'] == 1 ) {
$form->data['mytext'] = 'My texte dljflmsdgjdmfgjmlfgj in body email';
. . .
?>
Bob
ok just to be sure
1 i create a custom code block
2 drag and drop in on submit event
and my code ?
exemple
<?php
if ( !empty ($form-data['extensions']) ) {
$form->data['extensions'] = $form->data['extensions'];
}else {
$form->data['extensions']="pas d'extensions";
}
?>
my user want a value in his email if $form-data['extensions'] is empty
1 i create a custom code block
2 drag and drop in on submit event
and my code ?
exemple
<?php
if ( !empty ($form-data['extensions']) ) {
$form->data['extensions'] = $form->data['extensions'];
}else {
$form->data['extensions']="pas d'extensions";
}
?>
my user want a value in his email if $form-data['extensions'] is empty
You need to login to be able to post a reply.