Menu

IP ADDRESS CAPTURE ON SUBMIT

Help
interpolat
2007-10-12
2013-06-03
  • interpolat

    interpolat - 2007-10-12

    This is both a feature request and a temporary support request.  Could you please include a feature into the program to allow for the capturing of submitter's IP address, for the form sent by email.  Also, is there a temporary fix I can use to achieve this endpoint while you consider the feature request?

     
    • TNTEverett

      TNTEverett - 2007-10-13

      It's not much of a feature.  Simple PHP code can get the address, simple addition to form can store the data or just display it as a warning to visitors.

      $ip = GetHostByName($REMOTE_ADDR);
      echo $ip;

       
    • interpolat

      interpolat - 2007-10-13

      Thanks for the quick response.  I am not much of a php expert, so need a bit extra help.  So do I put the code in the form.html to display the IP? Also, how do I get the ip submitted along with the form?

       
    • interpolat

      interpolat - 2007-10-13

      I tried just copying the code into my form.html, and the code just shows up as is on the web front end, no IP address.  So, am obviously not doing this correctly.

       
    • interpolat

      interpolat - 2007-10-13

      Ok, got it to work with this code, " . $mail_message .= "Form Submitted by IP Address: ".$_SERVER['REMOTE_ADDR']."\n" . "    which I inserted in processor.php

       

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.