Closed (fixed)
Project:
User IP Log
Version:
7.x-1.x-dev
Component:
Code
Priority:
Normal
Category:
Feature request
Assigned:
Unassigned
Reporter:
Created:
31 Oct 2012 at 21:01 UTC
Updated:
25 Feb 2013 at 09:50 UTC
When a user registers but never logs in, no IP is registered. Adding the following code to uiplog.module fixes this.
function uiplog_user_insert(&$edit, $account, $category) {
global $user;
// Do not log an address when the user is created by someone else.
if ($user->uid != 0) {
return;
}
uiplog_user_login($edit, $account);
}
Comments
Comment #1
jvdurme commentedHi Jorrit,
do you have code to do this for the 6.x version?
Would really help me. I'm having spam trubbles..
Joost
Comment #2
jvdurme commentedIt's ok, I found it.
Changed:
if (($op == 'login') {to
if (($op == 'login') or ($op == 'insert')){Comment #3
Jorrit commentedGreat, I don't use this module on Drupal 6.
Comment #4
petednz commentedSounds like this module could be what we want to try out - if it has the above patch.
Is this patch going to be committed?
Our goal is to have the IP address of spammers as they register for an account.
Comment #5
sivaji_ganesh_jojodae commentedAdded this feature to both 6.x and 7.x branches, download the dev release to avail this feature.
Comment #6
Jorrit commentedThanks for committing. Are you planning on making a new release?