Page Index Toggle Pages: [1] 2  Send TopicPrint
Hot Topic (More than 10 Replies) Link IP Mod V1.2 for YaBB 2.5 (Read 658 times)
Derek Barnstorm
God Member
*****
Offline



Posts: 1146
Location: Warwickshire
Joined: Mar 23rd, 2008
Gender: Male
Link IP Mod V1.2 for YaBB 2.5
Nov 3rd, 2010 at 10:00pm
Print Post  
Link IP Mod V1.2

Description:
-----------------
This Mod will link IP Addresses (wherever they are displayed) to a regional Whois server.

Credits:
-----------
This Mod was originally coded by Mongo (Brian Longo) for YaBB 2.0/1. Thanks to him for giving me permission to update it. [Link to Original Mod]

Thanks to pyragony for the German and German_Du translations.

Changes in this version:
-------------------------------
I've made some changes to this version, so it's slightly different to the 2.4 update.

I didn't really see any reason to have a separate setting for every place that IP's were displayed, so now there is just the one setting to enable/disable.

I also didn't see any reason to require a separate settings file each time it was needed, so I've moved the settings to 'Admin Center => Forum Settings => Staff'.

I've also removed three of the whois sites (domaintools, ip-adress and geobytes) - these sites used the main RIPE network anyway. So now there are just the five main regional whois servers:

AfriNIC.net
APNIC.net
ARIN.net
LACNIC.net
RIPE.net

I hope these changes are okay with everyone...

Screenshots:
----------------
Admin Center - Forum Settings - Staff:


Modify Profile - Admin Edits:


Installation:
---------------
1) Modify YaBB files using BoardMod or manually.
2) Upload modified files to your server in ASCII mode.
3) Go into Admin Center => Forum Settings => Staff to configure the settings.

Files to edit:
----------------
Admin/Admin.pl
Admin/ErrorLog.pl
Admin/ModList.pl
Admin/NewSettings.pl
Admin/RegistrationLog.pl
Admin/Settings_Main.pl
Languages/English/Admin.lng
Languages/English/Profile.lng
Sources/BoardIndex.pl
Sources/Display.pl
Sources/InstantMessage.pl
Sources/Poll.pl
Sources/Profile.pl

Zip package:
----------------
Link_IP_V1_2.mod
Link_IP_V1_2_For_YaMMS.mod
Link_IP_V1_2_German.mod
Link_IP_V1_2_German_Du.mod

History:
----------
1.0 - Upadted for YaBB 2.4 by Derek Barnstorm - 4th December 2009
1.1 - Added to Instant Messages, Registation Log and Admin Edits - 7th December 2009
1.1a - Added to View Poll Votes - 7th December 2009
1.2 - Upadted for YaBB 2.5 and moved settings to Admin Center => Staff - 3rd November 2010

### YaBB 2.0/1 ###
1.0 - 1.2 - Original Mod by Brian Longo
« Last Edit: Mar 6th, 2011 at 12:20am by Derek Barnstorm »  

Link_IP_V_1_2.zip ( 8 KB | Downloads )
Back to top
 
IP Logged
 
pyragony
Junior Member
**
Offline


abgeschlafft und ausgebufft

Posts: 85
Location: Eichenau
Joined: Apr 26th, 2008
Gender: Male
Re: Link IP Mod V1.2 for YaBB 2.5
Reply #1 - Feb 28th, 2011 at 4:19pm
Print Post  
Don´t works whith yamms.
Error in the last Line (Profil.pl)   Cry
  

Back to top
WWW  
IP Logged
 
Derek Barnstorm
God Member
*****
Offline



Posts: 1146
Location: Warwickshire
Joined: Mar 23rd, 2008
Gender: Male
Re: Link IP Mod V1.2 for YaBB 2.5
Reply #2 - Mar 1st, 2011 at 4:01am
Print Post  
It's because YaMMS links the IP's on the profile page to the member list - the easiest thing to do is to just remove that last step from the mod file before you install it and they'll work fine together then...
  
Back to top
 
IP Logged
 
pyragony
Junior Member
**
Offline


abgeschlafft und ausgebufft

Posts: 85
Location: Eichenau
Joined: Apr 26th, 2008
Gender: Male
Re: Link IP Mod V1.2 for YaBB 2.5
Reply #3 - Mar 1st, 2011 at 1:22pm
Print Post  
Smiley

Here the German-Files:

Code
Select All
<edit file>
Languages/German/Admin.lng
</edit file>

<search for>
);

%floodtxt=(
</search for>

<add before>
'linkip_1' => 'IP-Adressen mit einem regionalen Whois-Server verlinken?',
'linkip_2' => 'Wählen sie den regionalen Wois-Server, mit dem die IP-Adressen verlinkt werden:',
</add before>

<edit file>
Languages/German/Profile.lng
</edit file>

<search for>
);

%mycenter_profile_txt = (
</search for>

<add before>
'linkip_1' => '\'s neueste IP-Adressen',
'linkip_2' => 'nachsehen',
'linkip_3' => '\'s neueste IP-Adresse auf einem regionalen Whois-Server',
</add before> 




Code
Select All
<edit file>
Languages/German_Du/Admin.lng
</edit file>

<search for>
);

%floodtxt=(
</search for>

<add before>
'linkip_1' => 'IP-Adressen mit einem regionalen Whois-Server verlinken?',
'linkip_2' => 'Wähle den regionalen Wois-Server, mit dem die IP-Adressen verlinkt werden:',
</add before>

<edit file>
Languages/German_Du/Profile.lng
</edit file>

<search for>
);

%mycenter_profile_txt = (
</search for>

<add before>
'linkip_1' => '\'s neueste IP-Adressen',
'linkip_2' => 'nachsehen',
'linkip_3' => '\'s neueste IP-Adresse auf einem regionalen Whois-Server',
</add before> 



Spoiler and OffToppic i was able to fully customize.
  

Back to top
WWW  
IP Logged
 
Derek Barnstorm
God Member
*****
Offline



Posts: 1146
Location: Warwickshire
Joined: Mar 23rd, 2008
Gender: Male
Re: Link IP Mod V1.2 for YaBB 2.5
Reply #4 - Mar 1st, 2011 at 9:22pm
Print Post  
Thanks pyragony. I'll add them to the package next time I have to attach the package again.

pyragony wrote on Mar 1st, 2011 at 1:22pm:
Spoiler and OffToppic i was able to fully customize.

Great!
  
Back to top
 
IP Logged
 
Derek Barnstorm
God Member
*****
Offline



Posts: 1146
Location: Warwickshire
Joined: Mar 23rd, 2008
Gender: Male
Re: Link IP Mod V1.2 for YaBB 2.5
Reply #5 - Mar 6th, 2011 at 12:16am
Print Post  
I've added the German and German_Du language patches (thanks again pyragony) and a YaMMS compatible mod file to package now. New zip attached to the first post.
  
Back to top
 
IP Logged
 
DylanBubi
New Member
*
Offline


I Love YaBB 2!

Posts: 4
Joined: Jul 16th, 2011
Re: Link IP Mod V1.2 for YaBB 2.5
Reply #6 - Jul 16th, 2011 at 6:51am
Print Post  
thanks!
  
Back to top
 
IP Logged
 
BloodyRue
New Member
*
Offline


The Sea Organization will
rot your brain.

Posts: 31
Location: Martha's Vineyard
Joined: Oct 9th, 2011
Gender: Male
Re: Link IP Mod V1.2 for YaBB 2.5
Reply #7 - Nov 23rd, 2011 at 8:28am
Print Post  
Made some adjustments:
Pardon my code quoting, i don't know how to format it properly in here.

Arin wasn't working with your setting so I changed it to:
settings_main.pl:
Code
Select All
$arin    = "http://whois.arin.net/rest/nets;q="; 



I added a tail info piece that works with arin but needs to be blank for the others, I made an admin config for it as $tailinfo but its not what  I would call ready for anyone else though, but here is what variable I set it to:

settings_main.pl:
Code
Select All
$arintail ="?showDetails=true&showARIN=false&ext=netref2"; 



my config changes that to $tailinfo, you can do it neater than I, I am sure.

Mainly, I was working on this to get online activity mod to use the links.

Find this in OnlineActivity.pl:
Code
Select All
			if($tkey == 2) {
				if(!$botactivity) { next; }
				$key =~ s~bot_(.+?)(\d{3})~$1~;
				$theuser = qq~<b>$key</b>~;
				if($iamadmin) {
					$theuser .= qq~ ($theip)~;
				}
			}
			elsif($tkey == 3) {
				if(!$guestactivity) { next; }
				$theuser = qq~<b>$memberson_txt{'3'}</b>~;
				$isguest = 1;
				if($iamadmin) {
					$theuser .= qq~ ($theip)~;
				}
			}
			else {
				&LoadUser($key);
				if(!$iamadmin && !$iamgmod && ${$uid.$key}{'stealth'}) { next; }
				$theuser = $format{$key} . (${$uid.$key}{'stealth'} ? "*" : "");
				if($iamadmin) {
					$theuser .= qq~ ($theip)~;
				}
			}
 



and change it to this:
Code
Select All
	### Link IP Mod Start ###
	    if ($link_ip && $theip) { $iplink = qq~<a href="$link_ip_region$theip$tailinfo" target="_blank">$theip</a>~; }
	    else { $iplink = $theip; }
	### Link IP Mod End ###
			if($tkey == 2) {
				if(!$botactivity) { next; }
				$key =~ s~bot_(.+?)(\d{3})~$1~;
				$theuser = qq~<b>$key</b>~;
				if($iamadmin) {
					$theuser .= qq~ ($iplink)~;
				}
			}
			elsif($tkey == 3) {
				if(!$guestactivity) { next; }
				$theuser = qq~<b>$memberson_txt{'3'}</b>~;
				$isguest = 1;
				if($iamadmin) {
					$theuser .= qq~ ($iplink)~;
				}
			}
			else {
				&LoadUser($key);
				if(!$iamadmin && !$iamgmod && ${$uid.$key}{'stealth'}) { next; }
				$theuser = $format{$key} . (${$uid.$key}{'stealth'} ? "*" : "");
				if($iamadmin) {
					$theuser .= qq~ ($iplink)~;
				}
			} 



remove the $tailinfo if not using arin or work with the admin config to leave it blank for others.
  

   
Back to top
WWW  
IP Logged
 
Derek Barnstorm
God Member
*****
Offline



Posts: 1146
Location: Warwickshire
Joined: Mar 23rd, 2008
Gender: Male
Re: Link IP Mod V1.2 for YaBB 2.5
Reply #8 - Nov 23rd, 2011 at 5:09pm
Print Post  
They must have changed the link since I released the Mod. I'll change it the next time I update it.
  
Back to top
 
IP Logged
 
westwegoman
New Member
*
Offline


I Love YaBB 2!

Posts: 46
Location: Westwego, La.
Joined: Feb 10th, 2012
Gender: Male
Re: Link IP Mod V1.2 for YaBB 2.5
Reply #9 - Apr 7th, 2012 at 5:09pm
Print Post  
I noticed since installing this mod that sometimes more Ip's show than members online when visiting my forum. If I refresh the page then the extra Ip dissapears.

It's something that is not a big deal but was just wondering if anybody might know what might cause this.
  


If they're big enough to hook, they're big enough to cook!!!!
Back to top
WWW  
IP Logged
 
Derek Barnstorm
God Member
*****
Offline



Posts: 1146
Location: Warwickshire
Joined: Mar 23rd, 2008
Gender: Male
Re: Link IP Mod V1.2 for YaBB 2.5
Reply #10 - Apr 8th, 2012 at 6:42pm
Print Post  
Hi Merv,

Yeah, I've noticed that. There was actually a bug in 2.4 which did exactly the same thing but it was fixed for 2.5:

http://www.yabbforum.com/community/YaBB.pl?num=1243340105

For some reason this Mod reintroduces it, but I'm not sure of the fix or why it's doing it right now, sorry!

If I do figure it out though, I'll obviously post up the changes for you.
  
Back to top
 
IP Logged
 
westwegoman
New Member
*
Offline


I Love YaBB 2!

Posts: 46
Location: Westwego, La.
Joined: Feb 10th, 2012
Gender: Male
Re: Link IP Mod V1.2 for YaBB 2.5
Reply #11 - Apr 8th, 2012 at 7:21pm
Print Post  
Ok. Thanks. Like I said, no big deal. I was just wondering if perhaps I had done something wrong.
  


If they're big enough to hook, they're big enough to cook!!!!
Back to top
WWW  
IP Logged
 
Derek Barnstorm
God Member
*****
Offline



Posts: 1146
Location: Warwickshire
Joined: Mar 23rd, 2008
Gender: Male
Re: Link IP Mod V1.2 for YaBB 2.5
Reply #12 - Jan 25th, 2013 at 3:53am
Print Post  
westwegoman wrote on Apr 7th, 2012 at 5:09pm:
I noticed since installing this mod that sometimes more Ip's show than members online when visiting my forum. If I refresh the page then the extra Ip dissapears.

It's something that is not a big deal but was just wondering if anybody might know what might cause this.

Derek Barnstorm wrote on Apr 8th, 2012 at 6:42pm:
If I do figure it out though, I'll obviously post up the changes for you.

You should find this fixes it - In Sources/LogInOut.pl find:

Code
Select All
    &buildIMS($username,''); # rebuild the Members/$username.ims file on login 


And add after:

Code
Select All
    WriteLog; 


Smiley
  
Back to top
 
IP Logged
 
westwegoman
New Member
*
Offline


I Love YaBB 2!

Posts: 46
Location: Westwego, La.
Joined: Feb 10th, 2012
Gender: Male
Re: Link IP Mod V1.2 for YaBB 2.5
Reply #13 - Jan 25th, 2013 at 3:59am
Print Post  
Nice Smiley
  


If they're big enough to hook, they're big enough to cook!!!!
Back to top
WWW  
IP Logged
 
Derek Barnstorm
God Member
*****
Offline



Posts: 1146
Location: Warwickshire
Joined: Mar 23rd, 2008
Gender: Male
Re: Link IP Mod V1.2 for YaBB 2.5
Reply #14 - Jan 25th, 2013 at 4:03am
Print Post  
Probably the longest time ever to come up with a fix though. Shocked
  
Back to top
 
IP Logged
 
Page Index Toggle Pages: [1] 2 
Send TopicPrint