<?xml version="1.0" encoding="iso-8859-1"?>
<rss version="2.0"
    xmlns:dc="http://purl.org/dc/elements/1.1/"
    xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
    xmlns:admin="http://webns.net/mvcb/"
    xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
    xmlns:content="http://purl.org/rss/1.0/modules/content/">

    <channel>
    
    <title>DevBlog</title>
    <link>http://loweblog.com/</link>
    <description></description>
    <dc:language>nl</dc:language>
    <dc:creator>Low</dc:creator>
    <dc:rights>Copyright 2008</dc:rights>
    <dc:date>2008-05-08T08:54:00+01:00</dc:date>
    <admin:generatorAgent rdf:resource="http://www.pmachine.com/" />
    

    <item>
      <title>EE: Safe Encode extension</title>
      <link>http://loweblog.com/feeder/?FeederAction=clicked&amp;feed=DevBlog+%28rss%29&amp;seed=http%3A%2F%2Floweblog.com%2Ffreelance%2Farticle%2Fee-safe-encode-extension%2F&amp;seed_title=EE%3A+Safe+Encode+extension</link>
      <guid>http://loweblog.com/freelance/article/ee&#45;safe&#45;encode&#45;extension/</guid>
      <description>The Dutch web guidelines do not allow you to use obfuscation to hide email addresses that are published on your site. ExpressionEngine will always use JavaScript to display email addresses when you use the &#123;encode=&#34;&#34;&#125; syntax. With this extension, you can bypass this behaviour, without having to modify the core typography class.</description>
      <dc:subject>add&#45;ons, expressionengine</dc:subject>
      <content:encoded><![CDATA[<p>The <a href="http://www.webrichtlijnen.nl/english/manual/development/production/link-navigation/email-addresses/#addresses-on-sites">Dutch web guidelines</a> do not allow you to use obfuscation to hide email addresses that are published on your site. ExpressionEngine will always use JavaScript to display email addresses when you use the <code>&#123;encode=&#34;&#34;&#125;</code> syntax. With this extension, you can bypass this behaviour, without having to modify the core typography class.</p>
<p><a href="/downloads/ext.safe_encode.php.zip" title="1KB .zip file">&#8594; Download the Safe Encode extension, version 1.0</a></p>
<h2>What does it do?</h2>
<p>Whenever you use <code>&#123;encode=&#34;&#34;&#125;</code> in your weblog entries to display email addresses, this extension will generate an accessible link, instead of the JavaScript generated one. There is hardly any obfuscation, except that the . are replaced with <code>&#38;#46;</code> and the @ is replaced with <code>&#38;#64;</code>. This also means the email address is more likely to be picked up by bots and harvesters, so use at your own risk.</p>
<p>If you&#8217;re using the <code>encode</code>-tag in your templates, this extension will have no effect. But then again, you could just as well not use the <code>encode</code>-tag there.</p>
<h2>Example</h2>
<p>Using the extension, this&#8230;</p>
<pre><code>&#123;encode=&#34;example@domain.com&#34; title=&#34;Send an email&#34;&#125;</code></pre>
<p>&#8230;will be converted to&#8230;</p>
<pre><code>&#60;a href=&#34;mailto:example&#38;#64;domain&#38;#46;com&#34;&#62;Send an email&#60;/a&#62;</code></pre>
]]></content:encoded>
      <dc:date>2008-05-08T08:54:00+01:00</dc:date>
    </item>

    <item>
      <title>EE: Google Mini Plugin</title>
      <link>http://loweblog.com/feeder/?FeederAction=clicked&amp;feed=DevBlog+%28rss%29&amp;seed=http%3A%2F%2Floweblog.com%2Ffreelance%2Farticle%2Fee-google-mini-plugin%2F&amp;seed_title=EE%3A+Google+Mini+Plugin</link>
      <guid>http://loweblog.com/freelance/article/ee&#45;google&#45;mini&#45;plugin/</guid>
      <description>This plugin lets you integrate search results from your Google Mini search appliance (GM) into ExpressionEngine seamlessly. If you&#8217;re using the GM to index your web site or intranet, this plugin will handle the search requests to it, retrieve the search results in XML format, and parses them just the way you want. You don&#8217;t have to learn any XSLT, you don&#8217;t have to leave the domain of your main site, just set up a template and you&#8217;re done.</description>
      <dc:subject>add&#45;ons, expressionengine, searching</dc:subject>
      <content:encoded><![CDATA[<p>This plugin lets you integrate search results from your <a href="http://www.google.com/enterprise/mini/">Google Mini search appliance</a> (GM) into <a href="http://expressionengine.com/index.php?affiliate=lodewijk">ExpressionEngine</a> seamlessly. If you&#8217;re using the GM to index your web site or intranet, this plugin will handle the search requests to it, retrieve the search results in XML format, and parses them just the way you want. You don&#8217;t have to learn any XSLT, you don&#8217;t have to leave the domain of your main site, just set up a template and you&#8217;re done.</p>
<p>&rarr; <a href="/downloads/pi.googlemini.php.zip" title="5KB .zip file">Download the ExpressionEngine Google Mini plugin, version 1.0</a></p>

<ul>
	<li>
		<a href="#gm_results">Search results</a>
		<ul>
			<li><a href="#results_parameters">Parameters</a></li>
			<li><a href="#results_conditionals">Conditionals</a></li>
			<li><a href="#results_variables">Single variables</a></li>
			<li><a href="#results_pairs">Variable pairs</a></li>	
			<li><a href="#results_example">Example</a></li>
		</ul>
	</li>
	<li><a href="#gm_keywords">Keywords</a></li>
	<li><a href="#gm_form">Search form</a></li>
</ul>

<h2 id="gm_results">Search results</h2>

<p>The main tag pair you will need is <code>&#123;exp:googlemini:results&#125;</code>. This contains several single variables and variable pairs that let you set up your search results page.</p>
	
<h3 id="results_parameters">Parameters</h3>

<ul>
	<li><a href="#par_host">host="googlemini.domain.com"</a></li>
	<li><a href="#par_request_parameters">Request Parameters</a></li>
</ul>

<h4 id="par_host">host=</h4>

<pre><code>host="googlemini.domain.com"</code></pre>

<p>The host name assigned to our Google Mini search appliance.</p>

<h4 id="par_request_parameters">Request parameters</h4>

<p>All <a href="http://code.google.com/apis/searchappliance/documentation/46/xml_reference.html#request_parameters">Request Parameters</a> used by the Google Mini search appliance are available. <em>All Request Parameters will be overwritten by GET variables in the url</em>. For example:</p>

<pre><code>client="default_frontend" site="default_collection"</code></pre>

<h3 id="results_conditionals">Conditional variables</h3>

<ul>
	<li><a href="#var_keymatch">&#123;if keymatch&#125;</a></li>
</ul>

<h4 id="var_keymatch">if keymatch</h4>
<pre><code>&#123;if keymatch&#125;
 content
&#123;/if&#125;</code></pre>
<p>This conditional lets you display content if a KeyMatch was found for the current search.</p>

<p><strong>Note:</strong> in addition to these conditionals, all <em>single variables</em> can be used as conditionals as well.</p>

<h3 id="results_variables">Single variables</h3>

<table>
	<caption>Single variables available in the &#123;exp:googlemini:results&#125; tag</caption>
	<colgroup>
		<col class="var" />
		<col class="desc" />
	</colgroup>
	<thead>
		<tr>
			<th scope="col">Variable</th>
			<th scope="col">Description</th>
		</tr>
	</thead>
	<tbody>
		<tr>
			<td>&#123;approx_results&#125;</td>
			<td>The estimated total number of results for the search. See also: <a href="http://code.google.com/apis/searchappliance/documentation/46/xml_reference.html#appendix_num_results">Estimated vs. Actual Number of Results</a></td>
		</tr>
		<tr>
			<td>&#123;current_page&#125;</td>
			<td>Current page number of search results</td>
		</tr>
		<tr>
			<td>&#123;end_result&#125;</td>
			<td>Absolute number of the last search result being displayed</td>
		</tr>
		<tr>
			<td>&#123;keymatch_description&#125;</td>
			<td>KeyMatch description for current search, as indicated in your Google Mini control panel</td>
		</tr>
		<tr>
			<td>&#123;keymatch_url&#125;</td>
			<td>KeyMatch URL for current search, as indicated in your Google Mini control panel</td>
		</tr>
		<tr>
			<td>&#123;keywords&#125;</td>
			<td>Search keywords, HTML-safe</td>
		</tr>
		<tr>
			<td>&#123;keywords_raw&#125;</td>
			<td>Search keywords, unaltered</td>
		</tr>
		<tr>
			<td>&#123;keywords_url&#125;</td>
			<td>Search keywords, URL-safe</td>
		</tr>
		<tr>
			<td>&#123;next_qs&#125;</td>
			<td>Query string to use in a URL to the next page of search results</td>
		</tr>
		<tr>
			<td>&#123;previous_qs&#125;</td>
			<td>Query string to use in a URL to the previous page of search results</td>
		</tr>
		<tr>
			<td>&#123;search_url&#125;</td>
			<td>Complete URL used to fetch the search results from your Google Mini search appliance</td>
		</tr>
		<tr>
			<td>&#123;start_result&#125;</td>
			<td>Absolute number of the first search result being displayed</td>
		</tr>
		<tr>
			<td>&#123;time&#125;</td>
			<td>Time it took for the Google Mini to come up with the search results</td>
		</tr>
		<tr>
			<td>&#123;total_pages&#125;</td>
			<td>Total number of pages with search results, based on the estimated total results (<code>&#123;approx_results&#125;</code>) and the <strong>num</strong> parameter defined in the <a href="#par_request_parameters">Request Parameters</a></td>
		</tr>
		<tr>
			<td>&#123;total_results&#125;</td>
			<td>The total number of search results being displayed</td>
		</tr>
		<tr>
			<td>&#123;total_synonyms&#125;</td>
			<td>Total number of synonyms found for current search</td>
		</tr>
	</tbody>
</table>


<h3 id="results_pairs">Variable pairs</h3>

<ul>
	<li><a href="#var_entries">&#123;entries&#125;</a></li>
	<li><a href="#var_synonyms">&#123;synonyms&#125;</a></li>
	<li><a href="#var_pagination">&#123;pagination&#125;</a></li>
</ul>

<h4 id="var_entries">entries</h4>
<pre><code>&#123;entries&#125;
 &lt;div&#123;if filtered&#125; class=&quot;filtered&quot;&#123;/if&#125;&gt;
  &lt;h3&gt;&lt;a href=&quot;&#123;url&#125;&quot;&gt;&#123;title&#125;&lt;/a&gt;&lt;/h3&gt;
  &lt;p&gt;&#123;excerpt&#125;&lt;/p&gt;
  &lt;p class=&quot;meta&quot;&gt;&#123;display_url&#125;&lt;/p&gt;
 &lt;/div&gt;
&#123;/entries&#125;</code></pre>

<table>
	<caption>Available variables in &#123;entries&#125; tag pair</caption>
	<colgroup>
		<col class="var" />
		<col class="desc" />
	</colgroup>
	<thead>
		<tr>
			<th scope="col">Variable</th>
			<th scope="col">Description</th>
		</tr>
	</thead>
	<tbody>
		<tr>
			<td>&#123;cache_id&#125;</td>
			<td>Cache id of the found page</td>
		</tr>
		<tr>
			<td>&#123;count&#125;</td>
			<td>The count out of the current search results being displayed</td>
		</tr>
		<tr>
			<td>&#123;crawldate&#125;</td>
			<td>The date the page was indexed</td>
		</tr>
		<tr>
			<td>&#123;display_url&#125;</td>
			<td>Stripped down version of the found page</td>
		</tr>
		<tr>
			<td>&#123;encoding&#125;</td>
			<td>Character encoding of the found page</td>
		</tr>
		<tr>
			<td>&#123;excerpt&#125;</td>
			<td>Excerpt of the found page</td>
		</tr>
		<tr>
			<td>&#123;if filtered&#125;</td>
			<td>Displays content if the result was part of a parent directory</td>
		</tr>
		<tr>
			<td>&#123;language&#125;</td>
			<td>Language of the found page</td>
		</tr>
		<tr>
			<td>&#123;more_url&#125;</td>
			<td>URL to use to compose a link to a specific site or directory search using the <code>site:</code> syntax</td>
		</tr>
		<tr>
			<td>&#123;rank&#125;</td>
			<td>Rank assigned to the page by the Google Mini</td>
		</tr>
		<tr>
			<td>&#123;result_number&#125;</td>
			<td>Absolute result number</td>
		</tr>
		<tr>
			<td>&#123;size&#125;</td>
			<td>Size in KB of the found page</td>
		</tr>
		<tr>
			<td>&#123;title&#125;</td>
			<td>Title of the found page</td>
		</tr>
		<tr>
			<td>&#123;url&#125;</td>
			<td>URL of the found page</td>
		</tr>
	</tbody>
</table>

<h4 id="var_synonyms">synonyms</h4>
<pre><code>&#123;synonyms&#125;
 &#123;synonym_count&#125;: &lt;a href=&quot;&#123;synonym_url&#125;&quot;&gt;&#123;synonym_name&#125;&lt;/a&gt;
&#123;/synonyms&#125;</code></pre>

<table>
	<caption>Available variables in &#123;synonyms&#125; tag pair</caption>
	<colgroup>
		<col class="var" />
		<col class="desc" />
	</colgroup>
	<thead>
		<tr>
			<th scope="col">Variable</th>
			<th scope="col">Description</th>
		</tr>
	</thead>
	<tbody>
		<tr>
			<td>&#123;synonym_name&#125;</td>
			<td>Name of the synonym found</td>
		</tr>
		<tr>
			<td>&#123;synonym_url&#125;</td>
			<td>Url of the synonym found</td>
		</tr>
		<tr>
			<td>&#123;synonym_count&#125;</td>
			<td>The count out of the current synonym being displayed</td>
		</tr>
	</tbody>
</table>

<h4 id="var_pagination">pagination</h4>
<pre><code>&#123;pagination&#125;
 &#123;if is_active&#125;
  &lt;strong&gt;&#123;page_count&#125;&lt;/strong&gt;
 &#123;if:else&#125;
  &lt;a href=&quot;&#123;path=search&#125;&#123;query_string&#125;&quot;&gt;&#123;page_count&#125;&lt;/a&gt;
 &#123;/if&#125;
&#123;/pagination&#125;</code></pre>

<table>
	<caption>Available variables in &#123;pagination&#125; tag pair</caption>
	<colgroup>
		<col class="var" />
		<col class="desc" />
	</colgroup>
	<thead>
		<tr>
			<th scope="col">Variable</th>
			<th scope="col">Description</th>
		</tr>
	</thead>
	<tbody>
		<tr>
			<td>&#123;if is_active&#125;</td>
			<td>Conditional variable to display content if current page is active</td>
		</tr>
		<tr>
			<td>&#123;page_count&#125;</td>
			<td>The count out of the current page being displayed</td>
		</tr>
		<tr>
			<td>&#123;query_string&#125;</td>
			<td>The query string used in the URL to navigate to a certain page</td>
		</tr>
	</tbody>
</table>

<h3 id="results_example">Example</h3>

<pre><code>&#123;exp:googlemini:results host=&quot;googlemini.domain.com&quot; oe=&quot;utf8&quot;&#125;
	
&#123;if keywords&#125;
 &lt;p&gt;Searched for &lt;strong&gt;&#123;keywords&#125;&lt;/strong&gt;&lt;br /&gt;
 Results &lt;strong&gt;&#123;start_result&#125; &ndash; &#123;end_result&#125;&lt;/strong&gt; of about &lt;strong&gt;&#123;approx_results&#125;&lt;/strong&gt;.&lt;/p&gt;
&#123;/if&#125;

&#123;if keymatch&#125;
 &lt;p&gt;KeyMatch: &lt;a href=&quot;&#123;keymatch_url&#125;&quot;&gt;&#123;keymatch_description&#125;&lt;/a&gt;&lt;/p&gt;
&#123;/if&#125;

&#123;if total_synonyms&#125;
 &lt;h3&gt;Also try:&lt;/h3&gt;
 &lt;ul&gt;
  &#123;synonyms&#125;
   &lt;li&gt;&lt;a href=&quot;&#123;path=search&#125;?q=&#123;synonym_url&#125;&quot;&gt;&#123;synonym_name&#125;&lt;/a&gt;&lt;/li&gt;
  &#123;/synonyms&#125;
 &lt;/ul&gt;
&#123;/if&#125;

&#123;entries&#125;
 &#123;if count == 1&#125;&lt;ol id=&quot;searchresults&quot;&gt;&#123;/if&#125;
  &lt;li&#123;if filtered&#125; class=&quot;level2&quot;&#123;/if&#125;&gt;
   &lt;h3&gt;&lt;a href=&quot;&#123;url&#125;&quot;&gt;&#123;title&#125;&lt;/a&gt;&lt;/h3&gt;
   &#123;if excerpt&#125;&lt;span class=&quot;excerpt&quot;&gt;&#123;excerpt&#125;&lt;/span&gt;&#123;/if&#125;
   &lt;span class=&quot;meta&quot;&gt;&#123;display_url&#125;&lt;/span&gt;
   &#123;if more_url&#125;&lt;span class=&quot;sitesearch&quot;&gt;[ &lt;a href=&quot;&#123;path=search&#125;?q=site:&#123;more_url&#125;%20&#123;keywords_url&#125;&quot;&gt;More results from &#123;more_url&#125;&lt;/a&gt; ]&lt;/span&gt;&#123;/if&#125;
  &lt;/li&gt;
 &#123;if count == total_results&#125;&lt;/ol&gt;&#123;/if&#125;
&#123;/entries&#125;

&#123;if total_pages &gt; 1&#125;
 &lt;p class=&quot;pagination&quot;&gt;
  &lt;span class=&quot;count&quot;&gt;&#123;current_page&#125;/&#123;total_pages&#125;&lt;/span&gt;
  &#123;if previous_qs&#125;&lt;a class=&quot;prev&quot; href=&quot;&#123;path=search&#125;&#123;previous_qs&#125;&quot;&gt;Previous page&lt;/a&gt;&#123;/if&#125;
  &#123;pagination&#125;&#123;if is_active&#125;&lt;strong&gt;&#123;page_count&#125;&lt;/strong&gt; &#123;if:else&#125;&lt;a href=&quot;&#123;path=search&#125;&#123;query_string&#125;&quot;&gt;&#123;page_count&#125;&lt;/a&gt; &#123;/if&#125;&#123;/pagination&#125;
  &#123;if next_qs&#125;&lt;a class=&quot;next&quot; href=&quot;&#123;path=search&#125;&#123;next_qs&#125;&quot;&gt;Next page&lt;/a&gt;&#123;/if&#125;
 &lt;/p&gt;
&#123;/if&#125;

&#123;/exp:googlemini:results&#125;</code></pre>


<h2 id="gm_keywords">Keywords</h2>
<p>To display keywords outside the results-tags, use the single tag <code>&#123;exp:googlemini:keywords&#125;</code>, for example:</p>
<pre><code>&lt;title&gt;&#123;exp:googlemini:keywords&#125; - Search - My Site Name&lt;/title&gt;</code></pre>


<h2 id="gm_form">Search form</h2>
<p>To create a search form, simply point a form to your search results template and use an input field with <code>name=&quot;q&quot;</code>. For example:</p>
<pre><code>&lt;form action=&quot;&#123;path=search&#125;&quot; method=&quot;get&quot;&gt;
 &lt;fieldset&gt;
  &lt;legend&gt;Search this site&lt;/legend&gt;
  &lt;label for=&quot;keywords&quot;&gt;Keywords&lt;/label&gt;
  &lt;input type=&quot;text&quot; name=&quot;q&quot; id=&quot;keywords&quot; value=&quot;&#123;exp:googlemini:keywords&#125;&quot; /&gt;
  &lt;button type=&quot;submit&quot;&gt;Search&lt;/button&gt;
 &lt;/fieldset&gt;
&lt;/form&gt;</code></pre>


]]></content:encoded>
      <dc:date>2008-03-19T11:28:00+01:00</dc:date>
    </item>

    <item>
      <title>EE search bookmarklet</title>
      <link>http://loweblog.com/feeder/?FeederAction=clicked&amp;feed=DevBlog+%28rss%29&amp;seed=http%3A%2F%2Floweblog.com%2Ffreelance%2Farticle%2Fee-search-bookmarklet%2F&amp;seed_title=EE+search+bookmarklet</link>
      <guid>http://loweblog.com/freelance/article/ee&#45;search&#45;bookmarklet/</guid>
      <description>If you&#8217;re anything like me, you&#8217;d agree that ExpressionEngine&#8217;s search functionality is adequate, but not as good as, say, Google. So, you&#8217;d rather use the latter than the former to search through expressionengine.com. And if you&#8217;re anything like me, you&#8217;re a bit lazy and you like to get repetitive things (like typing in site:expressionengine.com) done quickly. Now you can.</description>
      <dc:subject>bookmarkets, expressionengine, searching</dc:subject>
      <content:encoded><![CDATA[<p>If you&#8217;re anything like me, you&#8217;d agree that <a href="http://www.expressionengine.com/index.php?affiliate=lodewijk">ExpressionEngine</a>&#8217;s search functionality is adequate, but not as good as, say, Google. So, you&#8217;d rather use the latter than the former to search through expressionengine.com. And if you&#8217;re anything like me, you&#8217;re a bit lazy and you like to get repetitive things (like typing in <kbd>site:expressionengine.com</kbd>) done quickly. Now you can.</p>
<p>Drag the following link to your browser&#8217;s toolbar and behold the speediness of bookmarklets (also known as &#8216;favelets&#8217;): <a href="javascript:if(w=prompt('Search%20expressionengine.com:',''))&#123;top.location.href='http://google.com/search?q=site%3Aexpressionengine.com+'+w;&#125;">!ee</a></p>
<p>That will speed up your support searches big time.</p>
]]></content:encoded>
      <dc:date>2007-12-11T20:03:00+01:00</dc:date>
    </item>

    <item>
      <title>Clean up your clean installation</title>
      <link>http://loweblog.com/feeder/?FeederAction=clicked&amp;feed=DevBlog+%28rss%29&amp;seed=http%3A%2F%2Floweblog.com%2Ffreelance%2Farticle%2Fclean-up-your-clean-installation%2F&amp;seed_title=Clean+up+your+clean+installation</link>
      <guid>http://loweblog.com/freelance/article/clean&#45;up&#45;your&#45;clean&#45;installation/</guid>
      <description>When you install ExpressionEngine, it automatically creates some default templates and categories for you, among other things. But since I like my clean installations really spotless, I created some sql queries to clean up your clean install.</description>
      <dc:subject>expressionengine, sql</dc:subject>
      <content:encoded><![CDATA[<p>When you install <a href="http://www.expressionengine.com/index.php?affiliate=lodewijk">ExpressionEngine</a>, it automatically creates some default templates and categories for you, among other things. But since I like my clean installations really spotless, I created some sql queries to clean up your clean install.</p>
<h2>What does it do?</h2>
<p>The queries will truncate some tables and insert some defaults that I work with regularly:</p>
<ul>
<li>Delete all template groups and insert a new one: home</li>
<li>Delete all templates and insert a new one in home: index</li>
<li>Delete all html-buttons and insert buttons for <code>&#60;h2&#62;</code>, <code>&#60;h3&#62;</code>, <code>&#60;strong&#62;</code> and <code>&#60;em&#62;</code>; usually all the formatting an editor would need</li>
<li>Delete all categories and category groups</li>
<li>Delete all weblog entries</li>
<li>Delete all but one weblog fields</li>
</ul>
<p>That&#8217;s it. You could probably do more, but this gives me a great start for new projects.</p>
<h2>The SQL</h2>
<pre><code># get rid of template groups
TRUNCATE TABLE exp_template_groups;
INSERT INTO exp_template_groups (group_id,site_id,group_name,group_order,is_site_default,is_user_blog) VALUES (NULL,'1','home','1','y','n');

# get rid of templates
TRUNCATE TABLE exp_templates;
INSERT INTO exp_templates (template_id,site_id,group_id,template_name,save_template_file,template_type,template_data,template_notes,edit_date,cache,refresh,no_auth_bounce,enable_http_auth,allow_php,php_parse_location,hits) VALUES (NULL,'1','1','index','n','webpage','','','0','n','','','n','n','o','');

# better html buttons
TRUNCATE TABLE exp_html_buttons;
INSERT INTO exp_html_buttons VALUES (1, 1, 0, 'strong', '&#60;strong&#62;', '&#60;/strong&#62;', 'b', 4, '1');
INSERT INTO exp_html_buttons VALUES (2, 1, 0, 'em', '&#60;em&#62;', '&#60;/em&#62;', 'i', 3, '1');
INSERT INTO exp_html_buttons VALUES (3, 1, 0, 'h3', '&#60;h3&#62;', '&#60;/h3&#62;', '3', 2, '1');
INSERT INTO exp_html_buttons VALUES (4, 1, 0, 'h2', '&#60;h2&#62;', '&#60;/h2&#62;', '2', 1, '1');

# no categories please
TRUNCATE TABLE exp_category_posts;
TRUNCATE TABLE exp_categories;
TRUNCATE TABLE exp_category_groups;
TRUNCATE TABLE exp_category_field_data;

# no weblog entries please
TRUNCATE TABLE exp_weblog_titles;
TRUNCATE TABLE exp_weblog_data;
TRUNCATE TABLE exp_weblog_fields;

# just one weblog field
INSERT INTO exp_weblog_fields VALUES (1, 1, 1, 'body', 'Body', '', 'textarea', '', 'n', 0, 0, 'blog', 0, 'date', 'desc', 0, 10, 0, 'n', 'ltr', 'y', 'n', 'xhtml', 'y', 1);
ALTER TABLE exp_weblog_data DROP field_id_2, DROP field_ft_2, DROP field_id_3, DROP field_ft_3;</code></pre>
]]></content:encoded>
      <dc:date>2007-12-02T17:00:00+01:00</dc:date>
    </item>

    <item>
      <title>EE: Title plugin</title>
      <link>http://loweblog.com/feeder/?FeederAction=clicked&amp;feed=DevBlog+%28rss%29&amp;seed=http%3A%2F%2Floweblog.com%2Ffreelance%2Farticle%2Fee-title-plugin%2F&amp;seed_title=EE%3A+Title+plugin</link>
      <guid>http://loweblog.com/freelance/article/ee&#45;title&#45;plugin/</guid>
      <description>This ExpressionEngine plugin lets you retrieve an entry title quickly and effectively. Instead of the default &#123;exp:weblog:entries&#125;&#45;tag with all its parameters, just use this plugin if you only want to display a title. Very useful for breadcrumbs or document &#60;title&#62;s.</description>
      <dc:subject>add&#45;ons, expressionengine</dc:subject>
      <content:encoded><![CDATA[<p>This <a href="http://www.expressionengine.com/index.php?affiliate=lodewijk">ExpressionEngine</a> plugin lets you retrieve an entry title quickly and effectively. Instead of the default <code>&#123;exp:weblog:entries&#125;</code>-tag with all its parameters, just use this plugin if you only want to display a title. Very useful for breadcrumbs or document <code>&#60;title&#62;</code>s.</p>
<p><a href="/downloads/pi.title.zip" title="1.9KB .zip file">&#8594; Download the Title plugin, version 1.1</a></p>
<p>By default, the plugin will output a title, formatted with <a href="http://expressionengine.com/downloads/details/xhtml_typography/">xhtml light</a> (you don&#8217;t need that plugin, by the way). In some cases, you can use the <code>custom_field</code>-parameter to display a custom field of your choice instead of the title, which could be useful for multilingual sites. The closing tag is not required.</p>
<h2>Entry title</h2>
<p><code>&#123;exp:title:entry&#125;</code>: Get the title for a weblog entry.</p>
<h3>Parameters</h3>
<ul>
<li><code>entry_id</code></li>
<li><code>url_title</code></li>
<li><code>weblog_id</code></li>
<li><code>weblog</code> (the short name of a weblog)</li>
<li><code>custom_field</code> (the short name of a custom field)</li>
<li><code>show_error</code> (only in combination with the <code>custom_field</code> parameter, defaults to &#8220;no&#8221;)</li>
</ul>
<h3>Examples</h3>
<pre><code>&#123;exp:title:entry entry_id="15"&#125;
&#123;exp:title:entry url_title="&#123;segment_2&#125;" weblog="default_site"&#125;
&#123;exp:title:entry url_title="&#123;segment_3&#125;" custom_field="title_&#123;language&#125;"&#125;</code></pre>
<h2>Category title</h2>
<p><code>&#123;exp:title:category&#125;</code>: Get the category name for a category.</p>
<h3>Parameters</h3>
<ul>
<li><code>category_id</code></li>
<li><code>url_title</code></li>
<li><code>category_group</code></li>
<li><code>custom_field</code> (the short name of a custom field)</li>
<li><code>show_error</code> (only in combination with the <code>custom_field</code> parameter, defaults to &#8220;no&#8221;)</li>
</ul>
<h3>Examples</h3>
<pre><code>&#123;exp:title:category category_id="18"&#125;
&#123;exp:title:category category_id="C24"&#125;
&#123;exp:title:category url_title="&#123;segment_4&#125;" category_group="1"&#125;
&#123;exp:title:category url_title="&#123;segment_3&#125;" custom_field="title_&#123;language&#125;"&#125;</code></pre>
<p>As you can see, you can use <code>C24</code> as input for the <code>category_id</code> parameter. The C will be ignored.</p>
<h2>Weblog title</h2>
<p><code>&#123;exp:title:weblog&#125;</code>: Get the title for a weblog.</p>
<h3>Parameters</h3>
<ul>
<li><code>weblog_id</code></li>
<li><code>weblog_name</code></li>
</ul>
<h3>Examples</h3>
<pre><code>&#123;exp:title:weblog weblog_id="3"&#125;
&#123;exp:title:weblog weblog_name="&#123;segment_1&#125;"&#125;</code></pre>
<h2>Site title</h2>
<p><code>&#123;exp:title:site&#125;</code>: Get the title for a site.</p>
<h3>Parameters</h3>
<ul>
<li><code>site_id</code></li>
<li><code>site_name</code></li>
</ul>
<h3>Examples</h3>
<pre><code>&#123;exp:title:site site_id="1"&#125;
&#123;exp:title:site site_name="&#123;segment_1&#125;"&#125;</code></pre>
<h2>New in version 1.1 &#8211; 2007.11.12</h2>
<ul>
<li>Added category title</li>
<li>Added weblog title</li>
<li>Added site title</li>
</ul>
]]></content:encoded>
      <dc:date>2007-08-06T12:33:00+01:00</dc:date>
    </item>

    <item>
      <title>Multiple Rick Birthday Contest</title>
      <link>http://loweblog.com/feeder/?FeederAction=clicked&amp;feed=DevBlog+%28rss%29&amp;seed=http%3A%2F%2Floweblog.com%2Ffreelance%2Farticle%2Fmultiple-rick-birthday-contest%2F&amp;seed_title=Multiple+Rick+Birthday+Contest</link>
      <guid>http://loweblog.com/freelance/article/multiple&#45;rick&#45;birthday&#45;contest/</guid>
      <description>It was Rick Ellis&#8217; birthday the other day, and there&#8217;s a new version of ExpressionEngine coming up, so his colleagues came up with a nice little contest: take any of the given pictures of the EllisLab CEO and use them as you see fit. So, without any further ado, here&#8217;s my shot at free EE goodies!</description>
      <dc:subject>contest, expressionengine</dc:subject>
      <content:encoded><![CDATA[<p>It was Rick Ellis&#8217; birthday the other day, and there&#8217;s a new version of <a href="http://expressionengine.com/index.php?affiliate=lodewijk">ExpressionEngine</a> coming up, so his colleagues came up with <a href="http://expressionengine.com/blog/entry/160_preview_and_multiple_rick_manager_birthday_contest/">a nice little contest</a>: take any of the given pictures of the EllisLab CEO and use them as you see fit. So, without any further ado, here&#8217;s my shot at free EE goodies!</p>
<p><img src="http://loweblog.com/images/monty-ellis.png" width="360" height="254" alt="Rick Ellis: I'm a CEO and I'm okay!" />
</p>]]></content:encoded>
      <dc:date>2007-06-18T19:30:00+01:00</dc:date>
    </item>

    <item>
      <title>EE: Nice Date plugin</title>
      <link>http://loweblog.com/feeder/?FeederAction=clicked&amp;feed=DevBlog+%28rss%29&amp;seed=http%3A%2F%2Floweblog.com%2Ffreelance%2Farticle%2Fee-nice-date-plugin%2F&amp;seed_title=EE%3A+Nice+Date+plugin</link>
      <guid>http://loweblog.com/freelance/article/ee&#45;nice&#45;date&#45;plugin/</guid>
      <description>This ExpressionEngine plugin takes a certain date and format and outputs the given date in the given format, localized or not. This is particularly useful when you use dates in the url and you don&#8217;t want to use a &#123;exp:weblog:entries&#125; tag to display it in a nice way. Go on, have a Nice Date.</description>
      <dc:subject>add&#45;ons, expressionengine</dc:subject>
      <content:encoded><![CDATA[<p>This ExpressionEngine plugin takes a certain date and format and outputs the given date in the given format, localized or not. This is particularly useful when you use dates in the url and you don&#8217;t want to use a <code>&#123;exp:weblog:entries&#125;</code> tag to display it in a nice way. Go on, have a Nice Date.</p>
<p><a href="/downloads/pi.nice_date.php.zip">&#8594; Download the Nice Date plugin, version 1.0</a></p>
<h2>Parameters</h2>
<ul>
<li><code>date</code> (any date string)</li>
<li><code>format</code> (just like the <a href="http://expressionengine.com/docs/templates/date_variable_formatting.html">Date Variable Formatting</a>)</li>
<li><code>localize</code> (<code>yes</code> or <code>no</code>, defaults to <code>no</code>)</li>
</ul>
<h2>Examples</h2>
<pre><code>&#123;exp:nice_date date="2007-05-20" format="%F %j%S, %Y" localize="yes"&#125;</code></pre>
<p>This will output something like <em>May 20th, 2007</em>.</p>
<pre><code>&#123;exp:nice_date date="&#123;segment_3&#125;-&#123;segment_4&#125;-01" format="%F %Y"&#125;</code></pre>
<p>For a url like <code>http://www.domain.com/index.php/blog/archive/2007/05/</code>, this will output <em>May 2007</em>.</p>
]]></content:encoded>
      <dc:date>2007-05-06T13:17:00+01:00</dc:date>
    </item>

    <item>
      <title>Ajax Archives in ExpressionEngine</title>
      <link>http://loweblog.com/feeder/?FeederAction=clicked&amp;feed=DevBlog+%28rss%29&amp;seed=http%3A%2F%2Floweblog.com%2Ffreelance%2Farticle%2Fajax-archives-in-expressionengine%2F&amp;seed_title=Ajax+Archives+in+ExpressionEngine</link>
      <guid>http://loweblog.com/freelance/article/ajax&#45;archives&#45;in&#45;expressionengine/</guid>
      <description>Ever since the Ajax hype began, there&#8217;s been talk about its proper use. Yes, with great power comes great responsibility, so you should think twice before you sprinkle Ajax fairy dust over your web site. But that doesn&#8217;t mean you shouldn&#8217;t use it at all. There are several places where I think it could be quite suitable. For example: browsing through blog archives, like mine.</description>
      <dc:subject>ajax, archives, expressionengine, javascript, mootools</dc:subject>
      <content:encoded><![CDATA[<p>Ever since the Ajax hype <a href="http://www.adaptivepath.com/publications/essays/archives/000385.php">began</a>, there&#8217;s been talk about its <a href="http://www.brothercake.com/presentations/what_has_ajax_done/">proper use</a>. Yes, with great power comes great responsibility, so you should think twice before you sprinkle Ajax fairy dust over your web site. But that doesn&#8217;t mean you shouldn&#8217;t use it at all. There are several places where I think it could be quite suitable. For example: browsing through blog archives, <a href="http://loweblog.com/archives/">like mine</a>.</p>
<p>Instead of clicking a month, waiting for the page to load, look through the entries, click Back, repeat, rinse, etc, you can now get served almost immediately. So, how to go about and do this, you ask? Let me explain.</p>
<h2>Create your templates</h2>
<p>First of all, make sure your archives work <em>without</em> all the fancy stuff. Create your list of archive links with either the <a href="http://expressionengine.com/docs/modules/weblog/archive_month_links.html">Archive Month Links Tag</a> or my own <a href="http://loweblog.com/archive/2006/03/03/ee-yearly-archives-plugin/">Yearly Archives plugin</a>, and make sure those links work. Also, make sure your list has a specific id &#8212; for example: &#8220;ya&#8221; &#8212; so we can refer to it later on. Once that&#8217;s done, we can begin progressive enhancement.</p>
<p>In a separate template, put your weblog entries that you&#8217;re going to retrieve with Ajax. This should be a very basic template: you&#8217;re going to use its output to refresh your normal archives page. Something like this:</p>
<pre><code>&#60;ul&#62;&#123;exp:weblog:entries weblog=&#34;blog&#34; display_by=&#34;month&#34; sort=&#34;asc&#34; disable=&#34;custom_fields&#124;member_data&#124;pagination&#124;trackbacks&#124;categories&#34;&#125;
 &#60;li&#62;&#123;entry_date format=&#34;%d&#34;&#125;: &#60;a href=&#34;&#123;url_title_path=blog/entry&#125;&#34;&#62;&#123;title&#125; (&#123;comment_total&#125;)&#60;/a&#62;&#60;/li&#62;&#123;/exp:weblog:entries&#125;
&#60;/ul&#62;</code></pre>
<h2>Add some JavaScript</h2>
<p>I&#8217;m not going to start a discussion about JavaScript libraries here. In this case I&#8217;m using <a href="http://mootools.net/">Mootools v1.00</a>, which gives me an excellent start to work with. For the actual magic to happen, you need a custom script. I prefer to <a href="http://www.digital-web.com/articles/objectifying_javascript/">objectify my JavaScript</a>, which means you could start like this:</p>
<pre><code>var YA = new Object();</code></pre>
<p>We&#8217;ve just created an object called YA (as in Yearly Archives), that we&#8217;re going to extend with several functions.</p>
<h3>YA.init</h3>
<pre><code>YA.init = function() &#123;
 window.addEvent('domready',function() &#123;
  if (!$('ya')) return;
  YA.build();
  $$('#ya a').each(function(el) &#123;
   el.addEvent('click', YA.get);
  &#125;);
 &#125;);
&#125;</code></pre>
<p>The <code>init</code> function adds an anonymous function to the domready-event, which will fire as soon as the DOM is ready (duh). The anonymous function checks if an element with id &#8220;ya&#8221; exists, executes <code>YA.build()</code> and adds the function <code>YA.get()</code> to the <code>onclick</code> event of each anchor in the ya-element.</p>
<h3>YA.build</h3>
<pre><code>YA.build = function() &#123;
 // create result div
 this.container    = new Element('div');
 this.container.id = 'ajaxresult';
 this.container.injectAfter($('ya'));

 // create throbber
 this.throbber = new Throbber('throb-target');
&#125;</code></pre>
<p>The <code>build</code> function creates a <code>div</code>-element. This element will be filled with the archive entries: it&#8217;s the container for the results. After it&#8217;s created, it&#8217;s inserted immediately after the ya-element. Secondly, a throbber is created to indicate activity. I&#8217;m using <a href="http://loweblog.com/freelance/article/easy-throbbing/">my own Throbber class</a> for that one.</p>
<h3>YA.get</h3>
<pre><code>YA.get = function(ev) &#123;
 var ev = new Event(ev);
 if (ev.shift &#124;&#124; ev.control &#124;&#124; ev.alt &#124;&#124; ev.meta) return;
 YA.throbber.on();
 YA.load(ev.target.href);
 ev.preventDefault();
&#125;</code></pre>
<p>The <code>get</code> function is fired each time an anchor in your archive list is clicked. The script aborts if a key was pressed simultaneously. It then turns the throbber on, tells our <code>YA</code> object to load the entries linked by the anchor and prevents the default action from happening.</p>
<h3>YA.load</h3>
<pre><code>YA.load = function(url) &#123;
 var url = url.replace('group/template','group/basic-template');
 new Ajax(url,&#123;
  onComplete:function(r)&#123;
   YA.container.setHTML(r);
   YA.throbber.off();
  &#125;
 &#125;).request();
&#125;</code></pre>
<p>The <code>load</code> function is responsible for the Ajax request. First, we need to modify the url so it points to our basic template, instead of the full archive template. Change the <code>group/template</code> and <code>group/basic-template</code> bits to whatever works for you. We then call the Mootools Ajax class and add an anonymous function to its <code>onComplete</code> parameter, which will insert the results into the container we created with <code>YA.build</code> and turns off the throbber.</p>
<h2>That&#8217;s it!</h2>
<p>Or is it? There&#8217;s only one step left: execute the <code>init</code> function, thus:</p>
<pre><code>YA.init();</code></pre>
<p>Now we&#8217;re done. Want to see it in action? Check out <a href="http://loweblog.com/archives/">my archives</a>. They&#8217;re in Dutch though, but the effect is the same.</p>
]]></content:encoded>
      <dc:date>2007-04-10T22:29:00+01:00</dc:date>
    </item>

    <item>
      <title>Last segment: a global variable</title>
      <link>http://loweblog.com/feeder/?FeederAction=clicked&amp;feed=DevBlog+%28rss%29&amp;seed=http%3A%2F%2Floweblog.com%2Ffreelance%2Farticle%2Flast-segment-a-global-variable%2F&amp;seed_title=Last+segment%3A+a+global+variable</link>
      <guid>http://loweblog.com/freelance/article/last&#45;segment&#45;a&#45;global&#45;variable/</guid>
      <description>As you might know, ExpressionEngine uses segments to access information in your URLs. These segment variables are available throughout your templates and are useful for conditionals, other EE tags, and a whole lot more. Retrieving an absolute segment is easy. Retrieving a relative segment, like the last one? Not so much. Path.php global variables to the rescue!</description>
      <dc:subject>expressionengine, path&#45;php, segments</dc:subject>
      <content:encoded><![CDATA[<p>As you might know, <a href="http://www.expressionengine.com/index.php?affiliate=lodewijk&#38;page=/ee/">ExpressionEngine</a> uses <a href="http://eedocs.expressionengine.com/templates/globals/url_segments.html">segments</a> to access information in your URLs. These segment variables are available throughout your templates and are useful for conditionals, other EE tags, and a whole lot more. Retrieving an absolute segment is easy. Retrieving a relative segment, like the last one? Not so much. <a href="http://eedocs.expressionengine.com/templates/globals/pathphp_globals.html">Path.php global variables</a> to the rescue!</p>
<h3>Path to relativity</h3>
<p>You can define any number of variables in your path.php file, which will be globally available, just like the standard URL segment variables. This means we can also define a <code>&#123;last_segment&#125;</code> variable, if we add some clever code.</p>
<pre><code>function getLastSegment($uri)
&#123;
 if (!strlen($uri)) return '';

 if (substr($uri,-1,1) == '/')
 &#123;
  $uri = substr($uri,0,-1);
 &#125;

 return substr($uri,(strrpos($uri, '/')+1));
&#125;</code></pre>
<p>At the bottom of your path.php file (but before the <code>?&#62;</code>) add the above function. This function will check <code>$uri</code> &#8212; a variable created by the index.php file and available for use &#8212; for the last segment, after stripping a possible trailing slash. Now you only have to call the function to retrieve your last segment. Add it to the <code>$global_vars</code> array.</p>
<pre><code>$global_vars['last_segment'] = getLastSegment($uri);</code></pre>
<p>Presto, you&#8217;re done! Just use <code>&#123;last_segment&#125;</code> anywhere in your templates and experience the joy of relative segment variables.</p>
]]></content:encoded>
      <dc:date>2007-01-08T15:20:00+01:00</dc:date>
    </item>

    <item>
      <title>Easy throbbing</title>
      <link>http://loweblog.com/feeder/?FeederAction=clicked&amp;feed=DevBlog+%28rss%29&amp;seed=http%3A%2F%2Floweblog.com%2Ffreelance%2Farticle%2Feasy-throbbing%2F&amp;seed_title=Easy+throbbing</link>
      <guid>http://loweblog.com/freelance/article/easy&#45;throbbing/</guid>
      <description>When using Ajax techniques, you can use a throbber to let the user know that something is being done on the background. This throbber &#8212; usually an animated gif &#8212; is either shown or hidden when an Ajax call is initiated or finished. Using CSS to accomplish this is one option, but I prefer to add and remove the image from the DOM entirely. In this example, I&#8217;ll explain how you can use a Throbber class in JavaScript to create your indicators, and turn them on or off without contaminating your DOM.</description>
      <dc:subject>ajax, dom, javascript, mootools</dc:subject>
      <content:encoded><![CDATA[<p>When using Ajax techniques, you can use a <a href="http://en.wikipedia.org/wiki/Throbber">throbber</a> to let the user know that something is being done on the background. This throbber &#8212; usually an animated gif &#8212; is either shown or hidden when an Ajax call is initiated or finished. Using <abbr>CSS</abbr> to accomplish this is one option, but I prefer to add and remove the image from the <acronym>DOM</acronym> entirely. In this example, I&#8217;ll explain how you can use a Throbber class in JavaScript to create your indicators, and turn them on or off without contaminating your <acronym>DOM</acronym>.</p>
<h3>What&#8217;s this? A library?</h3>
<p>Well, yes. It is. I&#8217;m using the compact JavaScript framework <a href="http://mootools.net/">Mootools</a> to make things easier. There&#8217;s nothing stopping you from altering my example to a library independent version, though&#8230; Enough with the small talk, let&#8217;s get crackin&#8217;!</p>
<pre><code>var Throbber = new Class(&#123;
 initialize : function (target) &#123;
  this.target  = $(target);
  this.status  = 0;
  this.img     = new Element('img');
  this.img.src = arguments[1] &#124;&#124; '/images/throbber.gif';
 &#125;,

 on : function() &#123;
  if (this.status == 0) &#123;
   this.target.appendChild(this.img);
   this.status = 1;
  &#125;
 &#125;,

 off : function() &#123;
  if (this.status == 1) &#123;
   try &#123; $(this.img).remove(); &#125; catch(x) &#123; &#125;
   this.status = 0;
  &#125;
 &#125;,

 toggle : function() &#123;
  if (this.status)
   this.off();
  else
   this.on();
 &#125;
&#125;);</code></pre>
<p>Let&#8217;s go through the code, shall we? First of all, we define our new throbber class: <code>var Throbber = new Class();</code>. The <code>initialize</code> method will be executed upon class instantiation. In this case, we&#8217;ll need a target element to put the throbber, the status is set to <code>0</code> and an <code>img</code> element is created. The source of this image is either the second (optional) argument, or the default source: <code>/images/throbber.gif</code>.</p>
<p>The <code>on</code> method will append the image to its target and set the status to <code>1</code>. The <code>off</code> method will remove the image from the DOM, if it&#8217;s not already gone (for example by an <code>innerHTML</code> call). The <code>toggle</code> method will either execute the <code>on</code> or <code>off</code> method, depending on the status.</p>
<p>That&#8217;s all there is to it! We&#8217;re now ready to put this baby in action.</p>
<h3>Examples</h3>
<p>Basic usage is easy. Just instantiate the class, giving at least one argument: the id of the target element, and turn your throbber on and off by using its methods. With Ajax calls, you can turn it on right before you make the call and turn it off as soon as the call is finished.</p>
<pre><code>var throb = new Throbber('throb-holder');
throb.on();
// some more code
throb.off();</code></pre>
<p>Check out <a href="http://loweblog.com/examples/throbber.html">this straight forward working example</a>, which demonstrates the <code>toggle</code> method.</p>
<h3>Need more control?</h3>
<p>I chose to keep this class simple, but for extra control you could extend it by adding some attributes to the throbber image, like <code>alt</code>, <code>class</code> or <code>id</code>. Then use some clever CSS rules to display the throbber exactly how you like it.</p>
]]></content:encoded>
      <dc:date>2006-12-20T15:40:00+01:00</dc:date>
    </item>

    
    </channel>
</rss>