﻿<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	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/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Girish Gangadharan &#187; PHP</title>
	<atom:link href="http://giri.sh/wp-404-handler.php/category/php/feed/?404;http://giri.sh:80/category/php/feed/" rel="self" type="application/rss+xml" />
	<link>http://giri.sh</link>
	<description>Did you expect something witty here?</description>
	<lastBuildDate>Mon, 26 Jul 2010 20:35:59 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8.4</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>How to set up clean URLs for a Wordpress site in IIS</title>
		<link>http://giri.sh/2008/04/10/how-to-set-up-clean-urls-for-a-wordpress-site-in-iis/</link>
		<comments>http://giri.sh/2008/04/10/how-to-set-up-clean-urls-for-a-wordpress-site-in-iis/#comments</comments>
		<pubDate>Thu, 10 Apr 2008 05:41:44 +0000</pubDate>
		<dc:creator>girish</dc:creator>
				<category><![CDATA[IIS]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[Windows 2003]]></category>
		<category><![CDATA[Wordpress]]></category>

		<guid isPermaLink="false">http://giri.sh/?p=50</guid>
		<description><![CDATA[As promised in the previous post, here&#8217;s what you need to do to get clean URLs for WP in IIS.

Create a new PHP file wp-404-handler.php in the root folder (in case you are not sure, this is the folder that has &#8220;wp-admin&#8221;, &#8220;wp-content&#8221;, &#8220;wp-includes&#8221; sub folders and bunch of other php files ) and copy [...]]]></description>
			<content:encoded><![CDATA[<p>As promised in the previous post, here&#8217;s what you need to do to get clean URLs for WP in IIS.</p>
<ol>
<li>Create a new PHP file wp-404-handler.php in the root folder (in case you are not sure, this is the folder that has &#8220;wp-admin&#8221;, &#8220;wp-content&#8221;, &#8220;wp-includes&#8221; sub folders and bunch of other php files ) and copy paste the following code in it.&lt;?php<br />
$qs = $_SERVER['QUERY_STRING'];<br />
$pos = strrpos($qs, &#8216;://&#8217;);<br />
$pos = strpos($qs, &#8216;/&#8217;, $pos + 4);<br />
$_SERVER['REQUEST_URI'] = substr($qs, $pos);<br />
$_SERVER['PATH_INFO'] = $_SERVER['REQUEST_URI'];<br />
include(&#8217;index.php&#8217;);<br />
?&gt;</li>
<li>Open IIS manager &#8211; Expand local computer &#8211; Expand Web Sites &#8211; Right click on your site &#8211; Click Properties &#8211; Click Custom Errors tab &#8211; Select 404. (See image below)<img src="http://giri.sh/images/custom-errors.png" alt="IIS Website Custom errors tab" width="472" height="458" /></li>
<li>Click Edit &#8211; Set Message Type to &#8220;URL&#8221; and URL to &#8220;/&#8221; (See image below)<img src="http://giri.sh/images/404-edit.png" alt="404 edit properties" width="392" height="230" /></li>
<li>Click OK.</li>
<li>Now login to your WordPress admin control panel. Click Settings and click Permalink (wp-admin/options-permalink.php)</li>
<li>Select &#8220;Custom structure&#8221; and set the text to &#8220;/%year%/%monthnum%/%day%/%postname%/&#8221;</li>
<li>And you are done! Your site should now have clean URLs like this site does.</li>
</ol>
]]></content:encoded>
			<wfw:commentRss>http://giri.sh/2008/04/10/how-to-set-up-clean-urls-for-a-wordpress-site-in-iis/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>How to install and use XFN plugin for textpattern</title>
		<link>http://giri.sh/2006/06/21/how-to-install-and-use-xfn-plugin-for-textpattern/</link>
		<comments>http://giri.sh/2006/06/21/how-to-install-and-use-xfn-plugin-for-textpattern/#comments</comments>
		<pubDate>Thu, 22 Jun 2006 04:19:00 +0000</pubDate>
		<dc:creator>girish</dc:creator>
				<category><![CDATA[PHP]]></category>
		<category><![CDATA[Pet projects]]></category>
		<category><![CDATA[Textpattern]]></category>
		<category><![CDATA[Wordpress]]></category>

		<guid isPermaLink="false">http://morethan2cents.com/morethan2cents/?p=16</guid>
		<description><![CDATA[Step 1: Download the plugins here. gg_linkxfn_v1.0.txt (admin side) gg_linklistxfn_v1.0.txt Since Textpattern is a PHP based CMS, the plugins are written in PHP as well. But these text plugin files don&#8217;t have any plain PHP code in it. The code is actually compiled into a chunk of base64-encoded text, to allow for easy installation and [...]]]></description>
			<content:encoded><![CDATA[<p>Step 1: Download the plugins here. <a href="http://giri.sh/downloads/gg_linkxfn_v1.0.txt">gg_linkxfn_v1.0.txt</a> (admin side) <a href="http://giri.sh/downloads/gg_linklistxfn_v1.0.txt">gg_linklistxfn_v1.0.txt</a> Since Textpattern is a PHP based CMS, the plugins are written in PHP as well. But these text plugin files don&#8217;t have any plain PHP code in it. The code is actually compiled into a chunk of base64-encoded text, to allow for easy installation and minimize corruption problems.</p>
<p>Step 2: Go to your textpattern admin interface usually yourdomainname.com/textpattern/index.php assuming you just did the simple basic installation.  Here&#8217;s what you should see now.  <img src="http://giri.sh/images/start.gif" alt="start" width="600" height="200" /></p>
<p>Step 3: Now click on the admin tab  <img src="http://giri.sh/images/admin.gif" alt="admin" width="600" height="200" /></p>
<p>Step 4: Click on plugins tab  <img src="http://giri.sh/images/plugins.gif" alt="plugins" width="600" height="200" /></p>
<p>Step 5: Now in the textarea beside &#8220;Install plugin&#8221;, copy paste the text from the <a href="http://giri.sh/downloads/gg_linkxfn_v1.0.txt">gg_linkxfn_v1.0.txt</a> (let&#8217;s install the admin side plugin first) and click &#8220;Upload&#8221;.  Textpattern will decode the text for you and spit out the plain PHP code, and then ask you whether you are ready to install it.  <img src="http://giri.sh/images/install.gif" alt="install" width="600" height="200" /></p>
<p>Step 6: Click Install. Now you should be back to the list of plugins under the plugin tab. On the gg_linkxfn plugin row, click on &#8220;No&#8221;(under the &#8220;active&#8221; column) to change it to &#8220;Yes&#8221;, to enable the plugin.  <img src="http://giri.sh/images/enable.gif" alt="enable" width="600" height="200" /></p>
<p>Step 7: That&#8217;s it you are done! Now to see the plugin in action. Click on the content tab. You should see a new tab named &#8220;linkxfn&#8221; under the sub tabs. Click on the new tab.  <img src="http://giri.sh/images/linkxfn.gif" alt="linkxfn" width="800" height="600" /></p>
<p>Step 8: There ya go! All set. Now you can choose your options from the fields, build the relation tag and see it in the &#8220;xfn&#8221; text area. Hit Save and you just have saved the values that will be populated in the &#8220;rel&#8221; attribute when you display the links using <a href="http://giri.sh/downloads/gg_linklistxfn.txt">gg_linklistxfn</a> plugin.</p>
<p>Step 9: Now repeat steps 1 to 7 to install and enable the <a href="http://giri.sh/downloads/gg_linklistxfn.txt">gg_linklistxfn</a> plugin.</p>
<p>Step 10: Here&#8217;s how you use it in your forms or pages.</p>
<pre><code>&lt;txp:if_category&gt;
&lt;txp:gg_linklistxfn form="waw_links" columns="1"
columnwraptag="ul" columnclass="alllinks" listwraptag=""
listclass="" headless="1" headwraptag="h3" argname="c"
category="Friends-and-Colleagues" /&gt;
&lt;txp:else /&gt;
&lt;txp:gg_linklistxfn form="waw_links" columns="1"
columnwraptag="ul" columnclass="alllinks" listwraptag=""
listclass="" headwraptag="h3" headless="1"
category="Friends-and-Colleagues"/&gt;
&lt;/txp:if_category&gt;</code></pre>
<p>Since this plugin is an extension of Manfre&#8217;s <a href="http://manfre.net/project/631/mem-glinklist">mem_glinklist</a> plugin, you can just read how to configure it from his help page. There are no new parameters to add or nothing different about how you use it.</p>
<p>Step 11. Here&#8217;s a demo. Right click on any link on blogroll there and click on properties. You should a relation name-value pair. Check out the screenshot below.  <img src="http://giri.sh/images/properties.png" alt="properties" width="359" height="146" /></p>
<p><strong>UPDATE:</strong> Step above will not work anymore as this site has been upgraded since the time this plugin was written. It runs on <a href="http://wordpress.org">Wordpress</a> now and hence doesn&#8217;t support any textpattern plugins.</p>
<p>Step 12. Most important of all&#8230;..ENJOY!</p>
]]></content:encoded>
			<wfw:commentRss>http://giri.sh/2006/06/21/how-to-install-and-use-xfn-plugin-for-textpattern/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
	</channel>
</rss>
