View Single Post
  #64  
Old 03-30-2003, 01:30 AM
jibious's Avatar
jibious jibious is offline
 
Join Date: Nov 2002
Posts: 39
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

i've added on some things to make this a little more complete. gives search functionality in memberlist.php as well as the admin user section.

===============
in memberlist.php
===============

find:

Code:
aim
after it add:

Code:
,msn
then find:

Code:
    if ($aim!="") {
      $condition.=" AND aim LIKE '%".addslashes(htmlspecialchars($aim))."%' ";
    }
after it add:

Code:
    if ($msn!="") {
      $condition.=" AND msn LIKE '%".addslashes(htmlspecialchars($msn))."%' ";
    }
then find:

Code:
    if ($userinfo[aim]!="") {
      eval("\$userinfo[aimicon] = \"".gettemplate("aim")."\";");
    } else {
      $userinfo[aim]=" ";
    }
after it add:

Code:
    if ($userinfo[msn]!="") {
      eval("\$userinfo[msnicon] = \"".gettemplate("msn")."\";");
    } else {
      $userinfo[msn]=" ";
    }
then find:

Code:
&aim=$aim
after it add:

Code:
&msn=$msn

===============
in admin/user.php
===============

find:

Code:
	  makeinputcode("AIM Handle","aim");
after it add:

Code:
	  makeinputcode("MSN Messenger Handle","msn");
then find:

Code:
aim,
after it add:

Code:
msn,
then find:

Code:
'".addslashes(htmlspecialchars($aim))."',
after it add:

Code:
'".addslashes(htmlspecialchars($msn))."',
then find:

Code:
	  makeinputcode("AIM Handle","aim",$user[aim],0);
after it add:

Code:
	  makeinputcode("MSN Messenger Handle","msn",$user[msn],0);
then find:

Code:
,aim='".addslashes(htmlspecialchars($aim))."'
after it add:

Code:
,msn='".addslashes(htmlspecialchars($msn))."'
then find:

Code:
  makeinputcode("and AIM Handle contains","aim");
after it add:

Code:
  makeinputcode("and MSN Messenger Handle contains","msn");
then find:

Code:
  makeyesnocode("Display AIM ID","displayaim",0);
after it add:

Code:
  makeyesnocode("Display MSN ID","displaymsn",0);
then find:

Code:
 and $displayaim == 0
after it add:

Code:
 and $displaymsn == 0
then find:

Code:
  if ($aim!="") {
    $condition.=" AND INSTR(LCASE(aim),'".addslashes(strtolower($aim))."')>0";
  }
after it add:

Code:
  if ($msn!="") {
    $condition.=" AND INSTR(LCASE(msn),'".addslashes(strtolower($msn))."')>0";
  }
then find:

Code:
,aim
after it add:

Code:
,msn
then find:

Code:
		if ($displayaim==1) {
			echo "<td><p><b><span class='tblhead'>AIM ID</span></b></p></td>";
		}
after it add:

Code:
		if ($displaymsn==1) {
			echo "<td><p><b><span class='tblhead'>MSN ID</span></b></p></td>";
		}
then find:

Code:
			if ($displayaim==1) {
				if ($user[aim]=="") {
					$user[aim]="&nbsp;";
				}
				echo "<td><p>$user[aim]</p></td>";
			}
after it add:

Code:
			if ($displaymsn==1) {
				if ($user[msn]=="") {
					$user[msn]="&nbsp;";
				}
				echo "<td><p>$user[msn]</p></td>";
			}
then find:

Code:
			makehiddencode("aim",$aim);
after it add:

Code:
			makehiddencode("msn",$msn);
then find:

Code:
			makehiddencode("displayaim",$displayaim);
after it add:

Code:
			makehiddencode("displaymsn",$displaymsn);
==================
In memberlist template
==================

find:

Code:
	<td align="center" bgcolor="{ tableheadbgcolor }"><smallfont color="{ tableheadtextcolor }"><b>AIM</b></smallfont></td>
add under it:

Code:
	<td align="center" bgcolor="{ tableheadbgcolor }"><smallfont color="{ tableheadtextcolor }"><b>MSN</b></smallfont></td>
==================
in memberlistsearch template
==================

find:

Code:
<tr>
	<td bgcolor="{ secondaltcolor }"><normalfont><b>and AIM Handle contains</b></normalfont></td>
	<td bgcolor="{ secondaltcolor }"><normalfont><input type="text" class="bginput" size="35" name="aim" value=""></normalfont></td>
</tr>
add under it:

Code:
<tr>
	<td bgcolor="{ firstaltcolor }"><normalfont><b>and MSN Messenger Handle contains</b></normalfont></td>
	<td bgcolor="{ firstaltcolor }"><normalfont><input type="text" class="bginput" size="35" name="msn" value=""></normalfont></td>
</tr>
==================
in memberlistbit template
==================

find:

Code:
	<td bgcolor="{firstaltcolor}">$ userinfo[aimicon]</td>
add under it:

Code:
	<td bgcolor="{firstaltcolor}">$ userinfo[msnicon]</td>

*note: you will need to remove the spaces (" ") between the {} on the template mods for the colors. also, fix the secondalt and firstalt colors to suit your board (i use the same for both, so i didn't need to make any fixes).
Reply With Quote
 
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01229 seconds
  • Memory Usage 1,827KB
  • Queries Executed 11 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD_SHOWPOST
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (42)bbcode_code
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_box
  • (1)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (1)post_thanks_postbit_info
  • (1)postbit
  • (1)postbit_onlinestatus
  • (1)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • reputationlevel
  • showthread
Included Files:
  • ./showpost.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_postinfo_query
  • fetch_postinfo
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showpost_start
  • bbcode_fetch_tags
  • bbcode_create
  • postbit_factory
  • showpost_post
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • showpost_complete