<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head><meta http-equiv="content-type" content="text/html; charset=utf-8" /><style type="text/css"><!--
#msg dl { border: 1px #006 solid; background: #369; padding: 6px; color: #fff; }
#msg dt { float: left; width: 6em; font-weight: bold; }
#msg dt:after { content:':';}
#msg dl, #msg dt, #msg ul, #msg li, #header, #footer { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt;  }
#msg dl a { font-weight: bold}
#msg dl a:link    { color:#fc3; }
#msg dl a:active  { color:#ff0; }
#msg dl a:visited { color:#cc6; }
h3 { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; font-weight: bold; }
#msg pre { overflow: auto; background: #ffc; border: 1px #fc0 solid; padding: 6px; }
#msg ul, pre { overflow: auto; }
#header, #footer { color: #fff; background: #636; border: 1px #300 solid; padding: 6px; }
#patch { width: 100%; }
#patch h4 {font-family: verdana,arial,helvetica,sans-serif;font-size:10pt;padding:8px;background:#369;color:#fff;margin:0;}
#patch .propset h4, #patch .binary h4 {margin:0;}
#patch pre {padding:0;line-height:1.2em;margin:0;}
#patch .diff {width:100%;background:#eee;padding: 0 0 10px 0;overflow:auto;}
#patch .propset .diff, #patch .binary .diff  {padding:10px 0;}
#patch span {display:block;padding:0 10px;}
#patch .modfile, #patch .addfile, #patch .delfile, #patch .propset, #patch .binary, #patch .copfile {border:1px solid #ccc;margin:10px 0;}
#patch ins {background:#dfd;text-decoration:none;display:block;padding:0 10px;}
#patch del {background:#fdd;text-decoration:none;display:block;padding:0 10px;}
#patch .lines, .info {color:#888;background:#fff;}
--></style>
<title>[BuddyPress] [1947] trunk:
  Fixes #1077 but this is part of a wider search conflict problem that will need to be addressed in a future version
 .</title>
</head>
<body>

<div id="msg">
<dl>
<dt>Revision</dt> <dd>1947</dd>
<dt>Author</dt> <dd>apeatling</dd>
<dt>Date</dt> <dd>2009-09-25 18:40:35 +0000 (Fri, 25 Sep 2009)</dd>
</dl>

<h3>Log Message</h3>
<pre>Fixes #1077 but this is part of a wider search conflict problem that will need to be addressed in a future version.</pre>

<h3>Modified Paths</h3>
<ul>
<li><a href="#trunkbpcorephp">trunk/bp-core.php</a></li>
<li><a href="#trunkbpforumsbpforumstemplatetagsphp">trunk/bp-forums/bp-forums-templatetags.php</a></li>
</ul>

</div>
<div id="patch">
<h3>Diff</h3>
<a id="trunkbpcorephp"></a>
<div class="modfile"><h4>Modified: trunk/bp-core.php (1946 => 1947)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/bp-core.php        2009-09-24 07:19:28 UTC (rev 1946)
+++ trunk/bp-core.php        2009-09-25 18:40:35 UTC (rev 1947)
</span><span class="lines">@@ -1532,21 +1532,25 @@
</span><span class="cx">                         switch ( $search_which ) {
</span><span class="cx">                                 case 'members': default:
</span><span class="cx">                                         $slug = BP_MEMBERS_SLUG;
</span><ins>+                                        $var = '/?s=';
</ins><span class="cx">                                         break;
</span><span class="cx">                                 case 'groups':
</span><span class="cx">                                         $slug = BP_GROUPS_SLUG;
</span><ins>+                                        $var = '/?s=';
</ins><span class="cx">                                         break;
</span><span class="cx">                                 case 'forums':
</span><span class="cx">                                         $slug = BP_FORUMS_SLUG;
</span><ins>+                                        $var = '/?fs=';
</ins><span class="cx">                                         break;
</span><span class="cx">                                 case 'blogs':
</span><span class="cx">                                         $slug = BP_BLOGS_SLUG;
</span><ins>+                                        $var = '/?s=';
</ins><span class="cx">                                         break;
</span><span class="cx">                         }
</span><span class="cx">                 }
</span><del>-
-                $search_url = apply_filters( 'bp_core_search_site', site_url( $slug . '/?s=' . urlencode($search_terms) ), $search_terms );
</del><span class="cx">                 
</span><ins>+                $search_url = apply_filters( 'bp_core_search_site', site_url( $slug . $var . urlencode($search_terms) ), $search_terms );
+                
</ins><span class="cx">                 bp_core_redirect( $search_url );
</span><span class="cx">         }
</span><span class="cx"> }
</span></span></pre></div>
<a id="trunkbpforumsbpforumstemplatetagsphp"></a>
<div class="modfile"><h4>Modified: trunk/bp-forums/bp-forums-templatetags.php (1946 => 1947)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/bp-forums/bp-forums-templatetags.php        2009-09-24 07:19:28 UTC (rev 1946)
+++ trunk/bp-forums/bp-forums-templatetags.php        2009-09-25 18:40:35 UTC (rev 1947)
</span><span class="lines">@@ -180,8 +180,8 @@
</span><span class="cx">                 $filter = $bp-&gt;action_variables[0];
</span><span class="cx"> 
</span><span class="cx">         /* If $_GET['s'] is set, let's auto populate the filter var */
</span><del>-        if ( $bp-&gt;is_directory &amp;&amp; !empty( $_GET['s'] ) )
-                $filter = $_GET['s'];
</del><ins>+        if ( $bp-&gt;is_directory &amp;&amp; !empty( $_GET['fs'] ) )
+                $filter = $_GET['fs'];
</ins><span class="cx">                 
</span><span class="cx">         $forum_template = new BP_Forums_Template_Forum( $type, $forum_id, $per_page, $max, $no_stickies, $filter );
</span><span class="cx"> 
</span><span class="lines">@@ -920,7 +920,7 @@
</span><span class="cx"> function bp_directory_forums_search_form() {
</span><span class="cx">         global $bp; ?&gt;
</span><span class="cx">         &lt;form action=&quot;&lt;?php echo $bp-&gt;root_domain . '/' . $bp-&gt;forums-&gt;slug . '/'; ?&gt;&quot; method=&quot;get&quot; id=&quot;search-forums-form&quot;&gt;
</span><del>-                &lt;label&gt;&lt;input type=&quot;text&quot; name=&quot;s&quot; id=&quot;forums_search&quot; value=&quot;&lt;?php if ( isset( $_GET['s'] ) ) { echo attribute_escape( $_GET['s'] ); } else { _e( 'Search anything...', 'buddypress' ); } ?&gt;&quot;  onfocus=&quot;if (this.value == '&lt;?php _e( 'Search anything...', 'buddypress' ) ?&gt;') {this.value = '';}&quot; onblur=&quot;if (this.value == '') {this.value = '&lt;?php _e( 'Search anything...', 'buddypress' ) ?&gt;';}&quot; /&gt;&lt;/label&gt;
</del><ins>+                &lt;label&gt;&lt;input type=&quot;text&quot; name=&quot;fs&quot; id=&quot;forums_search&quot; value=&quot;&lt;?php if ( isset( $_GET['fs'] ) ) { echo attribute_escape( $_GET['fs'] ); } else { _e( 'Search anything...', 'buddypress' ); } ?&gt;&quot;  onfocus=&quot;if (this.value == '&lt;?php _e( 'Search anything...', 'buddypress' ) ?&gt;') {this.value = '';}&quot; onblur=&quot;if (this.value == '') {this.value = '&lt;?php _e( 'Search anything...', 'buddypress' ) ?&gt;';}&quot; /&gt;&lt;/label&gt;
</ins><span class="cx">                 &lt;input type=&quot;submit&quot; id=&quot;forums_search_submit&quot; name=&quot;submit&quot; value=&quot;&lt;?php _e( 'Search', 'buddypress' ) ?&gt;&quot; /&gt;
</span><span class="cx">         &lt;/form&gt;
</span><span class="cx"> &lt;?php
</span></span></pre>
</div>
</div>

</body>
</html>