<?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/"
	xmlns:georss="http://www.georss.org/georss" xmlns:geo="http://www.w3.org/2003/01/geo/wgs84_pos#" xmlns:media="http://search.yahoo.com/mrss/"
	>

<channel>
	<title>Viral Solani</title>
	<atom:link href="https://viralsolani.wordpress.com/feed/" rel="self" type="application/rss+xml" />
	<link>https://viralsolani.wordpress.com</link>
	<description>If you can&#039;t do it, I will love to do it....</description>
	<lastBuildDate>Sat, 15 Jun 2013 04:24:28 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.com/</generator>
<cloud domain='viralsolani.wordpress.com' port='80' path='/?rsscloud=notify' registerProcedure='' protocol='http-post' />
<image>
		<url>https://secure.gravatar.com/blavatar/53140200943f953d49b0a445fa8f899c?s=96&#038;d=https%3A%2F%2Fs2.wp.com%2Fi%2Fbuttonw-com.png</url>
		<title>Viral Solani</title>
		<link>https://viralsolani.wordpress.com</link>
	</image>
	<atom:link rel="search" type="application/opensearchdescription+xml" href="https://viralsolani.wordpress.com/osd.xml" title="Viral Solani" />
	<atom:link rel='hub' href='https://viralsolani.wordpress.com/?pushpress=hub'/>
		<item>
		<title>How to replace plain URLs with links in JavaScript or PHP?</title>
		<link>https://viralsolani.wordpress.com/2013/05/18/how-to-replace-plain-urls-with-links-in-javascript-or-php/</link>
		<comments>https://viralsolani.wordpress.com/2013/05/18/how-to-replace-plain-urls-with-links-in-javascript-or-php/#comments</comments>
		<pubDate>Sat, 18 May 2013 10:36:35 +0000</pubDate>
		<dc:creator>viralsolani</dc:creator>
				<category><![CDATA[Javascript]]></category>
		<category><![CDATA[Jquery]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[How to replace plain URLs with links]]></category>
		<category><![CDATA[How to replace plain URLs with links in JavaScript or PHP?]]></category>
		<category><![CDATA[JavaScript]]></category>
		<category><![CDATA[Plain text]]></category>

		<guid isPermaLink="false">http://viralsolani.wordpress.com/?p=485</guid>
		<description><![CDATA[Hello Friends If you want to convert plain text in to URLs in JavaScript or PHP. This is good solution for you. In PHP : In JavaScript Hope it helps.<img alt="" border="0" src="https://stats.wordpress.com/b.gif?host=viralsolani.wordpress.com&#038;blog=15107616&#038;post=485&#038;subd=viralsolani&#038;ref=&#038;feed=1" width="1" height="1" />]]></description>
				<content:encoded><![CDATA[<p>Hello Friends</p>
<p>If you want to convert plain text in to URLs in JavaScript or PHP. This is good solution for you.</p>
<blockquote><p>In PHP :</p></blockquote>
<pre class="brush: php; title: ; notranslate">
public function makeLinks($str)
{
    $reg_exUrl = &quot;/(http|https|ftp|ftps)\:\/\/[a-zA-Z0-9\-\.]+\.[a-zA-Z]{2,3}(\/\S*)?/&quot;;
    $urls = array();
    $urlsToReplace = array();
    if(preg_match_all($reg_exUrl, $str, $urls)) {
        $numOfMatches = count($urls[0]);
        $numOfUrlsToReplace = 0;
        for($i=0; $i&amp;lt;$numOfMatches; $i++) {
            $alreadyAdded = false;
            $numOfUrlsToReplace = count($urlsToReplace);
            for($j=0; $j&amp;lt;$numOfUrlsToReplace; $j++) {
                if($urlsToReplace[$j] == $urls[0][$i]) {
                    $alreadyAdded = true;
                }
            }
            if(!$alreadyAdded) {
                array_push($urlsToReplace, $urls[0][$i]);
            }
        }
        $numOfUrlsToReplace = count($urlsToReplace);
        for($i=0; $i&amp;lt;$numOfUrlsToReplace; $i++) {
            $str = str_replace($urlsToReplace[$i], &quot;&amp;lt;a target='_balnk' href=\&quot;&quot;.$urlsToReplace[$i].&quot;\&quot;&amp;gt;&quot;.$urlsToReplace[$i].&quot;&amp;lt;/a&amp;gt; &quot;, $str);
        }
        return $str;
    } else {
        return $str;
    }
}
</pre>
<blockquote><p>In JavaScript</p></blockquote>
<pre class="brush: jscript; title: ; notranslate">
function makeLinks(text) {
 var exp = /(\b(https?|ftp|file):\/\/[-A-Z0-9+&amp;amp;@#\/%?=~_|!:,.;]*[-A-Z0-9+&amp;amp;@#\/%=~_|])/ig;
 return text.replace(exp,&quot;&amp;lt;a target='_blank' href='$1'&amp;gt;$1&amp;lt;/a&amp;gt;&quot;);
}
</pre>
<p>Hope it helps.</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/viralsolani.wordpress.com/485/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/viralsolani.wordpress.com/485/" /></a> <img alt="" border="0" src="https://stats.wordpress.com/b.gif?host=viralsolani.wordpress.com&#038;blog=15107616&#038;post=485&#038;subd=viralsolani&#038;ref=&#038;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>https://viralsolani.wordpress.com/2013/05/18/how-to-replace-plain-urls-with-links-in-javascript-or-php/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
	
		<media:content url="https://1.gravatar.com/avatar/4ca6a6b2dfb7925852e82ac82685cee2?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">viralsolani</media:title>
		</media:content>
	</item>
		<item>
		<title>8 Things Productive People Do During the Workday</title>
		<link>https://viralsolani.wordpress.com/2013/05/16/8-things-productive-people-do-during-the-workday/</link>
		<comments>https://viralsolani.wordpress.com/2013/05/16/8-things-productive-people-do-during-the-workday/#comments</comments>
		<pubDate>Thu, 16 May 2013 06:34:46 +0000</pubDate>
		<dc:creator>viralsolani</dc:creator>
				<category><![CDATA[Cool Articles]]></category>
		<category><![CDATA[Motivatioanl Stories]]></category>
		<category><![CDATA[8 Things Productive People Do During the Workday]]></category>
		<category><![CDATA[Productivity]]></category>
		<category><![CDATA[Time management]]></category>

		<guid isPermaLink="false">http://viralsolani.wordpress.com/?p=481</guid>
		<description><![CDATA[Forget about your job title or profession – everyone is looking for ways to be more productive at work. It’s time to set down your gallon-sized container of coffee, toss out your three-page to-do list, and put an end to those ridiculously long emails you’ve been sending. Experiencing a highly productive workday can feel euphoric. But contrary [&#8230;]<img alt="" border="0" src="https://stats.wordpress.com/b.gif?host=viralsolani.wordpress.com&#038;blog=15107616&#038;post=481&#038;subd=viralsolani&#038;ref=&#038;feed=1" width="1" height="1" />]]></description>
				<content:encoded><![CDATA[<div id="attachment_482" class="wp-caption alignleft" style="width: 310px"><a href="http://viralsolani.files.wordpress.com/2013/05/00c61ae.jpg"><img class="size-medium wp-image-482" alt="8 Things Productive People Do During the Workday" src="http://viralsolani.files.wordpress.com/2013/05/00c61ae.jpg?w=300&#038;h=239" width="300" height="239" /></a><p class="wp-caption-text">Productivity</p></div>
<p>Forget about your job title or profession – <em>everyone</em> is looking for ways to be more productive at work. It’s time to set down your gallon-sized container of coffee, toss out your three-page to-do list, and put an end to those ridiculously long emails you’ve been sending.</p>
<p>Experiencing a highly productive workday can feel euphoric. But contrary to popular belief, simply checking tasks off your to-do list isn’t really an indication of productivity. Truly productive people aren’t focused on doing more things; this is actually the opposite of productivity. If you really want to be productive, you’ve got to make a point to do fewer things.</p>
<p>Harness your productivity by taking note of these eight things:</p>
<p><strong>1. Create a smaller to-do list.</strong> Getting things accomplished during your workday shouldn’t be about doing as much as possible in the sanctioned eight hours. It may be hard to swallow, but there’s nothing productive about piling together a slew of tasks in the form of a checklist. Take a less-is-more approach to your to-do list by only focusing on accomplishing things that matter.</p>
<p><strong>2. Take breaks. </strong>You know that ache that fills your brain when you’ve been powering through tasks for several hours? This is due to your brain using up glucose. Too many people mistake this for a good feeling, rather than a signal to take a break. Go take a walk, grab something to eat, workout, or meditate – give your brain some resting time. Achieve more productivity during your workday by making a point to regularly clear your head. You’ll come back recharged and ready to achieve greater efficiency.</p>
<p><strong>3. Follow the 80/20 rule.</strong> Did you know that only 20 percent of what you do each day produces 80 percent of your results? Eliminate the things that don’t matter during your workday: they have a minimal effect on your overall productivity. For example, on a project, systematically remove tasks until you end up with the 20 percent that gets the 80 percent of results.</p>
<p><strong>4. Start your day by focusing on yourself.</strong> If you begin your morning by checking your email, it allows others to dictate what you accomplish. Set yourself in the right direction by ignoring your emails and taking the morning to focus on yourself, eat a good breakfast, meditate, or read the news.</p>
<p><strong>5. Take on harder tasks earlier in the day.</strong> Knock out your most challenging work when your brain is most fresh. Save your busy work – if you have any – for when your afternoon slump rolls in.</p>
<p><strong>6. Pick up the phone. </strong>The digital world has created poor communication habits. Email is a productivity killer and usually a distraction from tasks that actually matter. For example, people often copy multiple people on emails to get it off their plate – don&#8217;t be a victim of this action. This distracts everyone else by creating noise against the tasks they’re trying to accomplish and is a sign of laziness. If you receive an email where many people are CC&#8217;d, do everyone a favor by BCCing them on your reply. If your email chain goes beyond two replies, it’s time to pick up the phone. Increase your productivity by scheduling a call.</p>
<p><strong>7. Create a system. </strong>If you know certain things are ruining your daily productivity, create a system for managing them. Do you check your emails throughout the day? Plan a morning, afternoon, and evening time slot for managing your email. Otherwise, you’ll get distracted from accomplishing more important goals throughout the day.</p>
<p><strong>8. Don’t confuse productivity with laziness.</strong> While no one likes admitting it, sheer laziness is the No. 1 contributor to lost productivity. In fact, a number of time-saving methods – take meetings and emails for example – are actually just ways to get out of doing real work. Place your focus on doing the things that matter most as efficiently and effectively as possible.</p>
<p>Remember, less is more when it comes to being productive during the workday.</p>
<p><em>What’s your secret to productive workdays?</em></p>
<p>&nbsp;</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/viralsolani.wordpress.com/481/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/viralsolani.wordpress.com/481/" /></a> <img alt="" border="0" src="https://stats.wordpress.com/b.gif?host=viralsolani.wordpress.com&#038;blog=15107616&#038;post=481&#038;subd=viralsolani&#038;ref=&#038;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>https://viralsolani.wordpress.com/2013/05/16/8-things-productive-people-do-during-the-workday/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="https://1.gravatar.com/avatar/4ca6a6b2dfb7925852e82ac82685cee2?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">viralsolani</media:title>
		</media:content>

		<media:content url="http://viralsolani.files.wordpress.com/2013/05/00c61ae.jpg?w=300" medium="image">
			<media:title type="html">8 Things Productive People Do During the Workday</media:title>
		</media:content>
	</item>
		<item>
		<title>Set php.ini Values Using .htaccess</title>
		<link>https://viralsolani.wordpress.com/2013/02/13/set-php-ini-values-using-htaccess/</link>
		<comments>https://viralsolani.wordpress.com/2013/02/13/set-php-ini-values-using-htaccess/#comments</comments>
		<pubDate>Wed, 13 Feb 2013 10:49:48 +0000</pubDate>
		<dc:creator>viralsolani</dc:creator>
				<category><![CDATA[htaccess]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[php.ini]]></category>
		<category><![CDATA[Set php.ini Values Using .htaccess]]></category>

		<guid isPermaLink="false">http://viralsolani.wordpress.com/?p=466</guid>
		<description><![CDATA[Did you know that you can set php.ini values right inside the .htaccess file? It&#8217;s actually very easy. The .htaccess Code #format php_value setting_name setting_value#example php_value upload_max_filesize 10M Of course you could simply place these in the .htaccess file, but .htaccess is a viable alternative if your host doesn&#8217;t allow you to touch the php.ini [&#8230;]<img alt="" border="0" src="https://stats.wordpress.com/b.gif?host=viralsolani.wordpress.com&#038;blog=15107616&#038;post=466&#038;subd=viralsolani&#038;ref=&#038;feed=1" width="1" height="1" />]]></description>
				<content:encoded><![CDATA[<p>Did you know that you can set php.ini values right inside the .htaccess file? It&#8217;s actually very easy.</p>
<h2>The .htaccess Code</h2>
<pre>#format
php_value setting_name setting_value#example
php_value  upload_max_filesize  10M</pre>
<p>Of course you could simply place these in the .htaccess file, but .htaccess is a viable alternative if your host doesn&#8217;t allow you to touch the php.ini file.</p>
<p><strong>Resource :</strong></p>
<p><a href="http://davidwalsh.name/php-values-htaccess" rel="nofollow">http://davidwalsh.name/php-values-htaccess</a></p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/viralsolani.wordpress.com/466/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/viralsolani.wordpress.com/466/" /></a> <img alt="" border="0" src="https://stats.wordpress.com/b.gif?host=viralsolani.wordpress.com&#038;blog=15107616&#038;post=466&#038;subd=viralsolani&#038;ref=&#038;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>https://viralsolani.wordpress.com/2013/02/13/set-php-ini-values-using-htaccess/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="https://1.gravatar.com/avatar/4ca6a6b2dfb7925852e82ac82685cee2?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">viralsolani</media:title>
		</media:content>
	</item>
		<item>
		<title>Prevent Your CSS and JavaScript Files From Being Cached</title>
		<link>https://viralsolani.wordpress.com/2013/02/13/prevent-your-css-and-javascript-files-from-being-cached/</link>
		<comments>https://viralsolani.wordpress.com/2013/02/13/prevent-your-css-and-javascript-files-from-being-cached/#comments</comments>
		<pubDate>Wed, 13 Feb 2013 09:44:08 +0000</pubDate>
		<dc:creator>viralsolani</dc:creator>
				<category><![CDATA[PHP]]></category>
		<category><![CDATA[CSS]]></category>
		<category><![CDATA[JavaScript]]></category>
		<category><![CDATA[Prevent Your CSS and JavaScript Files From Being Cached]]></category>
		<category><![CDATA[prevent-cache]]></category>
		<category><![CDATA[Style Sheets]]></category>
		<category><![CDATA[Web browser]]></category>

		<guid isPermaLink="false">http://viralsolani.wordpress.com/?p=458</guid>
		<description><![CDATA[Some websites use highly volatile, oft-changing CSS and JavaScript files. In the case of these files, it&#8217;s important that the developer prevent browsers from caching them. How do we do that? By using a phantom querystring, of course. We&#8217;ll use PHP to tack the current time onto the file reference. The PHP It&#8217;s a very [&#8230;]<img alt="" border="0" src="https://stats.wordpress.com/b.gif?host=viralsolani.wordpress.com&#038;blog=15107616&#038;post=458&#038;subd=viralsolani&#038;ref=&#038;feed=1" width="1" height="1" />]]></description>
				<content:encoded><![CDATA[<p>Some websites use highly volatile, oft-changing CSS and JavaScript files. In the case of these files, it&#8217;s important that the developer prevent browsers from caching them. How do we do that? By using a phantom querystring, of course. We&#8217;ll use PHP to tack the current time onto the file reference.</p>
<h2>The PHP</h2>
<pre class="brush: php; title: ; notranslate">
&lt;link href=&quot;/stylesheet.css?&lt;?php echo time(); ?&gt;&quot; rel=&quot;stylesheet&quot; type=&quot;text/css&quot; &gt;
&lt;-- RENDERS --&gt;
&lt;link href=&quot;/stylesheet.css?1234567890&quot; rel=&quot;stylesheet&quot; type=&quot;text/css&quot;&gt;

&lt;script type=&quot;text/javascript&quot; src=&quot;/site-script.js?&lt;?php echo time(); ?&gt;&quot;&gt;&lt;/script&gt;
&lt;-- RENDERS --&gt;
&lt;script type=&quot;text/javascript&quot; src=&quot;/site-script.js?1234567890&quot;&gt;&lt;/script&gt;
</pre>
<p>It&#8217;s a very simple technique and doesn&#8217;t affect your CSS or JavaScript code in any way.</p>
<p><strong>Resource :</strong></p>
<p><a href="http://davidwalsh.name/prevent-cache" rel="nofollow">http://davidwalsh.name/prevent-cache</a></p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/viralsolani.wordpress.com/458/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/viralsolani.wordpress.com/458/" /></a> <img alt="" border="0" src="https://stats.wordpress.com/b.gif?host=viralsolani.wordpress.com&#038;blog=15107616&#038;post=458&#038;subd=viralsolani&#038;ref=&#038;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>https://viralsolani.wordpress.com/2013/02/13/prevent-your-css-and-javascript-files-from-being-cached/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="https://1.gravatar.com/avatar/4ca6a6b2dfb7925852e82ac82685cee2?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">viralsolani</media:title>
		</media:content>
	</item>
		<item>
		<title>Android Detection with JavaScript or PHP</title>
		<link>https://viralsolani.wordpress.com/2013/02/13/android-detection-with-javascript-or-php/</link>
		<comments>https://viralsolani.wordpress.com/2013/02/13/android-detection-with-javascript-or-php/#comments</comments>
		<pubDate>Wed, 13 Feb 2013 06:53:28 +0000</pubDate>
		<dc:creator>viralsolani</dc:creator>
				<category><![CDATA[Javascript]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[Android]]></category>
		<category><![CDATA[Android Detection with JavaScript or PHP]]></category>
		<category><![CDATA[htaccess]]></category>
		<category><![CDATA[IOS]]></category>
		<category><![CDATA[JavaScript]]></category>
		<category><![CDATA[Uniform Resource Locator]]></category>
		<category><![CDATA[User agent]]></category>
		<category><![CDATA[Web application]]></category>

		<guid isPermaLink="false">http://viralsolani.wordpress.com/?p=438</guid>
		<description><![CDATA[Hello Friends You have a web application and you want to detect that if your Application is opened from android device than it will be redirect to any other URL that will be Android compatible.This is a good solution for you. What&#8217;s obvious is that Android development is a hot topic that will only grow. [&#8230;]<img alt="" border="0" src="https://stats.wordpress.com/b.gif?host=viralsolani.wordpress.com&#038;blog=15107616&#038;post=438&#038;subd=viralsolani&#038;ref=&#038;feed=1" width="1" height="1" />]]></description>
				<content:encoded><![CDATA[<p>Hello Friends</p>
<p>You have a web application and you want to detect that if your Application is opened from android device than it will be redirect to any other URL that will be Android compatible.This is a good solution for you.</p>
<p>What&#8217;s obvious is that Android development is a hot topic that will only grow. Here are a few methods by which you can detect <a class="zem_slink" title="IOS" href="http://www.apple.com/ios" target="_blank" rel="homepage">iOS</a>&#8216; main competitor: Android.</p>
<h2>The JavaScript</h2>
<p>Searching the user agent string for &#8220;Android&#8221; is the quickest method:</p>
<pre class="brush: php; title: ; notranslate">
var ua = navigator.userAgent.toLowerCase();
var isAndroid = ua.indexOf(&quot;android&quot;) &gt; -1; //&amp;&amp; ua.indexOf(&quot;mobile&quot;);
if(isAndroid)
{
// Do something! // Redirect to Android-site? window.location = 'http://android.viralsolani.co';
}

</pre>
<h2>The PHP</h2>
<p>Again, we&#8217;ll use PHP&#8217;s strstr function to search for Android in the user agent:</p>
<pre class="brush: php; title: ; notranslate">
$ua = strtolower($_SERVER['HTTP_USER_AGENT']);
if(stripos($ua,'android') !== false){// &amp;&amp; stripos($ua,'mobile') !== false) {
header('Location: http://android.viralsolani.co');
exit();
}
</pre>
<h2>Bonus! .htaccess Detection </h2>
<p>We can even use .htaccess directives to detect and react to Android devices!</p>
<pre class="brush: php; title: ; notranslate">
RewriteCond %{HTTP_USER_AGENT} ^.*Android.*$
 RewriteRule ^(.*)$ http://android.viralsolani.co [R=301]
</pre>
<p>And there you have it: three different Android device detection! Have fun with your mobile development!</p>
<p><strong>Resource :</strong></p>
<p><a href="http://davidwalsh.name/detect-android" rel="nofollow">http://davidwalsh.name/detect-android</a></p>
<p>Thanks</p>
<p>&nbsp;</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/viralsolani.wordpress.com/438/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/viralsolani.wordpress.com/438/" /></a> <img alt="" border="0" src="https://stats.wordpress.com/b.gif?host=viralsolani.wordpress.com&#038;blog=15107616&#038;post=438&#038;subd=viralsolani&#038;ref=&#038;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>https://viralsolani.wordpress.com/2013/02/13/android-detection-with-javascript-or-php/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="https://1.gravatar.com/avatar/4ca6a6b2dfb7925852e82ac82685cee2?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">viralsolani</media:title>
		</media:content>
	</item>
		<item>
		<title>How to install SSL Certificates with Apache 2 on Ubuntu 12.04</title>
		<link>https://viralsolani.wordpress.com/2013/02/07/how-to-install-ssl-certificates-with-apache-2-on-ubuntu-12-04/</link>
		<comments>https://viralsolani.wordpress.com/2013/02/07/how-to-install-ssl-certificates-with-apache-2-on-ubuntu-12-04/#comments</comments>
		<pubDate>Thu, 07 Feb 2013 10:59:23 +0000</pubDate>
		<dc:creator>viralsolani</dc:creator>
				<category><![CDATA[Apache]]></category>
		<category><![CDATA[Ubuntu]]></category>
		<category><![CDATA[How to generate CSR]]></category>
		<category><![CDATA[How to install SSL Certificates with Apache 2 on Ubuntu 12.04]]></category>
		<category><![CDATA[SSL Certificates]]></category>

		<guid isPermaLink="false">http://viralsolani.wordpress.com/?p=418</guid>
		<description><![CDATA[Please note that commercial SSL certificates require a unique IP address each for SSL-enabled site, although multiple non-SSL sites may also share that IP address. Step – 1 Create a Certificate Signing Request A CSR is an encrypted body of text. Your CSR will contain encoded information specific to your company and domain name; this [&#8230;]<img alt="" border="0" src="https://stats.wordpress.com/b.gif?host=viralsolani.wordpress.com&#038;blog=15107616&#038;post=418&#038;subd=viralsolani&#038;ref=&#038;feed=1" width="1" height="1" />]]></description>
				<content:encoded><![CDATA[<p>Please note that commercial SSL certificates require a unique IP address each for SSL-enabled site, although multiple non-SSL sites may also share that IP address.</p>
<p><strong>Step – 1 Create a Certificate Signing Request</strong></p>
<p>A CSR is an encrypted body of text. Your CSR will contain encoded information specific to your company and domain name; this information is known as a Distinguished Name or DN.<br />
In the DN for most servers are the following fields: Country, State (or Province), Locality (or City), Organization, Organizational Unit, and Common Name. Please note:<br />
1. The Country is a two-digit code &#8212; for the United States, it&#8217;s &#8216;US&#8217;. For countries outside of the United States,<br />
2. State and Locality are full names, i.e. &#8216;California&#8217;, &#8216;Los Angeles&#8217;.<br />
3. The Organization Name is your Full Legal Company or Personal Name, as legally registered in your locality.<br />
4. The Organizational Unit is whichever branch of your company is ordering the certificate such as accounting, marketing, etc.<br />
5. The Common Name is the Fully Qualified Domain Name (FQDN) for which you are requesting the ssl certificate.<br />
If you are generating a CSR for a Wildcard Certificate your common name must start with *. (for example: *.digicert.com). The wildcard character (*) will be able to assume any name that does not have a &#8220;dot&#8221; character in it.<br />
To remain secure, certificates must use keys which are at least 2048 bits in length. If your server platform can&#8217;t generate a CSR with a 2048-bit key</p>
<pre class="brush: php; title: ; notranslate">
mkdir /etc/apache2/ssl
 cd /etc/apache2/ssl
 openssl req -new -newkey rsa:2048 -nodes -keyout yourdomain.key -out yourdomain.csr
</pre>
<p>Replace yourdomain with the domain name you&#8217;re securing. For example, if your domain name is viralsolani.co, you would type viralsolani.co.key and viralsolani.co.csr.</p>
<p>• This begins the process of generating two files: the Private-Key file for the decryption of your SSL Certificate, and a certificate signing request (CSR) file (used to apply for your SSL Certificate) with apache openssl.</p>
<p>• Open the CSR file with a text editor and copy and paste it (including the BEGIN and END tags) into the form from where you purchase your SSL certificate.</p>
<p>• Save (backup) the generated .key file as it will be required later for Certificate installation</p>
<p>Execute the following command to protect the key:<br />
chmod 400 /etc/apache2/ssl/www.yourdomain.com.key</p>
<p>Execute the following command to protect the signed certificate:</p>
<pre class="brush: php; title: ; notranslate">
chmod 400 /etc/apache2/ssl/www.mydomain.com.crt

</pre>
<p><strong>Step – 2 Get the Certificate Authority Root Certificate</strong><br />
In My case it is Go Daddy. So you need to go from wherever you purchase your SSL certificate and you need to submit the below generated CSR. And you can then download the certificate.<br />
You will get two files. I’ve upload that two files in same folder where I’ve put my CSR and Private key that i.e /etc/apache2/ssl/<br />
<strong>Step – 3 Configure Apache to use the Signed SSL Certificate.</strong></p>
<p>This configuration vary depend upon OS and version of that OS. So I’ve installed Ubuntu 12.04 and to configure the certificate you need to do below steps.<br />
You need to configuration in Apache virtual hosting file.<br />
So now you need to go: /etc/apache2/sites-available/default-ssl</p>
<pre class="brush: php; title: ; notranslate">
&lt;IfModule mod_ssl.c&gt;
&lt;VirtualHost _default_:443&gt;
ServerAdmin viral.solani@gmail.com

DocumentRoot /var/www
&lt;Directory /&gt;
Options FollowSymLinks
AllowOverride None
&lt;/Directory&gt;
&lt;Directory /var/www/&gt;
Options Indexes FollowSymLinks MultiViews
AllowOverride None
Order allow,deny
allow from all
&lt;/Directory&gt;

SSLCertificateFile    /etc/apache2/ssl/yourdomain.com.crt
SSLCertificateKeyFile /etc/apache2/ssl/yourdomain.com.key
SSLCertificateChainFile /etc/apache2/ssl/gd_bundle.crt

&lt;/VirtualHost&gt;
&lt;/IfModule&gt;

</pre>
<p>Basically you need to locate yourdomain.com.crt , yourdomain.com.key and gd_bundle.crt.<br />
Now last thing you need to do is restart you apache with the following command</p>
<pre class="brush: php; title: ; notranslate">
 /etc/init.d/apache2 restart

</pre>
<p>You should now be able to visit your site with SSL enabled. Congratulations, you&#8217;ve installed a commercial SSL certificate!</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/viralsolani.wordpress.com/418/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/viralsolani.wordpress.com/418/" /></a> <img alt="" border="0" src="https://stats.wordpress.com/b.gif?host=viralsolani.wordpress.com&#038;blog=15107616&#038;post=418&#038;subd=viralsolani&#038;ref=&#038;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>https://viralsolani.wordpress.com/2013/02/07/how-to-install-ssl-certificates-with-apache-2-on-ubuntu-12-04/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="https://1.gravatar.com/avatar/4ca6a6b2dfb7925852e82ac82685cee2?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">viralsolani</media:title>
		</media:content>
	</item>
		<item>
		<title>2012 in review</title>
		<link>https://viralsolani.wordpress.com/2013/01/29/2012-in-review/</link>
		<comments>https://viralsolani.wordpress.com/2013/01/29/2012-in-review/#comments</comments>
		<pubDate>Tue, 29 Jan 2013 07:13:54 +0000</pubDate>
		<dc:creator>viralsolani</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://viralsolani.wordpress.com/?p=417</guid>
		<description><![CDATA[The WordPress.com stats helper monkeys prepared a 2012 annual report for this blog. Here&#8217;s an excerpt: 4,329 films were submitted to the 2012 Cannes Film Festival. This blog had 14,000 views in 2012. If each view were a film, this blog would power 3 Film Festivals Click here to see the complete report.<img alt="" border="0" src="https://stats.wordpress.com/b.gif?host=viralsolani.wordpress.com&#038;blog=15107616&#038;post=417&#038;subd=viralsolani&#038;ref=&#038;feed=1" width="1" height="1" />]]></description>
				<content:encoded><![CDATA[<p>The WordPress.com stats helper monkeys prepared a 2012 annual report for this blog.</p>
<p>	<a href="http://viralsolani.wordpress.com/2012/annual-report/"><img src="http://www.wordpress.com/wp-content/mu-plugins/annual-reports/img/2012-emailteaser.png" width="100%" alt="" /></a></p>
<p>Here&#8217;s an excerpt:</p>
</p>
<blockquote><p>4,329 films were submitted to the 2012 Cannes Film Festival. This blog had <strong>14,000</strong> views in 2012. If each view were a film, this blog would power 3 Film Festivals</p></blockquote>
<p><a href="http://viralsolani.wordpress.com/2012/annual-report/">Click here to see the complete report.</a></p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/viralsolani.wordpress.com/417/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/viralsolani.wordpress.com/417/" /></a> <img alt="" border="0" src="https://stats.wordpress.com/b.gif?host=viralsolani.wordpress.com&#038;blog=15107616&#038;post=417&#038;subd=viralsolani&#038;ref=&#038;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>https://viralsolani.wordpress.com/2013/01/29/2012-in-review/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="https://1.gravatar.com/avatar/4ca6a6b2dfb7925852e82ac82685cee2?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">viralsolani</media:title>
		</media:content>

		<media:content url="http://www.wordpress.com/wp-content/mu-plugins/annual-reports/img/2012-emailteaser.png" medium="image" />
	</item>
		<item>
		<title>Understanding Abstract Classes in PHP</title>
		<link>https://viralsolani.wordpress.com/2012/12/06/understanding-abstract-classes-in-php/</link>
		<comments>https://viralsolani.wordpress.com/2012/12/06/understanding-abstract-classes-in-php/#comments</comments>
		<pubDate>Thu, 06 Dec 2012 17:38:54 +0000</pubDate>
		<dc:creator>viralsolani</dc:creator>
				<category><![CDATA[OOPS Consept]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[OOPS consents in PHP]]></category>
		<category><![CDATA[PHP Interview Question]]></category>
		<category><![CDATA[Understanding Abstract Classes in PHP]]></category>

		<guid isPermaLink="false">http://viralsolani.wordpress.com/?p=415</guid>
		<description><![CDATA[Abstract classes are an often misunderstood feature of PHP object-oriented programming (OOP) and the source of confusion when considered versus an Interface. The obvious reason for using an Interface is that a child class can implement multiple interfaces but extend only a single abstract class. However, if multiple inheritance is not required then people often [&#8230;]<img alt="" border="0" src="https://stats.wordpress.com/b.gif?host=viralsolani.wordpress.com&#038;blog=15107616&#038;post=415&#038;subd=viralsolani&#038;ref=&#038;feed=1" width="1" height="1" />]]></description>
				<content:encoded><![CDATA[<p>Abstract classes are an often misunderstood feature of PHP object-oriented programming (OOP) and the source of confusion when considered versus an Interface. The obvious reason for using an Interface is that a child class can implement multiple interfaces but extend only a single abstract class. However, if multiple inheritance is not required then people often go with abstract classes just because they provide the option of later adding base functionality within the abstract class. This is not entirely unreasonable but the reasons for creating abstract classes should be more than that.<br />
Why Use Abstract Classes?</p>
<p>An Abstract class provides concrete base functions as well as abstract functions that must be implemented by concrete child classes—binding them into a contract so to speak, if they wish to make use of the base functionality.</p>
<p>This is a subtle but important point and this is where abstract classes really shine. They can call abstract functions from within base concrete functions. Jumping straight to an example is the clearest way to explain this.</p>
<pre class="brush: php; title: ; notranslate">
abstract class Animal {
  function greeting() {
    $sound = $this-&gt;sound();      // exists in child class by contract
    return strtoupper($sound);
  }
  abstract function sound();      // this is the contract
}

class Dog extends Animal {
  function sound() {              // concrete implementation is mandatory
    return &quot;Woof!&quot;;
  }
}

$dog = new Dog();
echo $dog-&gt;greeting();            // WOOF!
</pre>
<p>This opens up a whole lot of interesting possibilities. For example, you can write a drive() function that calls $this-&gt;start(); $this-&gt;accelerate(); in an abstract class. Then create a motorcycle class that defines its own start() and accelerate() functions that may be different from those in the car class. In turn, the motorcycle and car can both be driven by just calling drive() without having to implement it locally.<br />
Characteristics of Abstract Classes</p>
<p>Make a note of these characteristics to lock down your understanding of abstract classes:</p>
<ul>
<li>Single inheritance. Child classes can extend only one class at a time.</li>
<li>Abstract classes cannot be instantiated — no new Animal();</li>
<li>Abstract classes can define class variables of type const only.</li>
<li>Abstract class A can be extended by another abstract class B. Abstract class B can implement none or any of the abstract functions in A.</li>
<li>In the previous case, a child class C which extends abstract class B must implement all abstract functions in B as well as the abstract functions in A which have not already been implemented in B.</li>
<li>The signature of the concrete functions and abstract functions must be the same. However, if an abstract function is defined as abstract function speak($greeting); then it is okay to implement it as function speak($greeting, $shout = FALSE) but not function speak($greeting, $shout).</li>
<li>The visibility of functions in the child classes must be the same or less restrictive than the parent class. Thus, a protected abstract function can be implemented as either protected or public but not private.</li>
<p>Declaring functions as static abstract throws a strict warning in PHP 5.2 or earlier, however, as of PHP 5.3 this is allowed.</li>
</ul>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/viralsolani.wordpress.com/415/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/viralsolani.wordpress.com/415/" /></a> <img alt="" border="0" src="https://stats.wordpress.com/b.gif?host=viralsolani.wordpress.com&#038;blog=15107616&#038;post=415&#038;subd=viralsolani&#038;ref=&#038;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>https://viralsolani.wordpress.com/2012/12/06/understanding-abstract-classes-in-php/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
	
		<media:content url="https://1.gravatar.com/avatar/4ca6a6b2dfb7925852e82ac82685cee2?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">viralsolani</media:title>
		</media:content>
	</item>
		<item>
		<title>Add JSON objects ,arrays and variables from php to javascript in Zend Framework</title>
		<link>https://viralsolani.wordpress.com/2012/09/26/405/</link>
		<comments>https://viralsolani.wordpress.com/2012/09/26/405/#comments</comments>
		<pubDate>Thu, 27 Sep 2012 05:04:32 +0000</pubDate>
		<dc:creator>viralsolani</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://viralsolani.wordpress.com/2012/09/26/405/</guid>
		<description><![CDATA[Reblogged from Rupesh Patel Web Developer: If you are using any MVC framework(these days I think most of us uses MVC) in php, then you might needed to assign variables from php to javascript, Some times you might have to add tens of parameters to javascript. And this thing leads to dirty code like below [&#8230;]<img alt="" border="0" src="https://stats.wordpress.com/b.gif?host=viralsolani.wordpress.com&#038;blog=15107616&#038;post=405&#038;subd=viralsolani&#038;ref=&#038;feed=1" width="1" height="1" />]]></description>
				<content:encoded><![CDATA[<div class="reblog-post"><p class="reblog-from"><img alt='' src='https://1.gravatar.com/avatar/ded59d37d49e7ad90848551ba30eaebc?s=25&amp;d=identicon&amp;r=G' class='avatar avatar-25' height='25' width='25' /> <a href="https://rupeshpatel.wordpress.com/2012/09/21/add-json-objects-arrays-and-variables-from-php-to-javascript/">Reblogged from Rupesh Patel  Web Developer:</a></p><div class="wpcom-enhanced-excerpt"><div class="wpcom-enhanced-excerpt-content"><a href="https://rupeshpatel.wordpress.com/2012/09/21/add-json-objects-arrays-and-variables-from-php-to-javascript/" target="_self"><img src="https://s0.wp.com/imgpress?url=http%3A%2F%2Fstackoverflow.com%2Fusers%2Fflair%2F1488417.png" alt="Click to visit the original post" class="size-full" /></a>
<p>If you are using any MVC framework(these days I think most of us uses MVC) in php, then you might needed to assign variables from php to javascript, Some times you might have to add tens of parameters to javascript. And this thing leads to dirty code like below in any of your view files..</p>

<p>and the main problem with this solution is you have to do it explicitly for each of variables.</p>
</div> <p class="read-more"><a href="https://rupeshpatel.wordpress.com/2012/09/21/add-json-objects-arrays-and-variables-from-php-to-javascript/" target="_self"><span>Read more&hellip;</span> 504 more words</a></p></div></div><div class="reblogger-note"><div class='reblogger-note-content'>
Superb way of adding PHP variables to Javascript/Jquery in Zend Framework
</div></div>]]></content:encoded>
			<wfw:commentRss>https://viralsolani.wordpress.com/2012/09/26/405/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="https://1.gravatar.com/avatar/4ca6a6b2dfb7925852e82ac82685cee2?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">viralsolani</media:title>
		</media:content>
	</item>
		<item>
		<title>The Painting</title>
		<link>https://viralsolani.wordpress.com/2012/05/31/401/</link>
		<comments>https://viralsolani.wordpress.com/2012/05/31/401/#comments</comments>
		<pubDate>Thu, 31 May 2012 10:25:21 +0000</pubDate>
		<dc:creator>viralsolani</dc:creator>
				<category><![CDATA[Cool Articles]]></category>
		<category><![CDATA[Motivatioanl Stories]]></category>
		<category><![CDATA[Motivation]]></category>
		<category><![CDATA[Motivational Articles]]></category>
		<category><![CDATA[Motivational Stories]]></category>

		<guid isPermaLink="false">http://viralsolani.wordpress.com/2012/05/31/401/</guid>
		<description><![CDATA[Reblogged from Motivate YourSelf: There was a king who was a great admirer of art. He encouraged artists from all over his country and gave them valuable gifts. One day an artist came and said to the king, "Oh King! Give me a blank wall in your palace and let me paint a picture on [&#8230;]<img alt="" border="0" src="https://stats.wordpress.com/b.gif?host=viralsolani.wordpress.com&#038;blog=15107616&#038;post=401&#038;subd=viralsolani&#038;ref=&#038;feed=1" width="1" height="1" />]]></description>
				<content:encoded><![CDATA[<div class="reblog-post"><p class="reblog-from"><img alt='' src='https://0.gravatar.com/avatar/0dc72fd0dfec1ad6aaacfcc32d715604?s=25&amp;d=identicon&amp;r=G' class='avatar avatar-25' height='25' width='25' /> <a href="https://2motivate.wordpress.com/2012/05/31/the-painting/">Reblogged from Motivate YourSelf:</a></p><div class="wpcom-enhanced-excerpt"><div class="wpcom-enhanced-excerpt-content">
<p>There was a king who was a great admirer of art. He encouraged artists from all over his country and gave them valuable gifts.</p>
<p>One day an artist came and said to the king, "Oh King! Give me a blank wall in your palace and let me paint a picture on it. It will be more beautiful than anything you have ever seen before.</p>
</div> <p class="read-more"><a href="https://2motivate.wordpress.com/2012/05/31/the-painting/" target="_self"><span>Read more&hellip;</span> 540 more words</a></p></div></div><div class="reblogger-note"><div class='reblogger-note-content'>
Nice Story......
</div></div>]]></content:encoded>
			<wfw:commentRss>https://viralsolani.wordpress.com/2012/05/31/401/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="https://1.gravatar.com/avatar/4ca6a6b2dfb7925852e82ac82685cee2?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">viralsolani</media:title>
		</media:content>
	</item>
	</channel>
</rss>
