1
I have been trying to get the Xoopsmembers module to search members Occupation. Before installing xoopsmembers, I changed the user_occ (Occupation) in the adminpanel/profiles/field to a drop down menu. I would think that the xoopsmembers searchform needs to have a drop down menu for occupation instead of a "Contains" statement.
But this is what I have done so far...I removed the URL and added Occupation, I have also added admin rights only to "realname". But unfortunately, if someone types a name in the search form, it will not show their real name, but it will find everyone with that name showing only their username. I would like to edit the searchform, but not sure where to find it so I can remove the realname from the search query (changes shown in red). Has anyone worked on this to show occupation or have any idea on how to make the searchform show a drop down menu for occupation?
/xoopsmembers/templates/xoopsmembers_searchresults.html
<a href="index.php"><{$lang_search}>a> <span style="font-weight:bold;">»»span> <{$lang_results}><br /><br />
<{if $total_found != 0}>
<table class="outer" cellspacing="1" cellpadding="4">
<tr>
<th align="center"><{$lang_username}>th>
[color=CC0000]<{if $is_admin == true}>
<th align="center"><{$lang_realname}>th>
<{/if}>[/color]
<th align="center"><{$lang_email}>th>
<th align="center"><{$lang_privmsg}>th>
[color=CC0000]<th align="center"><{$lang_occupation}>th>[/color]
<th align="center"><{$lang_regdate}>th>
<th align="center"><{$lang_lastlogin}>th>
<th align="center"><{$lang_posts}>th>
<{if $is_admin == true}>
<th align="center"><{$lang_admin}>th>
<{/if}>
tr>
<{section name=i loop=$users}>
<tr valign="middle">
<td class="odd"><a href="<{$xoops_url}>/userinfo.php?uid=<{$users[i].id}>"><{$users[i].name}>a>td>
[color=CC0000]<{if $is_admin == true}>
<td class="even"><{$users[i].realname}>td>
<{/if}>[/color]
<td align="center" class="odd"><{$users[i].email}>td>
<td class="even" align="center"><{$users[i].pmlink}>td>
[color=CC0000]<td class="odd" align="center"><{$users[i].occupation}>td>[/color]
<td class="even" align="center"><{$users[i].registerdate}>td>
<td class="odd" align="center"><{$users[i].lastlogin}>td>
<td class="even" align="center"><{$users[i].posts}>td>
<{if $is_admin == true}>
<td class="odd" align="center"><{$users[i].adminlink}>td>
<{/if}>
tr>
<{/section}>
table>
<div style="text-align:center">
<{$pagenav}>
<{$lang_numfound}>
div>
<{else}>
<{$lang_nonefound}>
<{/if}>