Oh hey, it worked, all except searching "groups". I uploaded the old search.php and search.tpl then I took the code from the original post about moving the search box ( the code from the 2.4 search_box.tpl) and inserted it into the new search_box.tpl and the search worked.
Here is the code from the SEARCH.TPL (copy and paste this into a document and call it search.tpl then upload to the templates folder)
Code:<table width=92% align=center border=0> <tr> <td> {if $total gt "0"} <div style="MARGIN-BOTTOM: 10px; COLOR: #333; PADDING-TOP: 10px"> Related Tags: {section name=i loop=$tags} {$tags[i]} {/section} </div> <div style="MARGIN-BOTTOM: 10px; COLOR: #333; PADDING-TOP: 10px"> Sort by: Relevance - Date Added - Title - View Count - Rating </div> <table cellSpacing=0 cellPadding=0 width="100%" align=center bgColor=#cccccc border=0> <tr><td> <div class=moduleTitleBar> <table cellSpacing=0 cellPadding=0 width="100%" border=0> <TR vAlign=top class=moduleTitle> <td> <table width="739" border="0" cellspacing="0" cellpadding="0"> <tr> <td width="5" height="24" background="{$baseurl}/templates/images/bg1_l.gif">[img]{$baseurl}/templates/images/bg1_l.gif[/img]</td> <th background="{$baseurl}/templates/images/bg1.gif" width=729> <div align="left"> <table width="728" border="0" cellspacing="0" cellpadding="0"> <tr> <td class="white_bold" width="307"> Search for: {$smarty.request.search_id}</td> </td> <td width="300" align=right class="white_bold"><div style="MARGIN-RIGHT: 5px">Results {$start_num}-{$end_num} of {$total} for ' {if $smarty.request.search_type eq "related"} {section name=k loop=$ch}{$ch[k]}{/section} {else} {$smarty.request.search_id} {/if} ' <SPAN style="FONT-SIZE: smaller"> ({$ttime} seconds)</SPAN> </div> </td> </tr> </table> </div> </th> <td width="5" background="{$baseurl}/templates/images/bg1_r.gif">[img]{$baseurl}/templates/images/bg1_r.gif[/img]</td> </tr> </table> </td> </tr> </table> </div> {section name=i loop=$answers} <div class=moduleEntry> <table cellSpacing=0 cellPadding=0 width="100%" border=0> <TR vAlign=top> <td> <table cellSpacing=0 cellPadding=0 border=0> <tr> <td>[img]{$tmburl}/1_{$answers[i].VID}.jpg[/img]</td> <td>[img]{$tmburl}/2_{$answers[i].VID}.jpg[/img]</td> <td>[img]{$tmburl}/3_{$answers[i].VID}.jpg[/img]</td> </tr> </table> </td> <td width=100%> <div class=moduleEntryTitle> {$answers[i].title}</div> <div class=moduleEntryDescription>{$answers[i].description}</div> <div class=moduleEntryTags>Tags: {insert name=video_keyword assign=tags vid=$answers[i].VID} {section name=j loop=$tags} {$tags[j]} {/section} </div> <div class=moduleEntryDetails>Channels: {insert name=video_channel assign=channel vid=$answers[i].VID} {section name=k loop=$channel} {$channel[k].name} {/section} </div> <div class=moduleEntryDetails>Added: {insert name=time_range IDFR=vid tbl=video field=addtime assign=timeran id=$answers[i].VID}{$timeran} by {insert name=id_to_name assign=uname un=$answers[i].UID} {$uname} </div> <div class=moduleEntryDetails> Runtime: {$answers[i].duration|string_format:"%.2f"} | Views: {$answers[i].viewnumber} | {insert name=comment_count assign=commentcount vid=$answers[i].VID} Comments: {$commentcount} </div> <NOBR>{insert name=show_rate assign=rate rte=$answers[i].rate}{$rate}</NOBR> </td> </tr> </table> </div> {/section} </table> </div> {if $total gt $items_per_page} <div class=moduleTitleBar> <div class=page_links align=right>Pages: {$page_links} </div> </div> {/if} </td> </tr> </table> {/if} </td> </tr> </table>
Next, open search_box.tpl, copy this code and REPLACE everything in the new search_box.tpl (you can also find this code in the thread about how to move the search box) --this does not include the fix for groups search crashing, just comment out or delete the code for the option to search groups)--:
The only thing needed after that is the original search.php which I will send to you.Code:<FORM name=searchForm action="{$baseurl}/search.php" method="get"> <table border="0" cellspacing="0" cellpadding="0" align=center> <tr> <td height="34"><INPUT class=search_box tabIndex=1 maxLength=128 name="search_id" value="{$smarty.request.search_id}"></td> <td width="20"></td> <td><SELECT name=search_type class=search_select> {if $smarty.request.search_type eq "search_videos"}<OPTION value=search_videos selected>Search Videos</OPTION>{else}<OPTION value=search_videos>Search Videos</OPTION>{/if} {if $smarty.request.search_type eq "search_users"}<OPTION value=search_users selected>Search Users</OPTION>{else}<OPTION value=search_users>Search Users</OPTION>{/if} {if $smarty.request.search_type eq "search_groups"}<OPTION value=search_groups selected>Search Groups</OPTION>{else}<OPTION value=search_groups>Search Groups</OPTION>{/if} </SELECT> </td> <td width="10"></td> <td><input type=image src="{$baseurl}/templates/images/search.gif" width="90" height="20"></td> </tr> </table> </FORM>




Reply With Quote
Bookmarks