<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	>
<channel>
	<title>Comments on: New Search Functionality</title>
	<atom:link href="http://www.distantparts.com/2006/06/08/46/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.distantparts.com/2006/06/08/46/</link>
	<description>Random thoughts from a far off place</description>
	<pubDate>Mon, 01 Dec 2008 23:02:17 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.6.5</generator>
		<item>
		<title>By: Distant Parts &#187; Blog Archive &#187; Search the Carsurvey.org Airline reviews</title>
		<link>http://www.distantparts.com/2006/06/08/46/#comment-482</link>
		<dc:creator>Distant Parts &#187; Blog Archive &#187; Search the Carsurvey.org Airline reviews</dc:creator>
		<pubDate>Wed, 28 Jun 2006 17:01:35 +0000</pubDate>
		<guid isPermaLink="false">http://www.distantparts.com/2006/06/08/46/#comment-482</guid>
		<description>[...] Following on from the Improved Carsurvey.org Search, I&#8217;ve now ported this functionality to the airline reviews site. [...]</description>
		<content:encoded><![CDATA[<p>[...] Following on from the Improved Carsurvey.org Search, I&#8217;ve now ported this functionality to the airline reviews site. [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Steven</title>
		<link>http://www.distantparts.com/2006/06/08/46/#comment-332</link>
		<dc:creator>Steven</dc:creator>
		<pubDate>Fri, 09 Jun 2006 17:28:54 +0000</pubDate>
		<guid isPermaLink="false">http://www.distantparts.com/2006/06/08/46/#comment-332</guid>
		<description>You're right - it was late at night and I was thinking of highlighting the keywords in the destination page, ala Google Cache. You're right about it being pretty easy to do in the search results page itself.</description>
		<content:encoded><![CDATA[<p>You&#8217;re right - it was late at night and I was thinking of highlighting the keywords in the destination page, ala Google Cache. You&#8217;re right about it being pretty easy to do in the search results page itself.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Gary</title>
		<link>http://www.distantparts.com/2006/06/08/46/#comment-331</link>
		<dc:creator>Gary</dc:creator>
		<pubDate>Fri, 09 Jun 2006 12:08:36 +0000</pubDate>
		<guid isPermaLink="false">http://www.distantparts.com/2006/06/08/46/#comment-331</guid>
		<description>What parameters would you need to pass?

You're building the page of results and you have the search string.

Just a quick preg before writing the page.</description>
		<content:encoded><![CDATA[<p>What parameters would you need to pass?</p>
<p>You&#8217;re building the page of results and you have the search string.</p>
<p>Just a quick preg before writing the page.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Steven</title>
		<link>http://www.distantparts.com/2006/06/08/46/#comment-330</link>
		<dc:creator>Steven</dc:creator>
		<pubDate>Thu, 08 Jun 2006 20:35:16 +0000</pubDate>
		<guid isPermaLink="false">http://www.distantparts.com/2006/06/08/46/#comment-330</guid>
		<description>Thanks Gary,

Might have to consider using pspell. Hopefully there's a way to install it on Redhat Enterprise Linux 4 without recompiling PHP.

The issue with the highlighting of search words is that the destination pages are supposed to be static HTML (they're actually PHP with a bit of mod_rewrite magic). Would have to point the results at a plain PHP page to allow the passing of the parameters needed for highlighting. Will have to give the issue some thought.</description>
		<content:encoded><![CDATA[<p>Thanks Gary,</p>
<p>Might have to consider using pspell. Hopefully there&#8217;s a way to install it on Redhat Enterprise Linux 4 without recompiling PHP.</p>
<p>The issue with the highlighting of search words is that the destination pages are supposed to be static HTML (they&#8217;re actually PHP with a bit of mod_rewrite magic). Would have to point the results at a plain PHP page to allow the passing of the parameters needed for highlighting. Will have to give the issue some thought.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Gary</title>
		<link>http://www.distantparts.com/2006/06/08/46/#comment-329</link>
		<dc:creator>Gary</dc:creator>
		<pubDate>Thu, 08 Jun 2006 20:01:55 +0000</pubDate>
		<guid isPermaLink="false">http://www.distantparts.com/2006/06/08/46/#comment-329</guid>
		<description>Apologies above, it escaped the example bold tags :)

&lt;code&gt;

$search = 'test';
$search_result = 'my test str';
echo $search_result."\n";
$search_result = preg_replace('/('.$search.')/','&#60;b&#62;\1&#60;/b&#62;',$search_result);
echo $search_result."\n";

&lt;/code&gt;</description>
		<content:encoded><![CDATA[<p>Apologies above, it escaped the example bold tags <img src='http://www.distantparts.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p><code></p>
<p>$search = 'test';<br />
$search_result = 'my test str';<br />
echo $search_result."\n";<br />
$search_result = preg_replace('/('.$search.')/','&lt;b&gt;\1&lt;/b&gt;',$search_result);<br />
echo $search_result."\n";</p>
<p></code></p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Gary</title>
		<link>http://www.distantparts.com/2006/06/08/46/#comment-328</link>
		<dc:creator>Gary</dc:creator>
		<pubDate>Thu, 08 Jun 2006 20:00:15 +0000</pubDate>
		<guid isPermaLink="false">http://www.distantparts.com/2006/06/08/46/#comment-328</guid>
		<description>For search spelling suggestions I recommend &lt;a href="http://uk.php.net/pspell" rel="nofollow"&gt;pspell&lt;/a&gt;.

And for highlighting searches, how about...



$search = 'test';
$search_result = 'my test str';
echo $search_result."\n";
$search_result = preg_replace('/('.$search.')/','&lt;b&gt;\1&lt;/b&gt;',$search_result);
echo $search_result."\n";

</description>
		<content:encoded><![CDATA[<p>For search spelling suggestions I recommend <a href="http://uk.php.net/pspell" rel="nofollow">pspell</a>.</p>
<p>And for highlighting searches, how about&#8230;</p>
<p>$search = &#8216;test&#8217;;<br />
$search_result = &#8216;my test str&#8217;;<br />
echo $search_result.&#8221;\n&#8221;;<br />
$search_result = preg_replace(&#8217;/(&#8217;.$search.&#8217;)/&#8217;,&#8217;<b>\1</b>&#8216;,$search_result);<br />
echo $search_result.&#8221;\n&#8221;;</p>
]]></content:encoded>
	</item>
</channel>
</rss>
