Spike223
08-24-2005, 10:00 PM
Alright, this is my first ever mod, I actually did it for someone else, and they suggested I post it here, but I'm no goood at making mods professional, so this is probably a very crude way of doing it to some of you, so bear with me, it does work, though.
Description:
This Mod will add popup links, just like Aim, Yahoo, ICQ, and MSN, but for Google Talk. IT will add them in the user's profile, their postbit (both styles), and the Member List (if enabled).
How To Install:
Firstly, you need to create a custom Profile Field, single-line textbox, and REMEMBER it's name. It should be something like "field__" where the __'s are a number.
Then, follow these directions. Sorry they're so crude, but I decided to document it 1/3 of the way in, and Notepad was the handiest way.
REMEMBER to replace, ANYWHERE you see "field10" in this document, with your own field name from above, otherwise it'll grab the wrong profile field!!!
Here's the mod instructions:
Upload im_gt.gif into %FORUM_ROOT%/images/misc/ (image is below quote box)
++ In sendmessage.php::
Replace: 'aim' => 'AIM',
With: 'aim' => 'AIM',
'gt' => 'Google Talk',
Replace: case 'icq':
$userinfo['icq'] = trim(htmlspecialchars_uni($userinfo['icq']));
break;
With: case 'icq':
$userinfo['icq'] = trim(htmlspecialchars_uni($userinfo['icq']));
break;
case 'gt':
$type = 'gt';
break;
Replace: if (empty($userinfo["$type"]))
{
// user does not have this messaging meduim defined
eval(print_standard_error('error_immethodnotdefine d'));
}
With: if (empty($userinfo["$type"]) and empty($userinfo['field10']))
{
// user does not have this messaging meduim defined
eval(print_standard_error('error_immethodnotdefine d'));
}
++ In Template MEMBERINFO::
Replace:
<if condition="$userinfo['showyahoo']">
<tr>
<td>$userinfo[yahooicon]</td>
<td><a href="#" onclick="return imwindow('yahoo', '$userinfo[userid]', 400, 200)">$userinfo[yahoo]</a></td>
</tr>
</if>
With:
<if condition="$userinfo['showyahoo']">
<tr>
<td>$userinfo[yahooicon]</td>
<td><a href="#" onclick="return imwindow('yahoo', '$userinfo[userid]', 450, 200)">$userinfo[yahoo]</a></td>
</tr>
</if>
<if condition="$userinfo[field10]">
<tr>
<td><a href="#" onclick="return imwindow('gt', '$userinfo[userid]', 450, 200)"><img src="images/misc/im_gt.gif" border="0"></a></td>
<td><a href="#" onclick="return imwindow('gt', '$userinfo[userid]', 450, 200)">$userinfo[field10]</a></td>
</tr>
</if>
++ In template memberlist_resultsbit:
Replace:
<if condition="$show['imicons'] AND exec_switch_bg()"><td class="$bgclass">$userinfo[icqicon] $userinfo[aimicon] $userinfo[msnicon] $userinfo[yahooicon]</td></if>
With:
<if condition="$show['imicons'] AND exec_switch_bg()"><td class="$bgclass">$userinfo[icqicon] $userinfo[aimicon] $userinfo[msnicon] $userinfo[yahooicon] <if condition="$userinfo[field10]"><a href="#" onclick="return imwindow('gt', '$userinfo[userid]', 400, 200)"><img src="images/misc/im_gt.gif" border="0"></a></if></td></if>
++ In Postbit and Postbit_Legacy Templates:: ***WARNING: NOT TESTED ON REGULAR POSTBIT STYLE, ONLY LEGACY!***
Find:
<div>$post[icqicon] $post[aimicon] $post[msnicon] $post[yahooicon]</div>
Replace:
<div>$post[icqicon] $post[aimicon] $post[msnicon] $post[yahooicon] <if condition="$post[field10]"><a href="#" onclick="return imwindow('gt', '$userinfo[userid]', 400, 200)"><img src="images/misc/im_gt.gif" border="0"></a></if></div>
Create Template Called "im_send_gt", put this in it, but replace with HTML where it says __CONTENT HERE__. The user's GT s/n is "$userinfo[field10]", no quotes.
-----------------------------------------------------------------------------------
<table class="tborder" cellpadding="6" cellspacing="1" border="0" width="100%" align="center">
<tr>
<td class="tcat">
<span class="smallfont" style="float:right"><a href="#" onclick="self.close()">Close this window</a></span>
Google Talk
</td>
</tr>
<tr>
<td class="panelsurround" align="center">
<div class="panel">
*** __CONTENT HERE__ ***
</div>
</td>
</tr>
</table>
</body>
</html>
-----------------------------------------------------------------------------------
Add whatever you like in it, but whatever you add, HTML allowed!, will be displayed in the popup window for contacting that user.
Any feedback is greatly appreciated, I pulled this together in about an hour or two. Here's my image, you can make your own if you like:
https://vborg.vbsupport.ru/
Thanks, hope it works!
If you liked this mod, please make sure to:
CLICK INSTALL!
Post yuor feedback, especially since this is my first mod!!!
Description:
This Mod will add popup links, just like Aim, Yahoo, ICQ, and MSN, but for Google Talk. IT will add them in the user's profile, their postbit (both styles), and the Member List (if enabled).
How To Install:
Firstly, you need to create a custom Profile Field, single-line textbox, and REMEMBER it's name. It should be something like "field__" where the __'s are a number.
Then, follow these directions. Sorry they're so crude, but I decided to document it 1/3 of the way in, and Notepad was the handiest way.
REMEMBER to replace, ANYWHERE you see "field10" in this document, with your own field name from above, otherwise it'll grab the wrong profile field!!!
Here's the mod instructions:
Upload im_gt.gif into %FORUM_ROOT%/images/misc/ (image is below quote box)
++ In sendmessage.php::
Replace: 'aim' => 'AIM',
With: 'aim' => 'AIM',
'gt' => 'Google Talk',
Replace: case 'icq':
$userinfo['icq'] = trim(htmlspecialchars_uni($userinfo['icq']));
break;
With: case 'icq':
$userinfo['icq'] = trim(htmlspecialchars_uni($userinfo['icq']));
break;
case 'gt':
$type = 'gt';
break;
Replace: if (empty($userinfo["$type"]))
{
// user does not have this messaging meduim defined
eval(print_standard_error('error_immethodnotdefine d'));
}
With: if (empty($userinfo["$type"]) and empty($userinfo['field10']))
{
// user does not have this messaging meduim defined
eval(print_standard_error('error_immethodnotdefine d'));
}
++ In Template MEMBERINFO::
Replace:
<if condition="$userinfo['showyahoo']">
<tr>
<td>$userinfo[yahooicon]</td>
<td><a href="#" onclick="return imwindow('yahoo', '$userinfo[userid]', 400, 200)">$userinfo[yahoo]</a></td>
</tr>
</if>
With:
<if condition="$userinfo['showyahoo']">
<tr>
<td>$userinfo[yahooicon]</td>
<td><a href="#" onclick="return imwindow('yahoo', '$userinfo[userid]', 450, 200)">$userinfo[yahoo]</a></td>
</tr>
</if>
<if condition="$userinfo[field10]">
<tr>
<td><a href="#" onclick="return imwindow('gt', '$userinfo[userid]', 450, 200)"><img src="images/misc/im_gt.gif" border="0"></a></td>
<td><a href="#" onclick="return imwindow('gt', '$userinfo[userid]', 450, 200)">$userinfo[field10]</a></td>
</tr>
</if>
++ In template memberlist_resultsbit:
Replace:
<if condition="$show['imicons'] AND exec_switch_bg()"><td class="$bgclass">$userinfo[icqicon] $userinfo[aimicon] $userinfo[msnicon] $userinfo[yahooicon]</td></if>
With:
<if condition="$show['imicons'] AND exec_switch_bg()"><td class="$bgclass">$userinfo[icqicon] $userinfo[aimicon] $userinfo[msnicon] $userinfo[yahooicon] <if condition="$userinfo[field10]"><a href="#" onclick="return imwindow('gt', '$userinfo[userid]', 400, 200)"><img src="images/misc/im_gt.gif" border="0"></a></if></td></if>
++ In Postbit and Postbit_Legacy Templates:: ***WARNING: NOT TESTED ON REGULAR POSTBIT STYLE, ONLY LEGACY!***
Find:
<div>$post[icqicon] $post[aimicon] $post[msnicon] $post[yahooicon]</div>
Replace:
<div>$post[icqicon] $post[aimicon] $post[msnicon] $post[yahooicon] <if condition="$post[field10]"><a href="#" onclick="return imwindow('gt', '$userinfo[userid]', 400, 200)"><img src="images/misc/im_gt.gif" border="0"></a></if></div>
Create Template Called "im_send_gt", put this in it, but replace with HTML where it says __CONTENT HERE__. The user's GT s/n is "$userinfo[field10]", no quotes.
-----------------------------------------------------------------------------------
<table class="tborder" cellpadding="6" cellspacing="1" border="0" width="100%" align="center">
<tr>
<td class="tcat">
<span class="smallfont" style="float:right"><a href="#" onclick="self.close()">Close this window</a></span>
Google Talk
</td>
</tr>
<tr>
<td class="panelsurround" align="center">
<div class="panel">
*** __CONTENT HERE__ ***
</div>
</td>
</tr>
</table>
</body>
</html>
-----------------------------------------------------------------------------------
Add whatever you like in it, but whatever you add, HTML allowed!, will be displayed in the popup window for contacting that user.
Any feedback is greatly appreciated, I pulled this together in about an hour or two. Here's my image, you can make your own if you like:
https://vborg.vbsupport.ru/
Thanks, hope it works!
If you liked this mod, please make sure to:
CLICK INSTALL!
Post yuor feedback, especially since this is my first mod!!!