How to add submitter IP address into email subject

gacux 27 Mar, 2013
Looks like {IPADDRESS} nor in "subject field" nor in "template" is the answer. Meanwhile "Get Submitter's IP" is working correctly. "Replace Nulls" is set to "Yes". I can't find the way.
GreyHead 28 Mar, 2013
Hi gacux,

ChronoForms doesn't look up the IP address until the EMail is sent so you have to do that yourself in a Custom Code action, you can then add it to a form variable to include in the subject.

Please see this FAQ for info on building a custom Subject.

Bob
gacux 28 Mar, 2013
Hello Bob,

thank you for the tip. Problem was solved with this simple code


<?php
$form->data['subject'] = "{$_SERVER['REMOTE_ADDR']}";
?>


I'm new here and in programming overall. I have payed too much attention to the {IPADDRESS} variable. Hope this will help for some rookie like me in the future.
chevron08 19 Sep, 2013
hi,
is it possible to add the subject "Contenttitle" into the Email?

So i can use one form in multi sites.

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