<?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>My Own Percept &#187; Web development</title>
	<atom:link href="http://www.myownpercept.com/category/web-development/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.myownpercept.com</link>
	<description>"Only in quiet waters things mirror themselves undistorted. Only in a quiet mind is adequate perception of the world."~Hans Margolius</description>
	<lastBuildDate>Mon, 02 Aug 2010 12:51:39 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.1</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Fatal error: Class &#8216;Net_SMTP&#8217; not found in /usr/lib/php/Mail/smtp.php on line 349</title>
		<link>http://www.myownpercept.com/2010/08/fatal-error-class-net_smtp-not-found-in-usrlibphpmailsmtp-php-on-line-349/</link>
		<comments>http://www.myownpercept.com/2010/08/fatal-error-class-net_smtp-not-found-in-usrlibphpmailsmtp-php-on-line-349/#comments</comments>
		<pubDate>Mon, 02 Aug 2010 12:48:18 +0000</pubDate>
		<dc:creator>Marouan OMEZZINE</dc:creator>
				<category><![CDATA[Tips & Tricks]]></category>
		<category><![CDATA[Web development]]></category>
		<category><![CDATA[how-to]]></category>
		<category><![CDATA[error]]></category>
		<category><![CDATA[Net_SMTP]]></category>
		<category><![CDATA[pear]]></category>
		<category><![CDATA[php]]></category>

		<guid isPermaLink="false">http://www.myownpercept.com/?p=299</guid>
		<description><![CDATA[digg_url = 'http://www.myownpercept.com/2010/08/fatal-error-class-net_smtp-not-found-in-usrlibphpmailsmtp-php-on-line-349/';digg_title = 'Fatal error: Class &#8216;Net_SMTP&#8217; not found in /usr/lib/php/Mail/smtp.php on line 349';
Error:

1
2
3
4
5
Warning: include_once&#40;Net/SMTP.php&#41; &#91;function.include-once&#93;: failed to open stream: No such file or directory in /usr/lib/php/Mail/smtp.php on line 348
&#160;
Warning: include_once&#40;&#41; &#91;function.include&#93;: Failed opening 'Net/SMTP.php' for inclusion &#40;include_path='.:/usr/lib/php'&#41; in /usr/lib/php/Mail/smtp.php on line 348
&#160;
Fatal error: Class 'Net_SMTP' not found in /usr/lib/php/Mail/smtp.php on line 349

Just install [...]]]></description>
			<content:encoded><![CDATA[<div class="diggbutton"><script type="text/javascript">digg_url = 'http://www.myownpercept.com/2010/08/fatal-error-class-net_smtp-not-found-in-usrlibphpmailsmtp-php-on-line-349/';digg_title = 'Fatal error: Class &#8216;Net_SMTP&#8217; not found in /usr/lib/php/Mail/smtp.php on line 349';</script><script src="http://digg.com/tools/diggthis.js" type="text/javascript"></script></div>
<p><strong>Error</strong>:</p>

<div class="wp_syntax"><table><tr><td class="line_numbers"><pre>1
2
3
4
5
</pre></td><td class="code"><pre class="php" style="font-family:monospace;">Warning<span style="color: #339933;">:</span> <span style="color: #b1b100;">include_once</span><span style="color: #009900;">&#40;</span>Net<span style="color: #339933;">/</span>SMTP<span style="color: #339933;">.</span>php<span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#91;</span><span style="color: #000000; font-weight: bold;">function</span><span style="color: #339933;">.</span>include<span style="color: #339933;">-</span>once<span style="color: #009900;">&#93;</span><span style="color: #339933;">:</span> failed to open stream<span style="color: #339933;">:</span> No such <span style="color: #990000;">file</span> or directory in <span style="color: #339933;">/</span>usr<span style="color: #339933;">/</span>lib<span style="color: #339933;">/</span>php<span style="color: #339933;">/</span><span style="color: #990000;">Mail</span><span style="color: #339933;">/</span>smtp<span style="color: #339933;">.</span>php on line <span style="color: #cc66cc;">348</span>
&nbsp;
Warning<span style="color: #339933;">:</span> <span style="color: #b1b100;">include_once</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#91;</span><span style="color: #000000; font-weight: bold;">function</span><span style="color: #339933;">.</span><span style="color: #b1b100;">include</span><span style="color: #009900;">&#93;</span><span style="color: #339933;">:</span> Failed opening <span style="color: #0000ff;">'Net/SMTP.php'</span> <span style="color: #b1b100;">for</span> inclusion <span style="color: #009900;">&#40;</span>include_path<span style="color: #339933;">=</span><span style="color: #0000ff;">'.:/usr/lib/php'</span><span style="color: #009900;">&#41;</span> in <span style="color: #339933;">/</span>usr<span style="color: #339933;">/</span>lib<span style="color: #339933;">/</span>php<span style="color: #339933;">/</span><span style="color: #990000;">Mail</span><span style="color: #339933;">/</span>smtp<span style="color: #339933;">.</span>php on line <span style="color: #cc66cc;">348</span>
&nbsp;
Fatal error<span style="color: #339933;">:</span> <span style="color: #000000; font-weight: bold;">Class</span> <span style="color: #0000ff;">'Net_SMTP'</span> not found in <span style="color: #339933;">/</span>usr<span style="color: #339933;">/</span>lib<span style="color: #339933;">/</span>php<span style="color: #339933;">/</span><span style="color: #990000;">Mail</span><span style="color: #339933;">/</span>smtp<span style="color: #339933;">.</span>php on line <span style="color: #cc66cc;">349</span></pre></td></tr></table></div>

<p>Just install the missing pear package:</p>

<div class="wp_syntax"><table><tr><td class="line_numbers"><pre>1
</pre></td><td class="code"><pre class="shell" style="font-family:monospace;">sudo pear install Net_SMTP</pre></td></tr></table></div>

]]></content:encoded>
			<wfw:commentRss>http://www.myownpercept.com/2010/08/fatal-error-class-net_smtp-not-found-in-usrlibphpmailsmtp-php-on-line-349/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>LoadError : no such file to load — readline (LoadError) when running script/console on ubuntu</title>
		<link>http://www.myownpercept.com/2009/06/loaderror-no-such-file-to-load-%e2%80%94-readline-loaderror-when-running-scriptconsole-on-ubuntu/</link>
		<comments>http://www.myownpercept.com/2009/06/loaderror-no-such-file-to-load-%e2%80%94-readline-loaderror-when-running-scriptconsole-on-ubuntu/#comments</comments>
		<pubDate>Mon, 15 Jun 2009 12:51:27 +0000</pubDate>
		<dc:creator>Marouan OMEZZINE</dc:creator>
				<category><![CDATA[Tips & Tricks]]></category>
		<category><![CDATA[Web development]]></category>
		<category><![CDATA[how-to]]></category>
		<category><![CDATA[error]]></category>
		<category><![CDATA[extconf]]></category>
		<category><![CDATA[rails]]></category>
		<category><![CDATA[ruby]]></category>

		<guid isPermaLink="false">http://www.myownpercept.com/?p=228</guid>
		<description><![CDATA[digg_url = 'http://www.myownpercept.com/2009/06/loaderror-no-such-file-to-load-%e2%80%94-readline-loaderror-when-running-scriptconsole-on-ubuntu/';digg_title = 'LoadError : no such file to load — readline (LoadError) when running script/console on ubuntu';
Q : What&#8217;s the best thing that may happen to a developer ?
A : A Bug   at the beginning of the day  
I ran script/console in a rails project to debug something on console, [...]]]></description>
			<content:encoded><![CDATA[<div class="diggbutton"><script type="text/javascript">digg_url = 'http://www.myownpercept.com/2009/06/loaderror-no-such-file-to-load-%e2%80%94-readline-loaderror-when-running-scriptconsole-on-ubuntu/';digg_title = 'LoadError : no such file to load — readline (LoadError) when running script/console on ubuntu';</script><script src="http://digg.com/tools/diggthis.js" type="text/javascript"></script></div>
<blockquote><p>Q : What&#8217;s the best thing that may happen to a developer ?<br />
A : A Bug <img src='http://www.myownpercept.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' />  at the beginning of the day <img src='http://www.myownpercept.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p></blockquote>
<p>I ran script/console in a rails project to debug something on console,  but I got this LoadError:</p>

<div class="wp_syntax"><table><tr><td class="line_numbers"><pre>1
2
3
4
5
6
7
8
9
10
</pre></td><td class="code"><pre class="shell" style="font-family:monospace;">Loading development environment (Rails 2.1.0)
/usr/local/lib/ruby/1.8/irb/completion.rb:10:in `require’: no such file to load — readline (LoadError)
        from /usr/local/lib/ruby/1.8/irb/completion.rb:10
        from /usr/local/lib/ruby/1.8/irb/init.rb:252:in `require’
        from /usr/local/lib/ruby/1.8/irb/init.rb:252:in `load_modules’
        from /usr/local/lib/ruby/1.8/irb/init.rb:250:in `each’
        from /usr/local/lib/ruby/1.8/irb/init.rb:250:in `load_modules’
        from /usr/local/lib/ruby/1.8/irb/init.rb:21:in `setup’
        from /usr/local/lib/ruby/1.8/irb.rb:54:in `start’
        from /usr/local/bin/irb:13</pre></td></tr></table></div>

<p><center><script type="text/javascript"><!--
google_ad_client = "pub-0920621684521020";
google_ad_slot = "1251664758";
google_ad_width = 336;
google_ad_height = 280;
//--></script>
<script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"></script>
</center><br />
<strong>How to fix ?</strong><br />
I figured out that some libraries are missing after installing ruby from sources (I got those troubles after upgrading my ubuntu from 8.10 to 9.04 and then reinstalling ruby from sources to solve a non-compatibility problem of the already installed ruby binary package with ubuntu 9.04) :</p>

<div class="wp_syntax"><table><tr><td class="line_numbers"><pre>1
2
</pre></td><td class="code"><pre class="shell" style="font-family:monospace;">sudo apt-get install libncurses5-dev
sudo apt-get install libreadline5-dev</pre></td></tr></table></div>

<p>Then move to your ruby source folder, subfolder ext/readline and then configure, build and install stuffs.</p>
<p><center><script type="text/javascript"><!--
google_ad_client = "pub-0920621684521020";
google_ad_slot = "1251664758";
google_ad_width = 336;
google_ad_height = 280;
//--></script>
<script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"></script>
</center></p>

<div class="wp_syntax"><table><tr><td class="line_numbers"><pre>1
2
3
4
</pre></td><td class="code"><pre class="shell" style="font-family:monospace;">cd /usr/src/ruby-1.8.6-p368/ext/readline/
ruby extconf.rb
sudo make
sudo make install</pre></td></tr></table></div>

<p>you may get something like this : ( when running <em>ruby extconf.rb</em>)</p>

<div class="wp_syntax"><table><tr><td class="line_numbers"><pre>1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
</pre></td><td class="code"><pre class="shell" style="font-family:monospace;">marouan@myownpercept:/usr/src/ruby-1.8.6-p368/ext/readline$ sudo ruby extconf.rb
checking for tgetnum() in -lncurses... yes
checking for readline/readline.h... yes
checking for readline/history.h... yes
checking for readline() in -lreadline... yes
checking for rl_filename_completion_function()... yes
checking for rl_username_completion_function()... yes
checking for rl_completion_matches()... yes
checking for rl_deprep_term_function in stdio.h,readline/readline.h,readline/history.h... yes
checking for rl_completion_append_character in stdio.h,readline/readline.h,readline/history.h... yes
checking for rl_basic_word_break_characters in stdio.h,readline/readline.h,readline/history.h... yes
checking for rl_completer_word_break_characters in stdio.h,readline/readline.h,readline/history.h... yes
checking for rl_basic_quote_characters in stdio.h,readline/readline.h,readline/history.h... yes
checking for rl_completer_quote_characters in stdio.h,readline/readline.h,readline/history.h... yes
checking for rl_filename_quote_characters in stdio.h,readline/readline.h,readline/history.h... yes
checking for rl_attempted_completion_over in stdio.h,readline/readline.h,readline/history.h... yes
checking for rl_library_version in stdio.h,readline/readline.h,readline/history.h... yes
checking for rl_event_hook in stdio.h,readline/readline.h,readline/history.h... yes
checking for rl_cleanup_after_signal()... yes
checking for rl_clear_signals()... yes
checking for rl_vi_editing_mode()... yes
checking for rl_emacs_editing_mode()... yes
checking for replace_history_entry()... yes
checking for remove_history()... yes
creating Makefile</pre></td></tr></table></div>

]]></content:encoded>
			<wfw:commentRss>http://www.myownpercept.com/2009/06/loaderror-no-such-file-to-load-%e2%80%94-readline-loaderror-when-running-scriptconsole-on-ubuntu/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>How to remove the blue border around an image link</title>
		<link>http://www.myownpercept.com/2009/04/remove-border-around-image/</link>
		<comments>http://www.myownpercept.com/2009/04/remove-border-around-image/#comments</comments>
		<pubDate>Sun, 12 Apr 2009 17:34:22 +0000</pubDate>
		<dc:creator>Marouan OMEZZINE</dc:creator>
				<category><![CDATA[Tips & Tricks]]></category>
		<category><![CDATA[Web development]]></category>
		<category><![CDATA[how-to]]></category>
		<category><![CDATA[snippet]]></category>
		<category><![CDATA[css]]></category>
		<category><![CDATA[html]]></category>

		<guid isPermaLink="false">http://www.myownpercept.com/?p=155</guid>
		<description><![CDATA[digg_url = 'http://www.myownpercept.com/2009/04/remove-border-around-image/';digg_title = 'How to remove the blue border around an image link';



You want to use an image as a link.However, a blue border appears around the image.

1
2
3
&#60;a href=&#34;http://www.myownpercept.com/&#34;&#62;  
  &#60;img src=&#34;logo.png&#34; alt=&#34;&#34; /&#62;
&#60;/a&#62;

This border is meant to inform users that the image is a link. Well, it&#8217;s a link but this [...]]]></description>
			<content:encoded><![CDATA[<div class="diggbutton"><script type="text/javascript">digg_url = 'http://www.myownpercept.com/2009/04/remove-border-around-image/';digg_title = 'How to remove the blue border around an image link';</script><script src="http://digg.com/tools/diggthis.js" type="text/javascript"></script></div>
<p style="text-align: center;"><script type="text/javascript"><!--
google_ad_client = "pub-0920621684521020";
google_ad_slot = "2952953575";
google_ad_width = 468;
google_ad_height = 60;
//--></script>
<script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"></script>
</p>
<p>You want to use an image as a link.However, a blue border appears around the image.</p>

<div class="wp_syntax"><table><tr><td class="line_numbers"><pre>1
2
3
</pre></td><td class="code"><pre class="html4strict" style="font-family:monospace;"><span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">a</span> <span style="color: #000066;">href</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;http://www.myownpercept.com/&quot;</span>&gt;</span>  
  <span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">img</span> <span style="color: #000066;">src</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;logo.png&quot;</span> <span style="color: #000066;">alt</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;&quot;</span> <span style="color: #66cc66;">/</span>&gt;</span>
<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">a</span>&gt;</span></pre></td></tr></table></div>

<p>This border is meant to inform users that the image is a link. Well, it&#8217;s a link but this is ugly :s and may not fit your need. <br />
<script type="text/javascript"><!--
google_ad_client = "pub-0920621684521020";
google_ad_slot = "1251664758";
google_ad_width = 336;
google_ad_height = 280;
//--></script>
<script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"></script>
  </p>
<h2>Solution</h2>
<ol>
<li>You simply have to add a border-style, set to none, as a style to your img tag

<div class="wp_syntax"><table><tr><td class="line_numbers"><pre>1
2
3
</pre></td><td class="code"><pre class="html4strict" style="font-family:monospace;"><span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">a</span> <span style="color: #000066;">href</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;http://www.myownpercept.com/&quot;</span>&gt;</span>
  <span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">img</span> <span style="color: #000066;">style</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;border-style: none;&quot;</span> <span style="color: #000066;">src</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;logo.png&quot;</span> <span style="color: #000066;">alt</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;&quot;</span> <span style="color: #66cc66;">/</span>&gt;</span>
<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">a</span>&gt;</span></pre></td></tr></table></div>

</li>
<li>A cleaner way, that will pass the W3C validation, is by adding those lines to your CSS file :

<div class="wp_syntax"><table><tr><td class="line_numbers"><pre>1
2
3
</pre></td><td class="code"><pre class="css" style="font-family:monospace;">img <span style="color: #00AA00;">&#123;</span>
	<span style="color: #000000; font-weight: bold;">border-style</span><span style="color: #00AA00;">:</span> <span style="color: #993333;">none</span><span style="color: #00AA00;">;</span>
<span style="color: #00AA00;">&#125;</span></pre></td></tr></table></div>

</li>
<li>A dirty old way, but works,  is by adding border attribute to the img tag.

<div class="wp_syntax"><table><tr><td class="line_numbers"><pre>1
2
3
</pre></td><td class="code"><pre class="html4strict" style="font-family:monospace;"><span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">a</span> <span style="color: #000066;">href</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;http://www.myownpercept.com/&quot;</span>&gt;</span>  
  <span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">img</span> <span style="color: #000066;">src</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;logo.png&quot;</span> <span style="color: #000066;">border</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;0&quot;</span> <span style="color: #000066;">alt</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;&quot;</span> <span style="color: #66cc66;">/</span>&gt;</span>
<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">a</span>&gt;</span></pre></td></tr></table></div>

</li>
</ol>
]]></content:encoded>
			<wfw:commentRss>http://www.myownpercept.com/2009/04/remove-border-around-image/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
