Hey,
I am trying to get the member search function to work in a side bar on all pages to let my users search for other members by custom profile fields.
This is the member search code
Code:
<form action="memberlist.php?do=getall" method="post">
<input type="hidden" name="s" value="$session[sessionhash]" />
<input type="hidden" name="do" value="getall" />
<table class="tborder" cellpadding="$stylevar[cellpadding]" cellspacing="$stylevar[cellspacing]" border="0" width="100%" align="center">
<tr>
<td class="tcat">$vbphrase[members_list] - $vbphrase[advanced_search]</td>
</tr>
<tr>
<td class="panelsurround" align="center">
<div class="panel">
<div style="width:$stylevar[formwidth]" align="$stylevar[left]">
<div style="margin-bottom:$stylevar[formspacer]px">
$vbphrase[fields_on_form_optional]
</div>
<div class="fieldset">
$vbphrase[username]
<div id="userfield"><input type="text" class="bginput" id="userfield_txt" size="50" name="ausername" value="" /></div>
<if condition="$show['popups']">
<div id="userfield_menu" class="vbmenu_popup" style="display:none"></div>
<script type="text/javascript" src="clientscript/vbulletin_ajax_namesugg.js?v=$vboptions[simpleversion]"></script>
<script type="text/javascript">
<!--
vbmenu_register('userfield', true);
snc = new vB_AJAX_NameSuggest('snc', 'userfield_txt', 'userfield');
//-->
</script>
</if>
</div>
<div class="fieldset">
$vbphrase[home_page]<br />
<input type="text" class="bginput" size="50" name="homepage" value="" />
</div>
$customfields
<fieldset class="fieldset">
<legend>$vbphrase[instant_messaging]</legend>
<table cellpadding="0" cellspacing="$stylevar[formspacer]" border="0">
<tr>
<td>
$vbphrase[icq_number]<br />
<img src="$stylevar[imgdir_misc]/im_icq.gif" alt="" />
<input type="text" class="bginput" size="25" name="icq" value="" dir="ltr" />
</td>
<td>
$vbphrase[aim_screen_name]<br />
<img src="$stylevar[imgdir_misc]/im_aim.gif" alt="" />
<input type="text" class="bginput" size="25" name="aim" value="" dir="ltr" />
</td>
</tr>
<tr>
<td>
$vbphrase[msn_messenger_handle]<br />
<img src="$stylevar[imgdir_misc]/im_msn.gif" alt="" />
<input type="text" class="bginput" size="25" name="msn" value="" dir="ltr" />
</td>
<td>
$vbphrase[yahoo_messenger_handle]<br />
<img src="$stylevar[imgdir_misc]/im_yahoo.gif" alt="" />
<input type="text" class="bginput" size="25" name="yahoo" value="" dir="ltr" />
</td>
</tr>
<tr>
<td>
$vbphrase[skype_name]<br />
<img src="$stylevar[imgdir_misc]/im_skype.gif" alt="" />
<input type="text" class="bginput" size="25" name="skype" value="" dir="ltr" />
</td>
<td> </td>
</tr>
</table>
</fieldset>
<fieldset class="fieldset">
<legend>$vbphrase[post_count]</legend>
<table cellpadding="0" cellspacing="$stylevar[formspacer]" border="0">
<tr>
<td>
$vbphrase[is_greater_than_or_equal_to]<br />
<input type="text" class="bginput" size="25" name="postslower" value="" />
</td>
<td>
$vbphrase[is_less_than]<br />
<input type="text" class="bginput" size="25" name="postsupper" value="" />
</td>
</tr>
</table>
</fieldset>
<fieldset class="fieldset">
<legend>$vbphrase[join_date]</legend>
<table cellpadding="0" cellspacing="$stylevar[formspacer]" border="0">
<tr>
<td>
$vbphrase[is_after]<br />
<input type="text" class="bginput" size="25" name="joindateafter" value="" />
</td>
<td>
$vbphrase[is_before]<br />
<input type="text" class="bginput" size="25" name="joindatebefore" value="" />
</td>
</tr>
<tr>
<td colspan="2">$vbphrase[please_use_format]</td>
</tr>
</table>
</fieldset>
<fieldset class="fieldset">
<legend>$vbphrase[last_post]</legend>
<table cellpadding="0" cellspacing="$stylevar[formspacer]" border="0">
<tr>
<td>
$vbphrase[is_after]<br />
<input type="text" class="bginput" size="25" name="lastpostafter" value="" />
</td>
<td>
$vbphrase[is_before]<br />
<input type="text" class="bginput" size="25" name="lastpostbefore" value="" />
</td>
</tr>
<tr>
<td colspan="2">$vbphrase[please_use_format_yyyymmdd_hhmmss]</td>
</tr>
</table>
</fieldset>
</div>
</div>
<div class="thead" style="padding:$stylevar[cellpadding]px">$vbphrase[options]</div>
<div class="panel" align="center">
<div style="width:$stylevar[formwidth]" align="$stylevar[left]">
<fieldset class="fieldset">
<legend>$vbphrase[options]</legend>
<table cellpadding="0" cellspacing="$stylevar[formspacer]" border="0">
<tr>
<td>
$vbphrase[order_results_by]<br />
<select name="sort">
<option value="username" selected="selected">$vbphrase[username]</option>
<option value="joindate">$vbphrase[join_date]</option>
<option value="posts">$vbphrase[post_count]</option>
<option value="lastvisit">$vbphrase[last_visit]</option>
<if condition="$vboptions['reputationenable']">
<option value="reputation">$vbphrase[reputation]</option>
</if>
</select>
<select name="order">
<option value="">$vbphrase[in_ascending_order]</option>
<option value="DESC">$vbphrase[in_descending_order]</option>
</select>
</td>
</tr>
<tr>
<td>
$vbphrase[number_of_users_perpage]<br />
<input type="text" class="bginput" size="25" name="pp" value="$vboptions[memberlistperpage]" />
</td>
</tr>
</table>
</fieldset>
</div>
</div>
<div style="margin-top:$stylevar[cellpadding]px">
<input type="submit" class="button" value="$vbphrase[search_now]" accesskey="s" />
<input type="reset" class="button" value="$vbphrase[reset_fields]" />
</div>
</td>
</tr>
</table>
</form>
I have the normal search on the sidebar but not sure how the member search will work.
Thanks a lot
John