Arrow Home arrow Forums
larger font smaller font default font Fixed screen resolution Auto adjust screen size

Advertise on this site

Joomlapolis Forums  


<< Start < Prev 1 2 3 4 5 6 7 8 Next > End >>
Re:IP Address...
Date: 2006/06/16 03:00 By: silexian Status: User  
Karma: -2023  
Senior Joomlapolitan

Posts: 93
graphgraph
i did not get that warning due to my ERROR_REPORTING level (set to NONE)...

Well, i'm trying to debug.

First, on line 24
Code:

 "SELECT DISTINCT userip FROM jos_comprofiler_plug_iplog WHERE userid='62' ORDER BY logdate ASC  LIMIT 0, 3"



i don't think the userid is a varchar, so the ' are useless ?

Then there's a bug line 129
Code:

         # Detect users IP - unless is admin and no admin log settings enabled         if (!$iplogNoAdminLog AND $admin) { } else { $this->detectUserIp($user$iplogDetect$iplogLogIp); }



$admin does not exist. $is_admin, yes.

Then
Code:

 $is_admin = (strtolower($my->usertype) == 'administrator' || strtolower($my->usertype) == 'super administrator');


correct it to (better)
Code:

 $is_admin = (strtolower($my->usertype) == 'administrator') || (strtolower($my->usertype) == 'super administrator');



Then, i never verify
Code:

 if ($iplogDetect=="0" AND $my->id==$user) { // Visiting own profile only!

and
Code:

 else if ($iplogDetect=="1"«») { // Visiting any profile!



with my config

Then, modify
Code:

 if ($iplogDetect=="0" AND $my->id==$user) { // Visiting own profile only!

with
Code:

 if (($iplogDetect=="0"«») AND ($my->id==$user)) { // Visiting own profile only!


it's better to set explicit priorities

Then i did not get that warning due to my ERROR_REPORTING level (set to NONE)...

Well, i'm trying to debug.

First, on line 24
Code:

 "SELECT DISTINCT userip FROM jos_comprofiler_plug_iplog WHERE userid='62' ORDER BY logdate ASC  LIMIT 0, 3"



i don't think the userid is a varchar, so the ' are useless ?

Then there's a bug line 129
Code:

         # Detect users IP - unless is admin and no admin log settings enabled         if (!$iplogNoAdminLog AND $admin) { } else { $this->detectUserIp($user$iplogDetect$iplogLogIp); }



$admin does not exist. $is_admin, yes.

Then
Code:

 $is_admin = (strtolower($my->usertype) == 'administrator' || strtolower($my->usertype) == 'super administrator');


correct it to (better)
Code:

 $is_admin = (strtolower($my->usertype) == 'administrator') || (strtolower($my->usertype) == 'super administrator');



Then, i never verify
Code:

 if ($iplogDetect=="0" AND $my->id==$user) { // Visiting own profile only!

and
Code:

 else if ($iplogDetect=="1"«») { // Visiting any profile!



with my config

Then, $user in
Code:

 if (($iplogDetect=="0"«») AND ($my->id==$user)) { // Visiting own profile only!

is an object and not a value

Then $user in
Code:

 if (($iplogDetect=="0"«») AND ($my->id==$user)) { // Visiting own profile only!

is incorrect. Must be
Code:

 if (($iplogDetect=="0"«») AND ($my->id==$user->id)) { // Visiting own profile only!



Post edited by: silexian, at: 2006/06/15 21:30

Okay ... I made some modification ...
and now, with my config, it works !

Post edited by: silexian, at: 2006/06/15 21:43
help me decrease my Karma ! i AM a bad boy Hurry up or i'm gonna eat your soul
Click here to see the profile of this user The topic has been locked.

Re:IP Address...
Date: 2006/06/16 03:44 By: silexian Status: User  
Karma: -2023  
Senior Joomlapolitan

Posts: 93
graphgraph
Here is the file that works ...

File Attachment:
File name: iplog_ok.zip
File size:2298 bytes

help me decrease my Karma ! i AM a bad boy Hurry up or i'm gonna eat your soul
Click here to see the profile of this user The topic has been locked.

Re:IP Address...
Date: 2006/06/18 20:12 By: Kampp Status: CB Doc subscriber  
Karma: 6  
Senior Joomlapolitan

Posts: 70
graphgraph
Here is a new compilation that fixes the install/uninstall bug and some of the the suggestions from silexian.

This will also be added to the CB download archive - if I just knew how to do so!!!!

Cheers, Kampp

File Attachment:
File name: cb_iplog-f9c5ce551419f3c322c9e58fe1a3eae6.zip
File size:5280 bytes


Post edited by: Kampp, at: 2006/06/18 14:17
Creator of the CB plugins: "User IP log" and "Public Mail"
Joomla! services/coding: http://www.toolmaster.dk
Click here to see the profile of this user The topic has been locked.

Re:IP Address...
Date: 2006/06/20 08:05 By: joomladude Status: User  
Karma: -3  
Senior Joomlapolitan

Posts: 74
graphgraph
Good job bro. You are THA BEST!
Click here to see the profile of this user The topic has been locked.

Re:IP Address...
Date: 2006/06/20 19:25 By: silexian Status: User  
Karma: -2023  
Senior Joomlapolitan

Posts: 93
graphgraph
Hi Kampp

there's 1 difference between the file iplog.php, (mine & yours)

mine is

Code:

 if (($iplogDetect=="0"«») AND ($my->id==$user<span style="color: #FF0000">->id</span>)) { // Visiting own profile only!



and yours is

Code:

 if (($iplogDetect=="0"«») AND ($my->id==$user)) { // Visiting own profile only!



if i remember, $user is an object. But, i don't have time to verify it. May you confirm or infirm that ?

Silexian
help me decrease my Karma ! i AM a bad boy Hurry up or i'm gonna eat your soul
Click here to see the profile of this user The topic has been locked.

Re:IP Address...
Date: 2006/07/25 20:55 By: Kampp Status: CB Doc subscriber  
Karma: 6  
Senior Joomlapolitan

Posts: 70
graphgraph
The plugin is now available in the download section!
Creator of the CB plugins: "User IP log" and "Public Mail"
Joomla! services/coding: http://www.toolmaster.dk
Click here to see the profile of this user The topic has been locked.

<< Start < Prev 1 2 3 4 5 6 7 8 Next > End >>

Documentation

Documentation Subscription Service
(updated for CB 1.2 RC2)

What?

Why?

Where?

Just click here for answers!

Click here for a yearly subscription: subscribe now

Download Latest Release

The latest stable Community Builder Release is version 1.1 for Joomla 1.0 and Mambo.
You need to be a registered member of Joomlapolis to download.

The latest release candidate of Community Builder is version 1.2 RC2, native for Joomla 1.0, 1.5 and Mambo.
It is available as "thank you" to all CB documentation subscribers at this time.

CB Login