0

I'm unable to get webform submissions data into my default mail,but when submitting form i have received mail.getting below Body in my mail

Submitted on

Submitted by user:

Submitted values are:

The results of this submission may be viewed at:

Above name's comming from webform-mail.tpl.php file in webform module

<?php print ($email['html'] ? '<p>' : '') . t('Submitted on [submission:date:long]'). ($email['html'] ? '</p>' : ''); ?>

<?php if ($user->uid): ?>
<?php print ($email['html'] ? '<p>' : '') . t('Submitted by user: [submission:user]') . ($email['html'] ? '</p>' : ''); ?>
<?php else: ?>
<?php print ($email['html'] ? '<p>' : '') . t('Submitted by anonymous user: [submission:ip-address]') . ($email['html'] ? '</p>' : ''); ?>
<?php endif; ?>

<?php print ($email['html'] ? '<p>' : '') . t('Submitted values are') . ':' . ($email['html'] ? '</p>' : ''); ?>

[submission:values]

<?php print ($email['html'] ? '<p>' : '') . t('The results of this submission may be viewed at:') . ($email['html'] ? '</p>' : '') ?>

<?php print ($email['html'] ? '<p>' : ''); ?>[submission:url]<?php print ($email['html'] ? '</p>' : ''); ?>

Please help me I'm new to drupal

  • [submission:date:long] is a token. So keep it outside php code. – Gokul N K Jun 9 '15 at 12:18
  • Thanks @ Gokul N K I have keep [submission:date:long] to outside php code no luck . values not coming so how can i debug whether the values are coming or not? – Parvateesam Jun 9 '15 at 12:47
  • 1
    @GokulNK Its the default code of webfore template file. That is fine. – Sumit Madan Jun 9 '15 at 13:46
  • @Parvateesam Try to check your email settings under node/[nid]/webform/email. Also don't make any changes in module's template file. – Sumit Madan Jun 9 '15 at 13:46
  • I agree with @SumitMadan. Don't make updates to that modules file. If you want to custom the email AND want to do it from the template, clone that template into your theme/custom module and override it. – alex laughnan Jun 9 '15 at 15:41
1

I have disabled all dependent modules for token and then disabled token module also again enabled all modules now working fine.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.