Answer the question
In order to leave comments, you need to log in
Is it possible to transfer the IP of the user who sent the letter through the feedback form with the transfer of a letter from the site?
Good afternoon!
Making a site on Bitrix to order.
There is a feedback form. Made with JavaScript and jQuery library, Bitrix email templates are used. Used JS to keep spam out. Everything works, everything is ok. But then spam began to come to the client's mail. I don’t understand how, because JS is generated on the fly, and robots don’t see it.
Okay, that's one thing. Now the client wants to receive the sender's IP in the letter. The client's site is on the masterhost. Mail arrives via undeliverable.masterhost.ru
In the headers Received: from relay-out6.shared.masterhost.ru (relay-out6.shared.masterhost.ru. [90.156.200.38])
I understand that the sender's ip is not in the headers, which letter was clicked through the return form, and the mail server?
Or I'm wrong?
Is it possible to somehow implement on Bitrix so that the sender's IP address is picked up in the letter?
Answer the question
In order to leave comments, you need to log in
The IP of the user who called the script is stored in $_SERVER['REMOTE_ADDR'] ( php.net/manual/ru/reserved.variables.server.php)
In order to add IP to the letter, it must be added to the array of data transmitted to the mail event. You can hook on the "onBeforeEventAdd" event.
The question is still relevant. Does anyone know how to pull up the sender IP? Where to read it from?
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question