<?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>Anil Konsal</title>
	<atom:link href="http://anilkonsal.com/feed" rel="self" type="application/rss+xml" />
	<link>http://anilkonsal.com</link>
	<description></description>
	<lastBuildDate>Wed, 02 Nov 2011 07:49:59 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.2.1</generator>
		<item>
		<title>Page not found in pagination on Category Page in WordPress</title>
		<link>http://anilkonsal.com/page-not-found-in-pagination-on-category-page-in-wordpress</link>
		<comments>http://anilkonsal.com/page-not-found-in-pagination-on-category-page-in-wordpress#comments</comments>
		<pubDate>Wed, 02 Nov 2011 07:49:29 +0000</pubDate>
		<dc:creator>Anil Konsal</dc:creator>
				<category><![CDATA[WordPRess]]></category>

		<guid isPermaLink="false">http://anilkonsal.com/?p=105</guid>
		<description><![CDATA[If I set the value of posts_per_page variable on query_posts to a lower value than that set on the settings page than I will get the 404 error. Example: settings set to 10 posts per page [$ppp = get_option('posts_per_page') will &#8230; <a href="http://anilkonsal.com/page-not-found-in-pagination-on-category-page-in-wordpress">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>If I set the value of posts_per_page variable on query_posts to a lower value than that set on the settings page than I will get the 404 error.<br />
Example: settings set to 10 posts per page [$ppp = get_option('posts_per_page') will echo 10]<br />
posts_per_page set to 3 on query_posts<br />
If I have a total of 9 posts on my wordpress database then, with the settings above, page two will not show and I get the 404 error!</p>
]]></content:encoded>
			<wfw:commentRss>http://anilkonsal.com/page-not-found-in-pagination-on-category-page-in-wordpress/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Teaching WordPress is a good experience.</title>
		<link>http://anilkonsal.com/teaching-wordpress-is-a-good-experience</link>
		<comments>http://anilkonsal.com/teaching-wordpress-is-a-good-experience#comments</comments>
		<pubDate>Tue, 18 Oct 2011 09:58:00 +0000</pubDate>
		<dc:creator>Anil Konsal</dc:creator>
				<category><![CDATA[Family]]></category>

		<guid isPermaLink="false">http://anilkonsal.com/?p=90</guid>
		<description><![CDATA[Teaching WordPress is a good experience.]]></description>
			<content:encoded><![CDATA[<p>Teaching WordPress is a good experience.</p>
]]></content:encoded>
			<wfw:commentRss>http://anilkonsal.com/teaching-wordpress-is-a-good-experience/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Canvas Padded thumbnails using PHP and GD in Zend Framework Application</title>
		<link>http://anilkonsal.com/canvas-padded-thumbnails-using-php-and-gd-in-zend-framework-application</link>
		<comments>http://anilkonsal.com/canvas-padded-thumbnails-using-php-and-gd-in-zend-framework-application#comments</comments>
		<pubDate>Fri, 07 Oct 2011 12:31:21 +0000</pubDate>
		<dc:creator>Anil Konsal</dc:creator>
				<category><![CDATA[Zend Framework]]></category>

		<guid isPermaLink="false">http://anilkonsal.com/?p=86</guid>
		<description><![CDATA[function showThumbnail($imageFileName='', $width='', $height='', $cwidth='', $cheight='') { $cfg = new Zend_Config_Ini(APPLICATION_PATH.'/configs/application.ini', 'production'); $path = $cfg->resources->frontController->imageupload->path; $publicpath = $cfg->resources->frontController->imageupload->publicpath; $pi = pathinfo($imageFileName); $filename = $pi['filename']; $ext = $pi['extension']; $thumbname = $filename.'-'.$width.'X'.$height.'.'.$ext; $fspath = APPLICATION_PATH.'/..'.$path.'/'.$imageFileName; $fspathThumb = APPLICATION_PATH.'/..'.$path.'/'.$thumbname; if(!file_exists($fspathThumb)) { thumb($fspath, $width, &#8230; <a href="http://anilkonsal.com/canvas-padded-thumbnails-using-php-and-gd-in-zend-framework-application">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p><code><br />
function showThumbnail($imageFileName='', $width='', $height='', $cwidth='', $cheight='')<br />
{<br />
	$cfg = new Zend_Config_Ini(APPLICATION_PATH.'/configs/application.ini', 'production');<br />
	$path = $cfg->resources->frontController->imageupload->path;<br />
	$publicpath = $cfg->resources->frontController->imageupload->publicpath;</p>
<p>	$pi = pathinfo($imageFileName);<br />
	$filename = $pi['filename'];<br />
	$ext = $pi['extension'];</p>
<p>	$thumbname = $filename.'-'.$width.'X'.$height.'.'.$ext;</p>
<p>	$fspath = APPLICATION_PATH.'/..'.$path.'/'.$imageFileName;<br />
	$fspathThumb = APPLICATION_PATH.'/..'.$path.'/'.$thumbname;</p>
<p>	if(!file_exists($fspathThumb)) {<br />
		thumb($fspath, $width, $height, $cwidth, $cheight, $fspathThumb);<br />
	}</p>
<p>	return $publicpath.'/'.$thumbname;<br />
}</p>
<p>function thumb($img, $w, $h, $cw='', $ch='', $thumb, $fill='') {<br />
	if (!extension_loaded('gd') &#038;&#038; !extension_loaded('gd2')) {<br />
		trigger_error("No dispones de la libreria GD para generar la imagen.", E_USER_WARNING);<br />
		return false;<br />
	}</p>
<p>	$imgInfo = getimagesize($img);<br />
	switch ($imgInfo[2]) {<br />
		case 1: $im = imagecreatefromgif($img); break;<br />
		case 2: $im = imagecreatefromjpeg($img);  break;<br />
		case 3: $im = imagecreatefrompng($img); break;<br />
		default:  trigger_error('Tipo de imagen no reconocido.', E_USER_WARNING);  break;<br />
	}</p>
<p>	if ($imgInfo[0] <= $w &#038;&#038; $imgInfo[1] <= $h) {<br />
		$nHeight = $imgInfo[1];<br />
		$nWidth = $imgInfo[0];<br />
	}else{<br />
		if ($w/$imgInfo[0] < $h/$imgInfo[1]) {<br />
			$nWidth = $w;<br />
			$nHeight = $imgInfo[1]*($w/$imgInfo[0]);<br />
			$ny = ($h - $nHeight)/2;<br />
		}else{<br />
			$nWidth = $imgInfo[0]*($h/$imgInfo[1]);<br />
			$nHeight = $h;<br />
			$nx = ($w - $nWidth)/2;<br />
		}<br />
	}</p>
<p>	$nWidth = round($nWidth);<br />
	$nHeight = round($nHeight);</p>
<p>	$newImg = imagecreatetruecolor($nWidth, $nHeight);<br />
	$newImg = imagecreatetruecolor($w, $h);<br />
	$fillColor = imagecolorallocate($newImg, 0xFF, 0xFF, 0xFF);<br />
	imagefill($newImg, 0, 0, $fillColor);</p>
<p>	imagecopyresampled($newImg, $im, $nx, $ny, 0, 0, $nWidth, $nHeight, $imgInfo[0], $imgInfo[1]);</p>
<p>	switch ($imgInfo[2]) {<br />
		case 1: imagegif($newImg , $thumb); break;<br />
		case 2: imagejpeg($newImg, $thumb);  break;<br />
		case 3: imagepng($newImg, $thumb); break;<br />
		default:  trigger_error('Imposible mostrar la imagen.', E_USER_WARNING);  break;<br />
	}</p>
<p>	imagedestroy($newImg);<br />
}</p>
<p></code></p>
]]></content:encoded>
			<wfw:commentRss>http://anilkonsal.com/canvas-padded-thumbnails-using-php-and-gd-in-zend-framework-application/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>SVN Post Commit hook</title>
		<link>http://anilkonsal.com/svn-post-commit-hook</link>
		<comments>http://anilkonsal.com/svn-post-commit-hook#comments</comments>
		<pubDate>Sun, 02 Oct 2011 06:47:19 +0000</pubDate>
		<dc:creator>Anil Konsal</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[Subversion]]></category>

		<guid isPermaLink="false">http://anilkonsal.com/?p=80</guid>
		<description><![CDATA[Some days ago, I got a requirement of giving access to 3 users to my SVN repo over ssh. #groupadd dev #useradd -g dev auser #useradd -g dev buser #useradd -g dev cuser Then set the passwords for each user. &#8230; <a href="http://anilkonsal.com/svn-post-commit-hook">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Some days ago, I got a requirement of giving access to 3 users to my SVN repo over ssh.<br />
<code><br />
#groupadd dev<br />
#useradd -g dev auser<br />
#useradd -g dev buser<br />
#useradd -g dev cuser<br />
</code><br />
Then set the passwords for each user.</p>
<p>For SVN, update changes, you need to have the working copy owned by dev group<br />
<code><br />
#chmod 0775 -R myworkingcopy<br />
#chown -R apache:dev myworkingcopy<br />
</code><br />
For svn post commit hook<br />
<code><br />
#chown apache:dev post-commit<br />
#chmod 0755 post-commit<br />
</code><br />
The point here is that the user committing the changes should have the write permissions to the working copy and execute permissions on the post-commit hook</p>
<p>and all is good.</p>
]]></content:encoded>
			<wfw:commentRss>http://anilkonsal.com/svn-post-commit-hook/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>MVC .htaccess with exclusion of .html files</title>
		<link>http://anilkonsal.com/mvc-htaccess-with-exclusion-of-html-files</link>
		<comments>http://anilkonsal.com/mvc-htaccess-with-exclusion-of-html-files#comments</comments>
		<pubDate>Tue, 30 Aug 2011 06:41:27 +0000</pubDate>
		<dc:creator>Anil Konsal</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://anilkonsal.com/?p=76</guid>
		<description><![CDATA[RewriteEngine on RewriteRule ^\.htaccess$ - [F] RewriteRule ^(.*)\.html$ - [L] RewriteCond %{REQUEST_URI} ="" RewriteRule ^.*$ /public/index.php [NC,L] RewriteCond %{REQUEST_URI} !^/public/.*$ RewriteRule ^(.*)$ /public/$1 RewriteCond %{REQUEST_FILENAME} -f RewriteRule ^.*$ - [NC,L] RewriteRule ^public/.*$ /public/index.php [NC,L]]]></description>
			<content:encoded><![CDATA[<p><code><br />
<code><br />
RewriteEngine on</p>
<p>RewriteRule ^\.htaccess$ - [F]<br />
RewriteRule ^(.*)\.html$ - [L]<br />
RewriteCond %{REQUEST_URI} =""<br />
RewriteRule ^.*$ /public/index.php [NC,L]</p>
<p>RewriteCond %{REQUEST_URI} !^/public/.*$<br />
RewriteRule ^(.*)$ /public/$1</p>
<p>RewriteCond %{REQUEST_FILENAME} -f</p>
<p>RewriteRule ^.*$ - [NC,L]<br />
RewriteRule ^public/.*$ /public/index.php [NC,L]<br />
</code><br />
</code></p>
]]></content:encoded>
			<wfw:commentRss>http://anilkonsal.com/mvc-htaccess-with-exclusion-of-html-files/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Zend Framework Project .htaccess with exclusion of folders</title>
		<link>http://anilkonsal.com/zend-framework-project-htaccess-with-exclusion-of-folders</link>
		<comments>http://anilkonsal.com/zend-framework-project-htaccess-with-exclusion-of-folders#comments</comments>
		<pubDate>Tue, 30 Aug 2011 06:05:41 +0000</pubDate>
		<dc:creator>Anil Konsal</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://anilkonsal.com/?p=71</guid>
		<description><![CDATA[Options +FollowSymLinks RewriteEngine on RewriteRule ^\.htaccess$ - [F] RewriteRule ^(blog&#124;forum)($&#124;/) - [L] RewriteCond %{REQUEST_URI} ="" RewriteRule ^.*$ /public/index.php [NC,L] RewriteCond %{REQUEST_URI} !^/public/.*$ RewriteRule ^(.*)$ /public/$1 RewriteCond %{REQUEST_FILENAME} -f RewriteRule ^.*$ - [NC,L] RewriteRule ^public/.*$ /public/index.php [NC,L]]]></description>
			<content:encoded><![CDATA[<p><code><br />
Options +FollowSymLinks<br />
RewriteEngine on</p>
<p>RewriteRule ^\.htaccess$ - [F]</p>
<p>RewriteRule ^(blog|forum)($|/) - [L]</p>
<p>RewriteCond %{REQUEST_URI} =""<br />
RewriteRule ^.*$ /public/index.php [NC,L]</p>
<p>RewriteCond %{REQUEST_URI} !^/public/.*$<br />
RewriteRule ^(.*)$ /public/$1</p>
<p>RewriteCond %{REQUEST_FILENAME} -f<br />
RewriteRule ^.*$ - [NC,L]</p>
<p>RewriteRule ^public/.*$ /public/index.php [NC,L]<br />
</code></p>
]]></content:encoded>
			<wfw:commentRss>http://anilkonsal.com/zend-framework-project-htaccess-with-exclusion-of-folders/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Exporting unversioned files with SVN</title>
		<link>http://anilkonsal.com/exporting-unversioned-files-with-svn</link>
		<comments>http://anilkonsal.com/exporting-unversioned-files-with-svn#comments</comments>
		<pubDate>Sat, 28 May 2011 05:11:46 +0000</pubDate>
		<dc:creator>Anil Konsal</dc:creator>
				<category><![CDATA[Subversion]]></category>
		<category><![CDATA[svn export unversioned shell]]></category>

		<guid isPermaLink="false">http://anilkonsal.com/?p=60</guid>
		<description><![CDATA[You can just use cp -r to copy the directory tree directly, and then remove the .svn directories afterwards: # cp -r x # cd x # find . -name .svn -type d -exec rm -r &#8216;{}&#8217; \;]]></description>
			<content:encoded><![CDATA[<p>You can just use cp -r to copy the directory tree directly, and then remove the .svn directories afterwards:<br />
# cp -r x<br />
# cd x<br />
# find . -name .svn -type d -exec rm -r &#8216;{}&#8217; \;</p>
]]></content:encoded>
			<wfw:commentRss>http://anilkonsal.com/exporting-unversioned-files-with-svn/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Drop Down menu hiding behind Flash in internet explorer</title>
		<link>http://anilkonsal.com/drop-down-menu-hiding-behind-flash-in-internet-explorer</link>
		<comments>http://anilkonsal.com/drop-down-menu-hiding-behind-flash-in-internet-explorer#comments</comments>
		<pubDate>Fri, 20 May 2011 08:08:23 +0000</pubDate>
		<dc:creator>Anil Konsal</dc:creator>
				<category><![CDATA[CSS]]></category>

		<guid isPermaLink="false">http://anilkonsal.com/?p=58</guid>
		<description><![CDATA[For this you have to make the flash movie transparent. set the wmode property to transparent in the flash object]]></description>
			<content:encoded><![CDATA[<p>For this you have to make the flash movie transparent. set the wmode property to transparent in the flash object</p>
]]></content:encoded>
			<wfw:commentRss>http://anilkonsal.com/drop-down-menu-hiding-behind-flash-in-internet-explorer/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Google Map Polygons draw internet explorer unspecified error</title>
		<link>http://anilkonsal.com/google-map-polygons-draw-internet-explorer-unspecified-error</link>
		<comments>http://anilkonsal.com/google-map-polygons-draw-internet-explorer-unspecified-error#comments</comments>
		<pubDate>Thu, 19 May 2011 10:37:34 +0000</pubDate>
		<dc:creator>Anil Konsal</dc:creator>
				<category><![CDATA[Google Maps]]></category>

		<guid isPermaLink="false">http://anilkonsal.com/?p=56</guid>
		<description><![CDATA[if you are using jQuery to initialize google Map, do not user $(function(){ initialize()}) or $(document).ready(function(){initialize()}). Always use $(window).load(function(){ initialize() }). This worked for me.]]></description>
			<content:encoded><![CDATA[<p>if you are using jQuery to initialize google Map, do not user $(function(){ initialize()}) or $(document).ready(function(){initialize()}). </p>
<p>Always use $(window).load(function(){ initialize() }). This worked for me.</p>
]]></content:encoded>
			<wfw:commentRss>http://anilkonsal.com/google-map-polygons-draw-internet-explorer-unspecified-error/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Installing python 2.7.1, mysql-pythondb and PIL (python Imaging Library) on centos</title>
		<link>http://anilkonsal.com/installing-python-2-7-1-mysql-pythondb-and-pil-python-imaging-library-on-centos</link>
		<comments>http://anilkonsal.com/installing-python-2-7-1-mysql-pythondb-and-pil-python-imaging-library-on-centos#comments</comments>
		<pubDate>Sat, 09 Apr 2011 12:01:29 +0000</pubDate>
		<dc:creator>Anil Konsal</dc:creator>
				<category><![CDATA[Linux]]></category>

		<guid isPermaLink="false">http://anilkonsal.com/?p=53</guid>
		<description><![CDATA[yum -y install gcc gdbm-devel readline-devel ncurses-devel zlib-devel bzip2-develsqlite-devel db4-devel openssl-devel tk-devel bluez-libs-devel make cd /var/tmp wget http://www.python.org/ftp/python/2.7.1/Python-2.7.1.tgz tar xvfz Python-2.7.1.tgz cd Python-2.7.1 ./configure --prefix=/opt/python2.7.1 --with-threads --enable-shared make make install touch /etc/ld.so.conf.d/opt-python2.7.1.conf echo "/opt/python2.7.1/lib/" &#62;&#62; /etc/ld.so.conf.d/opt-python2.7.1.conf ldconfig ln -sf /opt/python2.7.1/bin/python &#8230; <a href="http://anilkonsal.com/installing-python-2-7-1-mysql-pythondb-and-pil-python-imaging-library-on-centos">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p><code><br />
yum -y install gcc gdbm-devel readline-devel ncurses-devel zlib-devel bzip2-develsqlite-devel db4-devel openssl-devel tk-devel bluez-libs-devel make</p>
<p>cd /var/tmp</p>
<p>wget http://www.python.org/ftp/python/2.7.1/Python-2.7.1.tgz</p>
<p>tar xvfz Python-2.7.1.tgz</p>
<p>cd Python-2.7.1</p>
<p>./configure --prefix=/opt/python2.7.1 --with-threads --enable-shared</p>
<p>make</p>
<p>make install<br />
touch /etc/ld.so.conf.d/opt-python2.7.1.conf</p>
<p>echo "/opt/python2.7.1/lib/" &gt;&gt; /etc/ld.so.conf.d/opt-python2.7.1.conf</p>
<p>ldconfig<br />
ln -sf /opt/python2.7.1/bin/python /usr/bin/python2.7<br />
cd /var/tmp</p>
<p>wget http://pypi.python.org/packages/2.7/s/setuptools/setuptools-0.6c11-py2.7.egg</p>
<p>sh setuptools-0.6c11-py2.7.egg --prefix=/opt/python2.7.1<br />
/opt/python2.7.1/bin/easy_install pip</p>
<p>ln -sf /opt/python2.7.1/bin/pip /usr/bin/pip<br />
pip install virtualenv</p>
<p>ln -sf /opt/python2.7.1/bin/virtualenv /usr/bin/virtualenv<br />
echo "alias python=/opt/python2.7.1/bin/python" &gt;&gt; ~/.bash_profile</p>
<p>echo "alias python2.7=/opt/python2.7.1/bin/python" &gt;&gt; ~/.bash_profile</p>
<p>echo "PATH=$PATH:/opt/python2.7.1/bin" &gt;&gt; ~/.bash_profile</p>
<p>source ~/.bash_profile<br />
# install mysql python db</p>
<p>cd /var/tmp</p>
<p>pip install http://sourceforge.net/projects/mysql-python/files/mysql-python/1.2.3/MySQL-python-1.2.3.tar.gz/download</p>
<p>#install PIL</p>
<p>yum install libjpeg freetype</p>
<p>pip install http://effbot.org/downloads/Imaging-1.1.7.tar.gz<br />
</code></p>
]]></content:encoded>
			<wfw:commentRss>http://anilkonsal.com/installing-python-2-7-1-mysql-pythondb-and-pil-python-imaging-library-on-centos/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

