<?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"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
		>
<channel>
	<title>Comments on: Quick Access v.1.0</title>
	<atom:link href="http://chapter42.whitewhale.net/2008/06/15/quickaccess/feed/" rel="self" type="application/rss+xml" />
	<link>http://chapter42.whitewhale.net/2008/06/15/quickaccess/</link>
	<description></description>
	<lastBuildDate>Fri, 05 Feb 2010 21:41:26 -0500</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8.4</generator>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
		<item>
		<title>By: Donald</title>
		<link>http://chapter42.whitewhale.net/2008/06/15/quickaccess/comment-page-1/#comment-17</link>
		<dc:creator>Donald</dc:creator>
		<pubDate>Tue, 22 Jul 2008 15:58:34 +0000</pubDate>
		<guid isPermaLink="false">http://chapter42.whaleblogs.net/?p=50#comment-17</guid>
		<description>Klark, the input box is added in lines 39 and 40:
&lt;pre&gt;
if(this.is(&#039;input[type=text],textarea&#039;)) qa.search=this; // if the specified item is an input element, use it
else qa.search = this.prepend(&#039;&lt;input type=&quot;text&quot; id=&quot;qa_search_query&quot;/&gt;&#039;).children().eq(0); // otherwise, add an input inside of it
&lt;/pre&gt;
So when you call quickaccess with &lt;span class=&quot;code&quot;&gt;$(&#039;#example&#039;).quickaccess(settings);&lt;/span&gt;, it looks for #example; if #example is a text input or textarea, it uses it as the quickaccess query box; otherwise, if #example is a div or paragraph (etc) line 40 inserts a query box into that element (prepended before the elements other content). Let me know if that helps.</description>
		<content:encoded><![CDATA[<p>Klark, the input box is added in lines 39 and 40:</p>
<pre>
if(this.is('input[type=text],textarea')) qa.search=this; // if the specified item is an input element, use it
else qa.search = this.prepend('&lt;input type="text" id="qa_search_query"/&gt;').children().eq(0); // otherwise, add an input inside of it
</pre>
<p>So when you call quickaccess with <span class="code">$(&#8217;#example&#8217;).quickaccess(settings);</span>, it looks for #example; if #example is a text input or textarea, it uses it as the quickaccess query box; otherwise, if #example is a div or paragraph (etc) line 40 inserts a query box into that element (prepended before the elements other content). Let me know if that helps.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Klark</title>
		<link>http://chapter42.whitewhale.net/2008/06/15/quickaccess/comment-page-1/#comment-16</link>
		<dc:creator>Klark</dc:creator>
		<pubDate>Sat, 19 Jul 2008 03:50:06 +0000</pubDate>
		<guid isPermaLink="false">http://chapter42.whaleblogs.net/?p=50#comment-16</guid>
		<description>This is great. Could you tell me what it is that writes the input box in the quickquery div? I can&#039;t figure it out!</description>
		<content:encoded><![CDATA[<p>This is great. Could you tell me what it is that writes the input box in the quickquery div? I can&#8217;t figure it out!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Donald</title>
		<link>http://chapter42.whitewhale.net/2008/06/15/quickaccess/comment-page-1/#comment-19</link>
		<dc:creator>Donald</dc:creator>
		<pubDate>Wed, 18 Jun 2008 20:33:56 +0000</pubDate>
		<guid isPermaLink="false">http://chapter42.whaleblogs.net/?p=50#comment-19</guid>
		<description>Jason,

We&#039;d used the title attribute in the first several versions of this for Haverford, but switched to comments before the site went live. What we decided was that the title attribute has a meaning of its own (both semantic and behavioral) and we shouldn&#039;t co-opt that for our own purposes (see also a future post that I&#039;ll call &quot;Our Beef with Microformats&quot;). Basically, it was really annoying to have &quot;PoliSci, International Relations,American&quot; show up when you moused over the link for &quot;Political Science&quot;.

If you&#039;d prefer the title attribute approach, though, just change line 50 of the QA.js to:
&lt;pre&gt;
qa.matches = qa.links = $(s.selector).each(function() { $.data(this,&#039;keywords&#039;,(this.innerHTML+$(this).attr(&#039;title&#039;)).toLowerCase().replace(/[,-\/]/g,&#039; &#039;).replace(/[^a-zA-Z 0-9]+/g,&#039;&#039;)); }); // grab links, attach data to match against
&lt;/pre&gt;
(Adding &quot;+$(this).attr(&#039;title&#039;)&quot; to the matched text.)

I&#039;d love to see a sample page when you get it up and running!</description>
		<content:encoded><![CDATA[<p>Jason,</p>
<p>We&#8217;d used the title attribute in the first several versions of this for Haverford, but switched to comments before the site went live. What we decided was that the title attribute has a meaning of its own (both semantic and behavioral) and we shouldn&#8217;t co-opt that for our own purposes (see also a future post that I&#8217;ll call &#8220;Our Beef with Microformats&#8221;). Basically, it was really annoying to have &#8220;PoliSci, International Relations,American&#8221; show up when you moused over the link for &#8220;Political Science&#8221;.</p>
<p>If you&#8217;d prefer the title attribute approach, though, just change line 50 of the QA.js to:</p>
<pre>
qa.matches = qa.links = $(s.selector).each(function() { $.data(this,'keywords',(this.innerHTML+$(this).attr('title')).toLowerCase().replace(/[,-\/]/g,' ').replace(/[^a-zA-Z 0-9]+/g,'')); }); // grab links, attach data to match against
</pre>
<p>(Adding &#8220;+$(this).attr(&#8217;title&#8217;)&#8221; to the matched text.)</p>
<p>I&#8217;d love to see a sample page when you get it up and running!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Jason</title>
		<link>http://chapter42.whitewhale.net/2008/06/15/quickaccess/comment-page-1/#comment-18</link>
		<dc:creator>Jason</dc:creator>
		<pubDate>Wed, 18 Jun 2008 20:21:58 +0000</pubDate>
		<guid isPermaLink="false">http://chapter42.whaleblogs.net/?p=50#comment-18</guid>
		<description>Cool stuff Donald! I&#039;m using this in the prototype site that will become our next university website. Rather than embedding additional keywords as comments, how about using the title attribute? What do you think?</description>
		<content:encoded><![CDATA[<p>Cool stuff Donald! I&#8217;m using this in the prototype site that will become our next university website. Rather than embedding additional keywords as comments, how about using the title attribute? What do you think?</p>
]]></content:encoded>
	</item>
</channel>
</rss>

