<?xml version='1.0' encoding='UTF-8'?><rss xmlns:atom="http://www.w3.org/2005/Atom" xmlns:openSearch="http://a9.com/-/spec/opensearchrss/1.0/" xmlns:blogger="http://schemas.google.com/blogger/2008" xmlns:georss="http://www.georss.org/georss" xmlns:gd="http://schemas.google.com/g/2005" xmlns:thr="http://purl.org/syndication/thread/1.0" version="2.0"><channel><atom:id>tag:blogger.com,1999:blog-5813540589519490137</atom:id><lastBuildDate>Fri, 06 Sep 2024 21:12:19 +0000</lastBuildDate><category>PHP</category><category>Sliit</category><category>mysql</category><category>Curtin</category><category>JavaScript</category><category>TIPS</category><category>jQuery</category><category>mid term</category><category>life</category><category>Ruby on Rails</category><category>phpMyAdmin</category><category>wamp server</category><category>DBMS III</category><category>Datepicker</category><category>Expresso</category><category>FPDF</category><category>HTML Tables</category><category>Regular Expressions</category><category>RoR</category><category>SPD2</category><category>Ubuntu</category><category>checkdate()</category><category>div</category><category>like strstr php</category><category>youtube api</category><category>Aptana Studio</category><category>Browser User Agents</category><category>C++</category><category>Cannot modify header</category><category>City</category><category>Configuration error</category><category>Curtin SLIIT</category><category>Cycle Plugin</category><category>District</category><category>Failed to access IIS metabase</category><category>Feathercoin</category><category>Find dup-licates in mysql</category><category>Foundation Certificate in Information Technology</category><category>Free learning videos</category><category>GFWL</category><category>GHS</category><category>Getafreelancer</category><category>Getafreelancer.com</category><category>HD 7750</category><category>HTML MARQUEE UP</category><category>HTML Tidy</category><category>How to get the size of an array php</category><category>How to post code samples in blog posts</category><category>How to post code samples in blogspot</category><category>How to turn off error reporting in php</category><category>IIS Configuration error</category><category>ITA</category><category>InnoDB</category><category>Install InstantRails</category><category>Install RoR</category><category>Install Ruby on Rails</category><category>Instant Rails</category><category>InstantRails</category><category>InstantRails 2.0</category><category>JavaScript Errors</category><category>JavaScript String Search</category><category>KeepAliveTimeout</category><category>Konami code</category><category>Kuppiya.com</category><category>LightBox</category><category>MAX</category><category>MOOV-Atom</category><category>Magento</category><category>Mangento</category><category>Marquee</category><category>My Graduation</category><category>MyISAM</category><category>MySql TIME</category><category>MySql TIMESTAMP</category><category>MySql last inserted row</category><category>Mysql TIME data type</category><category>NBQSA</category><category>New Ideas</category><category>PDFlib alternative</category><category>PHP random number</category><category>PHP-GTK sri lanaka</category><category>RGB color</category><category>Rich Text Editor</category><category>Richard Matthew Stallman in SLIIT</category><category>Richard Matthew Stallman in Sri Lanka</category><category>SEO</category><category>SETM</category><category>SHOW TABLES</category><category>SLIIT Community</category><category>SLIIT Convocation 2008</category><category>SLIIT Schools Program</category><category>SLIIT Together 2008</category><category>SLLIT</category><category>SPAW Editor</category><category>SQL</category><category>SQLite3</category><category>Saddest Day Of My SLIIT Life</category><category>Select or Deselect All Checkboxes</category><category>ServerSide JavaScript</category><category>Sexy LightBox</category><category>Simple News Bar</category><category>Simple image filmstrip</category><category>Simple image scroller</category><category>Square root</category><category>Sri Lanka</category><category>Start SLIIT with O/L</category><category>String Length in JavaScript</category><category>TDIT</category><category>T_PAAMAYIM_NEKUDOTAYIM</category><category>Text Box transparent</category><category>TinyMCE</category><category>Undefined index</category><category>VB.NET</category><category>Variable is empty using PHP</category><category>Virtusa</category><category>WYSIWYG</category><category>Web.config</category><category>Web.config error</category><category>XML</category><category>YYYY-MM-DD HH:MM:SS</category><category>YouTube video API search</category><category>add break to newlines</category><category>array</category><category>array_merge()</category><category>array_push()</category><category>array_search</category><category>array_search()</category><category>array_unique()</category><category>assoative array</category><category>basics on ruby rails</category><category>be your own boss</category><category>bitcoin</category><category>ceiling()</category><category>change time zone php</category><category>check array</category><category>check for numbers</category><category>check if a array key exists</category><category>check upload file extension</category><category>cloud mining</category><category>content around a image using DIV</category><category>create dynamic pdf files</category><category>cryptography</category><category>curl</category><category>current URL using JavaScript</category><category>current shell</category><category>custom key codes</category><category>date format</category><category>date()</category><category>date_default_timezone_set()</category><category>delete a directory</category><category>describe</category><category>distinct mysql</category><category>drop up menu</category><category>duplicate mysql rows</category><category>encode HTML</category><category>encode code</category><category>encrypted</category><category>exam help</category><category>facebook</category><category>fadeIn</category><category>fb application tab blank page</category><category>feed</category><category>feed browser</category><category>file type</category><category>final</category><category>find correct date</category><category>floor()</category><category>foreach</category><category>foreign key in mysql</category><category>fpdf.org</category><category>free ide</category><category>free javascript editor</category><category>free web hosting</category><category>get Max ID</category><category>get Max ID mysql</category><category>get current executing file in php</category><category>getElementById</category><category>getimagesize()</category><category>glob()</category><category>gmail</category><category>header()</category><category>how to add date php</category><category>how to add time php</category><category>how to find a array key</category><category>html2pdf</category><category>image type button</category><category>implode()</category><category>in_array()</category><category>is_int()</category><category>is_numeric()</category><category>join array elements</category><category>join php and html</category><category>joins</category><category>kuppiya</category><category>linode</category><category>linux</category><category>list tables</category><category>make all uppercase php</category><category>make first letter uppercase</category><category>make word capital php</category><category>md5</category><category>merge two arrays</category><category>mktime</category><category>model answers</category><category>mp4</category><category>mysql date()</category><category>mysql row count</category><category>mysql same field name</category><category>mysql update</category><category>mysql_affected_rows()</category><category>mysql_fetch_array()</category><category>mysql_fetch_assoc()</category><category>mysql_insert_id()</category><category>mysql_num_rows</category><category>mysql_real_escape_string()</category><category>mysql_result</category><category>nl2br()</category><category>onchange dropdown</category><category>onchange redirect</category><category>onmouseout. change background color</category><category>onmouseover</category><category>open a PDF inside a php file</category><category>php and html</category><category>php and radio buttons</category><category>php array</category><category>php array size</category><category>php content editor</category><category>php empty</category><category>php error reporting</category><category>php forms</category><category>php gd</category><category>php row count</category><category>php submit</category><category>php time diff</category><category>phpmailer</category><category>post content-length exceeds</category><category>post_max_size</category><category>pow()</category><category>print_r</category><category>rails</category><category>rand()</category><category>random alpha numeric value</category><category>random number</category><category>random row from mysql table</category><category>redirect a page using java script</category><category>refresh parent window</category><category>reload  parent  window from a iframe</category><category>remove first letter from a string</category><category>replace a string within given portion</category><category>rmdir()</category><category>round floating numbers</category><category>round()</category><category>rss</category><category>scaffold</category><category>scan files inside a directory</category><category>scandir()</category><category>search array</category><category>set rgb colors in div tag</category><category>set rgb values in drop down</category><category>sha1</category><category>shell</category><category>sinhala learning videos</category><category>size of flash</category><category>size of swf</category><category>sliit it park</category><category>specific row in a large result</category><category>split a string</category><category>split() JS</category><category>sqrt()</category><category>storage engine</category><category>string</category><category>strlen</category><category>strtolower</category><category>strtoupper()</category><category>substr</category><category>substr_replace</category><category>swapping</category><category>thumb rotator</category><category>time to string</category><category>timstamp</category><category>title tag</category><category>top.location.href</category><category>uniqid</category><category>unique array values</category><category>unset</category><category>update error</category><category>update query</category><category>validate date</category><category>wampserver</category><category>wampserver download</category><category>web editor</category><category>what is faster</category><category>window.location.href</category><title>MY NODE</title><description>SHARING MY KNOWLEDGE</description><link>http://my-sliit.blogspot.com/</link><managingEditor>noreply@blogger.com (my node)</managingEditor><generator>Blogger</generator><openSearch:totalResults>204</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>25</openSearch:itemsPerPage><item><guid isPermaLink="false">tag:blogger.com,1999:blog-5813540589519490137.post-8680269972524590100</guid><pubDate>Wed, 30 Apr 2014 08:35:00 +0000</pubDate><atom:updated>2014-04-30T14:08:05.739+05:30</atom:updated><category domain="http://www.blogger.com/atom/ns#">bitcoin</category><category domain="http://www.blogger.com/atom/ns#">cloud mining</category><category domain="http://www.blogger.com/atom/ns#">GHS</category><title>Before you buy Cloud Mining</title><description>Why would a company sell already bought hashing power to someone else without making 100% bitcoin profit mining it alone. It doesn&#39;t make sense at all unless the seller is trying to sell it for a highly over priced amount or scam you.&lt;br /&gt;
&lt;br /&gt;
Some companies say that you can trade the bought GHS but even then bitcoin difficulty rises and GHS drops in value very fast. Unless you are a good short term trader GHS trading is a ripoff. This apply to mining as well with increasing difficulty you will get lesser returns for your GHS plus increased maintenance fee.&lt;br /&gt;
&lt;br /&gt;
Just my thoughts, Please do proper research before you invest in cloud mining.</description><link>http://my-sliit.blogspot.com/2014/04/before-you-buy-cloud-mining.html</link><author>noreply@blogger.com (my node)</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-5813540589519490137.post-2470127679147215269</guid><pubDate>Mon, 03 Mar 2014 19:39:00 +0000</pubDate><atom:updated>2014-03-04T01:14:16.382+05:30</atom:updated><title>Mahara web services - simple guide</title><description>Mahara web services can be installed as a plugin. Installation is a easy process. you can find the steps in here&amp;nbsp;&lt;a href=&quot;https://wiki.mahara.org/index.php/Plugins/Auth/WebServices#Installation_Instructions&quot; target=&quot;_blank&quot;&gt;https://wiki.mahara.org/index.php/Plugins/Auth/WebServices#Installation_Instructions&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
extract the zip file and put to folders inside mahara&amp;nbsp;/path/to/mahara/webservice and&amp;nbsp;/path/to/mahara/auth/webservice&lt;br /&gt;
&lt;br /&gt;
login to mahara as admin goto menu extensions -&amp;gt; Plugin administration under&amp;nbsp;Plugin type: auth heading install&amp;nbsp;webservice&lt;br /&gt;
&lt;br /&gt;
code check for https so if you do not have SSL in your site and you want to test the web services you can comment out https check part in the code (NOT recommended for a production server)&lt;br /&gt;
&lt;br /&gt;
for example if you want to use REST go to the folder webservice -&amp;gt; rest inside server.php comment&lt;br /&gt;
&lt;br /&gt;
&lt;pre style=&quot;background-color: #eeeeee; border: 1px dashed rgb(153, 153, 153); overflow: auto; padding: 5px; width: 100%;&quot;&gt;// you must use HTTPS as token based auth is a hazzard without it
/*if (!is_https()) {
    header(&quot;HTTP/1.0 403 Forbidden - HTTPS must be used&quot;);
    die;
}*/
&lt;/pre&gt;
&lt;br /&gt;
Now you can test web services using the built in Web service test client&lt;br /&gt;
click Configuration link near webservice plugin. Enable WebServices master switch. under Manage Service Access Tokens add a user and generate a token. Now click Web service test client tab and select&lt;br /&gt;
protocol - REST&lt;br /&gt;
Authentication Type - Token&lt;br /&gt;
Service - choose the service you selected when generating token.&lt;br /&gt;
Select a function and enter token.&lt;br /&gt;
&lt;br /&gt;
You can also use curl from another site to access the webservice like this&lt;br /&gt;
&lt;br /&gt;
&lt;pre style=&quot;background-color: #eeeeee; border: 1px dashed rgb(153, 153, 153); overflow: auto; padding: 5px; width: 100%;&quot;&gt;&amp;lt;?php
$service_url = &#39;http://yoursite.com/mahara/webservice/rest/server.php&#39;;
$token = &#39;your token&#39;;

$curl = curl_init($service_url);

$curl_post_data = array( &amp;nbsp; &amp;nbsp; &amp;nbsp; 

&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;&#39;wsfunction&#39; =&amp;gt; &#39;mahara_user_get_users&#39;, // the function to be called
&amp;nbsp; &amp;nbsp; &amp;nbsp;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;&#39;wstoken&#39; =&amp;gt; $token //token need to be passed in the url
);

curl_setopt($curl, CURLOPT_RETURNTRANSFER, true);
curl_setopt($curl, CURLOPT_POST, true);
curl_setopt($curl, CURLOPT_POSTFIELDS, $curl_post_data);
$curl_response = curl_exec($curl);

$info = curl_getinfo($curl);

if ($curl_response === false) {
&amp;nbsp; &amp;nbsp; $info = curl_getinfo($curl);
&amp;nbsp; &amp;nbsp; curl_close($curl);
&amp;nbsp; &amp;nbsp; die(&#39;error occured during curl exec. Additioanl info: &#39;.var_export($info));
}
curl_close($curl);

header(&quot;Content-type: text/xml&quot;);

echo $curl_response;

?&amp;gt;
&lt;/pre&gt;
&lt;br /&gt;</description><link>http://my-sliit.blogspot.com/2014/03/mahara-web-services-simple-guide.html</link><author>noreply@blogger.com (my node)</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-5813540589519490137.post-2700113576790490196</guid><pubDate>Sat, 01 Mar 2014 19:12:00 +0000</pubDate><atom:updated>2014-03-02T09:28:28.219+05:30</atom:updated><title>Mahara - Sorry, your registration attempt was unsuccessful. This is our fault, not yours. Please try again later.</title><description>Fix is to setup email setting in site options.
I installed Mahara on a shared hosting. I&#39;m not sure how to setup email setting required for localhost other than giving working SMTP details.

Administration -&gt; Site options -&gt; Email settings</description><link>http://my-sliit.blogspot.com/2014/03/mahara-sorry-your-registration-attempt.html</link><author>noreply@blogger.com (my node)</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-5813540589519490137.post-9184877970340667992</guid><pubDate>Thu, 13 Feb 2014 07:28:00 +0000</pubDate><atom:updated>2014-02-13T13:00:52.742+05:30</atom:updated><title>div losing background color/image when resizing the browser window</title><description>When you have div width 100% it apply to browser viewpoint only not the max page width. This can be a problem when you have another div with a fixed width length. The fix is to put a min-width with max possible page width.&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEga-iDlLm3IX-9QbV_aa9BLoU5rifajGsbvdBhdv6GZC8kkKz0SBN2b5Wq-bAurOxpBstU5MBdBBPSu5WxlAOK6ICSZ7vc2C_99WQix_WWzLeX7FAjN-4I0sL7IQZBD7J4MArw5atyZcwcU/s1600/div.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEga-iDlLm3IX-9QbV_aa9BLoU5rifajGsbvdBhdv6GZC8kkKz0SBN2b5Wq-bAurOxpBstU5MBdBBPSu5WxlAOK6ICSZ7vc2C_99WQix_WWzLeX7FAjN-4I0sL7IQZBD7J4MArw5atyZcwcU/s1600/div.png&quot; height=&quot;112&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;pre style=&quot;background-color: #eeeeee; border: 1px dashed rgb(153, 153, 153); overflow: auto; padding: 5px; width: 100%;&quot;&gt;&amp;lt;html&amp;gt;
&amp;lt;head&amp;gt;
&amp;lt;style&amp;gt;
html, body{margin:0; padding:0;border: 0;outline: 0;}
&amp;lt;/style&amp;gt;
&amp;lt;/head&amp;gt;
&amp;lt;body&amp;gt;

&amp;lt;!--The problem--&amp;gt;
&amp;lt;div style=&quot;margin:0; width:100%; background-color:#060;&quot;&amp;gt;
 Header 1
&amp;lt;/div&amp;gt;

&amp;lt;div style=&quot;margin:0 auto; width:1000px; background-color:#03C;&quot;&amp;gt;     
 Text Line 1
&amp;lt;/div&amp;gt;

&amp;lt;br /&amp;gt;&amp;lt;br /&amp;gt;

&amp;lt;!--Fix--&amp;gt;
&amp;lt;div style=&quot;margin:0; width:100%; min-width:1000px; background-color:#060;&quot;&amp;gt;
 Header 2
&amp;lt;/div&amp;gt;

&amp;lt;div style=&quot;margin:0 auto; width:1000px; background-color:#03C;&quot;&amp;gt;     
 Text Line 2
&amp;lt;/div&amp;gt;

&amp;lt;/body&amp;gt;
&amp;lt;/html&amp;gt;

&lt;/pre&gt;
Don&#39;t forget padding widths when calculating min width.</description><link>http://my-sliit.blogspot.com/2014/02/div-losing-background-colorimage-when.html</link><author>noreply@blogger.com (my node)</author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEga-iDlLm3IX-9QbV_aa9BLoU5rifajGsbvdBhdv6GZC8kkKz0SBN2b5Wq-bAurOxpBstU5MBdBBPSu5WxlAOK6ICSZ7vc2C_99WQix_WWzLeX7FAjN-4I0sL7IQZBD7J4MArw5atyZcwcU/s72-c/div.png" height="72" width="72"/><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-5813540589519490137.post-7388269342686645845</guid><pubDate>Wed, 12 Feb 2014 04:02:00 +0000</pubDate><atom:updated>2014-02-12T09:32:09.808+05:30</atom:updated><category domain="http://www.blogger.com/atom/ns#">GFWL</category><title>Cannot login to Games for Windows LIVE</title><description>Login issue for me was caused by two-step verification. you can either disable it temporally till you finish game or you can use a App password that you can find in your Live account under &quot;Security info&quot;.&lt;br /&gt;
&lt;br /&gt;
GFWL can be very annoying at times. I had problems with it every time it was required to play a specific game. Wish they at least give a detailed error message without wasting my time for hours looking for fixes.</description><link>http://my-sliit.blogspot.com/2014/02/cannot-login-to-games-for-windows-live.html</link><author>noreply@blogger.com (my node)</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-5813540589519490137.post-8019994839551364222</guid><pubDate>Thu, 06 Feb 2014 14:12:00 +0000</pubDate><atom:updated>2014-02-07T02:04:26.233+05:30</atom:updated><category domain="http://www.blogger.com/atom/ns#">Feathercoin</category><category domain="http://www.blogger.com/atom/ns#">HD 7750</category><title>HD 7750 cypto coin mining experience</title><description>HD 7750 is a entry level card for mining any kind of coin. suitable for casual mining while you do other stuff in the pc. I mine&amp;nbsp;Feathercoin (FTC) as it has a very low difficulty but I think Litecoin will give the same return when converted to Bitcoins. I get around 2.5FTC per day with wemineftc.com pool.&lt;br /&gt;
&lt;br /&gt;
My HD 7750 punch 134 khash/s on Intensity level of 13 in GUIminer-scrypt&lt;br /&gt;
GPU clock increased to 825MHz (core speed 800)&lt;br /&gt;
Memory clock speed decreased to 700Mhz to reduce temperature. you can change card settings using amd catalyst control center.&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjQpo66NIVKdH4Zgu3kXCK09RZPsw0QcayuJ1MaCOKmyTBR3lTrOvTupiOL_VXBbZZCZZWQ3REyAxc7CVAczLb0lkIjdl392QxSLi0HJ_lmh8IOiQ2DQo3fiLtccZ5wXfSjL_wlcCxh2zrb/s1600/hd7750-guiminer.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjQpo66NIVKdH4Zgu3kXCK09RZPsw0QcayuJ1MaCOKmyTBR3lTrOvTupiOL_VXBbZZCZZWQ3REyAxc7CVAczLb0lkIjdl392QxSLi0HJ_lmh8IOiQ2DQo3fiLtccZ5wXfSjL_wlcCxh2zrb/s1600/hd7750-guiminer.png&quot; height=&quot;282&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;br /&gt;
It can easily go over 150 Khash/s with more GPU overclocking and increasing the intensity level. I haven&#39;t tried to push the card that far since increase core speed make temperature go over the roof.</description><link>http://my-sliit.blogspot.com/2014/02/hd-7750-cypto-coin-mining-experience.html</link><author>noreply@blogger.com (my node)</author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjQpo66NIVKdH4Zgu3kXCK09RZPsw0QcayuJ1MaCOKmyTBR3lTrOvTupiOL_VXBbZZCZZWQ3REyAxc7CVAczLb0lkIjdl392QxSLi0HJ_lmh8IOiQ2DQo3fiLtccZ5wXfSjL_wlcCxh2zrb/s72-c/hd7750-guiminer.png" height="72" width="72"/><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-5813540589519490137.post-5386388423119721135</guid><pubDate>Wed, 05 Feb 2014 20:32:00 +0000</pubDate><atom:updated>2014-02-06T02:03:56.092+05:30</atom:updated><title>How to get all results without the first row from a MySQL table </title><description>To exclude first row you have to use MySQL limit clause.&lt;br /&gt;
&lt;br /&gt;
&lt;pre style=&quot;background-color: #eeeeee; border: 1px dashed #999999; color: black; font-family: Andale Mono, Lucida Console, Monaco, fixed, monospace; font-size: 12px; line-height: 14px; overflow: auto; padding: 5px; width: 100%;&quot;&gt;select * from table limit 1, 10000000&lt;/pre&gt;
&lt;br /&gt;
You can pass 2 values to limit clause first one is the starting row. Row index start with 0 so you have to put 1 to remove first row.
Second parameter is the number of result u need to retrieve. Put a number that is larger than max rows of table.
</description><link>http://my-sliit.blogspot.com/2014/02/how-to-get-all-results-from-mysql-table.html</link><author>noreply@blogger.com (my node)</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-5813540589519490137.post-8903092301863169013</guid><pubDate>Sat, 14 Sep 2013 19:14:00 +0000</pubDate><atom:updated>2013-09-15T00:44:03.056+05:30</atom:updated><title>Disable other_vhosts_access.log in ubuntu</title><description>Check the following location for apache2.conf and other-vhost-access-log&lt;br /&gt;
/etc/apache2/apache2.conf&lt;br /&gt;
/etc/apache2/conf.d/other-vhost-access-log&lt;br /&gt;
&lt;br /&gt;
Open those files and check for the line with&amp;nbsp;other_vhosts_access.log and comment them out with # sign in front of the line.&lt;br /&gt;
&lt;br /&gt;
Restart Apache.</description><link>http://my-sliit.blogspot.com/2013/09/disable-othervhostsaccesslog-in-ubuntu.html</link><author>noreply@blogger.com (my node)</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-5813540589519490137.post-8971804615818277473</guid><pubDate>Sun, 31 Mar 2013 20:32:00 +0000</pubDate><atom:updated>2013-05-13T11:42:28.433+05:30</atom:updated><category domain="http://www.blogger.com/atom/ns#">MOOV-Atom</category><category domain="http://www.blogger.com/atom/ns#">mp4</category><title>Fixing MP4 not playing until full video loads in browser</title><description>I had a problem where my mp4 videos were not played by video.js player until the video was fully downloaded by the browser. after some searching I found out it was because mp4 file metadata ( moov atom) is on the end of the file and the player cannot&amp;nbsp;locate&amp;nbsp;it for streaming when&amp;nbsp;initially&amp;nbsp;played.&lt;br /&gt;
&lt;br /&gt;
I was saved by this small php  library&amp;nbsp;&lt;a href=&quot;http://code.google.com/p/moovrelocator/&quot;&gt;http://code.google.com/p/moovrelocator/&lt;/a&gt;&lt;br /&gt;
This will read a video and move MOOV-Atom to the front of the mp4 file.&lt;br /&gt;
&lt;br /&gt;
there is a demo in _demo folder. if you get errors finding the paths, try giving direct paths like this in index.php&lt;br /&gt;
&lt;br /&gt;
$inFile  = &#39;../../videos/&#39;.$tempv;&lt;br /&gt;
// output (processed file)&lt;br /&gt;
$outFile = &#39;../../new_videos/&#39;.$tempv;

&lt;br /&gt;
&lt;br /&gt;
if you get zend errors try giving direct paths in&amp;nbsp;Moovrelocator.class.php&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
// atom poc class&lt;br /&gt;
require_once &#39;atom/Atom.class.php&#39;;&lt;br /&gt;
&lt;br /&gt;
// bytearray to operate direct on bytes in memory just to simulate Adobe&#39;s AS3 Bytearray&lt;br /&gt;
require_once &#39;bytes/Bytearray.class.php&#39;;&lt;br /&gt;
&lt;br /&gt;
// transform (taken from php-reader)&lt;br /&gt;
require_once &#39;bytes/Transform.class.php&#39;;&lt;br /&gt;
&lt;br /&gt;
you may also want to change your php.ini max execute time and memory use if you are looping through lot of videos in a folder.</description><link>http://my-sliit.blogspot.com/2013/04/fixing-mp4-not-playing-until-full-video.html</link><author>noreply@blogger.com (my node)</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-5813540589519490137.post-3799735457136896263</guid><pubDate>Sat, 27 Oct 2012 19:52:00 +0000</pubDate><atom:updated>2012-10-28T01:32:19.422+05:30</atom:updated><title>php file upload error messages in a php array</title><description>Hope this will be useful to someone, all the php file upload error codes and messages in an array.

&lt;br /&gt;
&lt;br /&gt;
&lt;pre style=&quot;background-color: #eeeeee; border: 1px dashed #999999; color: black; font-family: Andale Mono, Lucida Console, Monaco, fixed, monospace; font-size: 12px; line-height: 14px; overflow: auto; padding: 5px; width: 100%;&quot;&gt;&amp;lt;?php

$error_codes = array(
        0=&amp;gt;&quot;There is no error, the file uploaded with success&quot;,
        1=&amp;gt;&quot;The uploaded file exceeds the upload_max_filesize directive in php.ini&quot;,
        2=&amp;gt;&quot;The uploaded file exceeds the MAX_FILE_SIZE directive that was specified in the HTML form&quot;,
        3=&amp;gt;&quot;The uploaded file was only partially uploaded&quot;,
        4=&amp;gt;&quot;No file was uploaded&quot;,
        6=&amp;gt;&quot;Missing a temporary folder&quot;,
        7=&amp;gt;&quot;Failed to write file to disk&quot;,
        8=&amp;gt;&quot;A PHP extension stopped the file upload&quot;
);

/* Posssible Usage */

if($_FILES[&quot;userfile&quot;][&quot;error&quot;] &amp;gt; 0){
   
  $code = $_FILES[&quot;userfile&quot;][&quot;error&quot;];
  echo $error_codes[$code];
}
else{
 
 //do the processing
}
 
?&amp;gt;&lt;/pre&gt;
</description><link>http://my-sliit.blogspot.com/2012/10/php-file-upload-error-messages-in-php.html</link><author>noreply@blogger.com (my node)</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-5813540589519490137.post-4710936109991959035</guid><pubDate>Tue, 23 Oct 2012 13:15:00 +0000</pubDate><atom:updated>2012-10-23T18:45:55.789+05:30</atom:updated><title>How to change default timezone in Ubuntu command-line</title><description>In a Ubuntu / Debian based Linux system you can use the following command to run the timezone setup to change the default timezone

&lt;pre style=&quot;background-color: #eeeeee; border: 1px dashed #999999; color: black; font-family: Andale Mono, Lucida Console, Monaco, fixed, monospace; font-size: 12px; line-height: 14px; overflow: auto; padding: 5px; width: 100%;&quot;&gt;dpkg-reconfigure tzdata
&lt;/pre&gt;</description><link>http://my-sliit.blogspot.com/2012/10/how-to-change-default-timezone-in.html</link><author>noreply@blogger.com (my node)</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-5813540589519490137.post-99295797684369055</guid><pubDate>Sun, 21 Oct 2012 19:56:00 +0000</pubDate><atom:updated>2012-10-22T01:26:39.728+05:30</atom:updated><category domain="http://www.blogger.com/atom/ns#">KeepAliveTimeout</category><category domain="http://www.blogger.com/atom/ns#">linode</category><category domain="http://www.blogger.com/atom/ns#">swapping</category><title>High Swapping On Linode 512 - KeepAliveTimeout</title><description>I thought of sharing my experience on handling the high swapping issue I faced recently. There is nothing wrong with Linode service, its just my dumb Apache configurations.&lt;br /&gt;&lt;br /&gt;

Linode is a great hosting service but for a Linux administration newbie it can be a challenging place.&lt;br /&gt;&lt;br /&gt;

Swapping problem was a nightmare, I tried adding another 512MB to the Linode box and still it goes into full swap. Then I get to know about the Apache KeepAliveTimeout.&lt;br /&gt;&lt;br /&gt;

KeepAliveTimeout - Amount of time the server will wait for subsequent requests on a persistent connection.&lt;br /&gt;&lt;br /&gt;

Unfortunately for me the default value was 15 which is a super high value. After changing the value to 4 all was smooth again.&lt;br /&gt;&lt;br /&gt;

Swapping can occur for many reasons like bad scripting but KeepAliveTimeout value can be a main suspect :)&lt;br /&gt;</description><link>http://my-sliit.blogspot.com/2012/10/high-swapping-on-linode-512.html</link><author>noreply@blogger.com (my node)</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-5813540589519490137.post-8427672520349096522</guid><pubDate>Tue, 16 Oct 2012 12:08:00 +0000</pubDate><atom:updated>2012-10-16T23:01:10.059+05:30</atom:updated><title>How to check and fix Domain Canonicalization (www)</title><description>It&#39;s a common configuration in web servers to point both urls of www.example.com and example.com to same content. This is a bad practice in terms of SEO because they regarded as duplicate content. If you have access to the .htaccess and assuming your Apache server has mod_rewrite enabled, you can add following lines to redirect traffic and issue a 301 (Moved Permanently).&lt;br /&gt;
I prefer my site addresses without www&lt;br /&gt;
&lt;pre style=&quot;background-color: #eeeeee; border: 1px dashed #999999; color: black; font-family: Andale Mono, Lucida Console, Monaco, fixed, monospace; font-size: 12px; line-height: 14px; overflow: auto; padding: 5px; width: 100%;&quot;&gt;
RewriteEngine On&lt;br /&gt;
RewriteCond %{HTTP_HOST} !^example.com [NC]&lt;br /&gt;
RewriteRule ^(.*)$ http://example.com/$1 [L,R=301]&lt;br /&gt;
&lt;/pre&gt;
&lt;br /&gt;
If you like to have your addresses with www use the following&lt;br /&gt;
&lt;pre style=&quot;background-color: #eeeeee; border: 1px dashed #999999; color: black; font-family: Andale Mono, Lucida Console, Monaco, fixed, monospace; font-size: 12px; line-height: 14px; overflow: auto; padding: 5px; width: 100%;&quot;&gt;
RewriteEngine On&lt;br /&gt;
RewriteCond %{HTTP_HOST} !^www.example.com [NC]&lt;br /&gt;
RewriteRule ^(.*)$ http://www.example.com/$1 [L,R=301]&lt;br /&gt;&lt;/pre&gt;
&lt;br /&gt;
If you have any sub domains like blog.example.com do not use the above code.</description><link>http://my-sliit.blogspot.com/2012/10/how-to-check-and-fix-domain.html</link><author>noreply@blogger.com (my node)</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-5813540589519490137.post-5819152144251180078</guid><pubDate>Tue, 07 Aug 2012 03:27:00 +0000</pubDate><atom:updated>2012-08-07T09:07:04.922+05:30</atom:updated><title>How to find MPM mode of Apache - Prefork or Worker</title><description>to find the Apache MPM mode you can simply run following command.&lt;br /&gt;
&lt;br /&gt;
in Ubuntu u can try&lt;br /&gt;
&lt;pre style=&quot;background-color: #eeeeee; border: 1px dashed #999999; color: black; font-family: Andale Mono, Lucida Console, Monaco, fixed, monospace; font-size: 12px; line-height: 14px; overflow: auto; padding: 5px; width: 100%;&quot;&gt;apache2 -V&lt;/pre&gt;
&lt;br /&gt;
in CentOS type of linux u can try

&lt;br /&gt;
&lt;pre style=&quot;background-color: #eeeeee; border: 1px dashed #999999; color: black; font-family: Andale Mono, Lucida Console, Monaco, fixed, monospace; font-size: 12px; line-height: 14px; overflow: auto; padding: 5px; width: 100%;&quot;&gt;httpd -V&lt;/pre&gt;</description><link>http://my-sliit.blogspot.com/2012/08/how-to-find-mpm-mode-of-apache-prefork.html</link><author>noreply@blogger.com (my node)</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-5813540589519490137.post-4648600414788201031</guid><pubDate>Thu, 10 Feb 2011 07:18:00 +0000</pubDate><atom:updated>2011-02-10T12:48:30.428+05:30</atom:updated><title>How to fix gd-jpeg, libjpeg: recoverable error: Premature end of JPEG file</title><description>Sometimes php will through a error when using the imagecreatefromjpeg() for some jpge images saved by cameras and photo editing softwares. When I search the internet for a solution I found this great article which fix the problem &lt;a href=&quot;http://worcesterwideweb.com/2008/03/17/php-5-and-imagecreatefromjpeg-recoverable-error-premature-end-of-jpeg-file/&quot;&gt;http://worcesterwideweb.com/2008/03/17/php-5-and-imagecreatefromjpeg-recoverable-error-premature-end-of-jpeg-file/&lt;/a&gt;</description><link>http://my-sliit.blogspot.com/2011/02/how-to-fix-gd-jpeg-libjpeg-recoverable.html</link><author>noreply@blogger.com (my node)</author><thr:total>1</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-5813540589519490137.post-5992098037534040582</guid><pubDate>Thu, 13 Jan 2011 13:33:00 +0000</pubDate><atom:updated>2011-01-13T19:03:01.912+05:30</atom:updated><title>How to loop A-Z in php</title><description>Just like counting numbers :)&lt;br /&gt;
&lt;br /&gt;
&lt;pre style=&quot;font-family: Andale Mono, Lucida Console, Monaco, fixed, monospace; color: #000000; background-color: #eee;font-size: 12px;border: 1px dashed #999999;line-height: 14px;padding: 5px; overflow: auto; width: 100%&quot;&gt;&lt;code&gt;$letter = &amp;quot;A&amp;quot;;
for($i = 1; $i&amp;lt;= 26; $i++)
{
  $letter++;
  echo $letter;
}
&lt;/code&gt;&lt;/pre&gt;</description><link>http://my-sliit.blogspot.com/2011/01/how-to-loop-z-in-php.html</link><author>noreply@blogger.com (my node)</author><thr:total>2</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-5813540589519490137.post-5715111449989426119</guid><pubDate>Fri, 24 Sep 2010 20:52:00 +0000</pubDate><atom:updated>2010-09-25T02:22:21.493+05:30</atom:updated><category domain="http://www.blogger.com/atom/ns#">HTML Tidy</category><title>Cannot make the website html validate? try HTML Tidy</title><description>Sometimes you cannot seems to find the line where the validation errors come from. In such cases you can try using HTML Tidy to do a auto clean up.&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;a target=&quot;_blank&quot; href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjAyLxwiomMf8bvYoTE18eqQv0Atu6RLwBBXHqoOq-3mC8nzAbc8HZHcAB5aWep3q3k5HiWMnCHr3K95T6nrK1LZTe3htPhbDSYCWDFKUF0lk8moe9JE_vA0R83EMgvkPGYfcT5UmPRu3gx/s1600/htmltidy.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;131&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjAyLxwiomMf8bvYoTE18eqQv0Atu6RLwBBXHqoOq-3mC8nzAbc8HZHcAB5aWep3q3k5HiWMnCHr3K95T6nrK1LZTe3htPhbDSYCWDFKUF0lk8moe9JE_vA0R83EMgvkPGYfcT5UmPRu3gx/s400/htmltidy.png&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;
&lt;br /&gt;
W3C Markup Validation Service also has this option. or you an check out the project page.&lt;br /&gt;
&lt;br /&gt;
&lt;a target=&quot;_blank&quot; href=&quot;http://tidy.sourceforge.net/&quot;&gt;http://tidy.sourceforge.net/&lt;/a&gt;</description><link>http://my-sliit.blogspot.com/2010/09/cannot-make-website-html-validate-try.html</link><author>noreply@blogger.com (my node)</author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjAyLxwiomMf8bvYoTE18eqQv0Atu6RLwBBXHqoOq-3mC8nzAbc8HZHcAB5aWep3q3k5HiWMnCHr3K95T6nrK1LZTe3htPhbDSYCWDFKUF0lk8moe9JE_vA0R83EMgvkPGYfcT5UmPRu3gx/s72-c/htmltidy.png" height="72" width="72"/><thr:total>1</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-5813540589519490137.post-5652069635941930933</guid><pubDate>Tue, 07 Sep 2010 10:39:00 +0000</pubDate><atom:updated>2010-09-07T16:09:04.345+05:30</atom:updated><title>Magento Video Tutorials: Thanks Armando Roggio :)</title><description>Cannot express how greatful I am to this guy. &lt;a target=&quot;_blank&quot; href=&quot;http://www.ecommercedeveloper.com/articles/1540-Building-a-Magento-Theme-Start-to-Finish-Part-One-Prolegomena&quot;&gt;http://www.ecommercedeveloper.com/articles/1540-Building-a-Magento-Theme-Start-to-Finish-Part-One-Prolegomena&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
I tried to start Magento several times and just got frustrated with the issues with locahost and complex nature of the file structure.&lt;br /&gt;
but thanks to above tutorial Magento is like riding a bike.&lt;br /&gt;
&lt;br /&gt;
Videos are on version 1.3 but after reading this note about version 1.4 you can follow the tutorials easily on 1.4&lt;br /&gt;
&lt;br /&gt;
&lt;a target=&quot;_blank&quot; href=&quot;http://www.magentocommerce.com/wiki/4_-_themes_and_template_customization/0_-_theming_in_magento/magento_theme_hierarchy-changes_in_cev1.4_and_eev1.8&quot;&gt;Magento&#39;s Theme Hierarchy--Changes in CEv1.4 and EEv1.8&lt;/a&gt;</description><link>http://my-sliit.blogspot.com/2010/09/magento-video-tutorials-thanks-armando.html</link><author>noreply@blogger.com (my node)</author><thr:total>1</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-5813540589519490137.post-1027787690022244769</guid><pubDate>Thu, 02 Sep 2010 10:14:00 +0000</pubDate><atom:updated>2010-09-02T15:44:03.263+05:30</atom:updated><category domain="http://www.blogger.com/atom/ns#">Mangento</category><title>Mangento Sample Data - 404 Page Error</title><description>I see few solutions for this error in the web but for me following steps corrected my error.&lt;br /&gt;
Magento Version - 1.4.1.1&lt;br /&gt;
&lt;br /&gt;
Admin -&gt; System -&gt; Index Management -&gt; Reindex all given Indexes</description><link>http://my-sliit.blogspot.com/2010/09/mangento-sample-data-404-page-error.html</link><author>noreply@blogger.com (my node)</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-5813540589519490137.post-942886812333699168</guid><pubDate>Wed, 01 Sep 2010 19:57:00 +0000</pubDate><atom:updated>2010-09-02T01:27:30.049+05:30</atom:updated><category domain="http://www.blogger.com/atom/ns#">City</category><category domain="http://www.blogger.com/atom/ns#">District</category><category domain="http://www.blogger.com/atom/ns#">SQL</category><category domain="http://www.blogger.com/atom/ns#">Sri Lanka</category><title>Sri Lanka District and City List Sql File</title><description>For a recent project I had to find all the Sri Lankan District and related Cities to populate in two drop downs. The list is not fully complete and Kilinochchi District is not in the list.&lt;br /&gt;
Districts - 24&lt;br /&gt;
Cities - 2044&lt;br /&gt;
&lt;br /&gt;
Two tables, city table refer district table by did.&lt;br /&gt;
&lt;br /&gt;
&lt;a target=&quot;_blank&quot; href=&quot;http://www.mediafire.com/?361om4s8bvj6kmj&quot;&gt;Download Sri Lankan District - City Sql file&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
You can easily import this sql file to mysql using phpmyadmin.</description><link>http://my-sliit.blogspot.com/2010/09/sri-lanka-district-and-city-list-sql.html</link><author>noreply@blogger.com (my node)</author><thr:total>25</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-5813540589519490137.post-1599283279867276435</guid><pubDate>Tue, 31 Aug 2010 18:05:00 +0000</pubDate><atom:updated>2010-08-31T23:35:11.281+05:30</atom:updated><category domain="http://www.blogger.com/atom/ns#">mysql</category><category domain="http://www.blogger.com/atom/ns#">PHP</category><title>Mysql insert multiple/batch of rows using single query</title><description>You don&#39;t need to loop a mysql insert query to add multiple records to a table. mysql insert support multiple inserts in one query.&lt;br /&gt;
&lt;br /&gt;
Let say you have a table called students with two fields fname and age. &lt;br /&gt;
&lt;br /&gt;
&lt;pre style=&quot;background-color: #eeeeee; border: 1px dashed #999999; color: black; font-family: Andale Mono, Lucida Console, Monaco, fixed, monospace; font-size: 12px; line-height: 14px; overflow: auto; padding: 5px; width: 100%;&quot;&gt;&lt;code&gt;insert into students (fname, age) values
(&#39;Kusal&#39;, &#39;26&#39;),
(&#39;Tom&#39;, &#39;18&#39;),
(&#39;Ann&#39;, &#39;23&#39;)
&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;
Remember to give the column names in the query.&lt;br /&gt;
&lt;br /&gt;
&lt;iframe align=&quot;left&quot; frameborder=&quot;0&quot; marginheight=&quot;0&quot; marginwidth=&quot;0&quot; scrolling=&quot;no&quot; src=&quot;http://rcm.amazon.com/e/cm?t=whiswh-20&amp;amp;o=1&amp;amp;p=8&amp;amp;l=bpl&amp;amp;asins=0672329166&amp;amp;fc1=000000&amp;amp;IS2=1&amp;amp;lt1=_blank&amp;amp;m=amazon&amp;amp;lc1=0000FF&amp;amp;bc1=000000&amp;amp;bg1=FFFFFF&amp;amp;f=ifr&quot; style=&quot;align: left; height: 245px; padding-right: 10px; padding-top: 5px; width: 131px;&quot;&gt;&lt;/iframe&gt;</description><link>http://my-sliit.blogspot.com/2010/08/mysql-insert-multiplebatch-of-rows.html</link><author>noreply@blogger.com (my node)</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-5813540589519490137.post-2327842339294967301</guid><pubDate>Mon, 30 Aug 2010 21:53:00 +0000</pubDate><atom:updated>2011-03-16T12:51:52.483+05:30</atom:updated><category domain="http://www.blogger.com/atom/ns#">jQuery</category><title>Quick, Simple and Easy Image Gallery Using jQuery</title><description>This is a simple image gallery I wrote for a project. Its small and easy to implement. Ideal if you need to build a simple and quick gallery.&lt;br /&gt;
You can improve the code by adding a loading.gif&lt;br /&gt;
&lt;br /&gt;
&lt;pre style=&quot;background-color: #eeeeee; border: 1px dashed #999999; color: black; font-family: Andale Mono, Lucida Console, Monaco, fixed, monospace; font-size: 12px; line-height: 14px; overflow: auto; padding: 5px; width: 100%;&quot;&gt;&lt;code&gt;&amp;lt;!DOCTYPE html PUBLIC &quot;-//W3C//DTD XHTML 1.0 Transitional//EN&quot; &quot;http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd&quot;&amp;gt;
&amp;lt;html xmlns=&quot;http://www.w3.org/1999/xhtml&quot;&amp;gt;
&amp;lt;head&amp;gt;
&amp;lt;meta http-equiv=&quot;Content-Type&quot; content=&quot;text/html; charset=utf-8&quot; /&amp;gt;
&amp;lt;title&amp;gt;How to add table rows using jQuery&amp;lt;/title&amp;gt;
&amp;lt;style&amp;gt;
.thumb{vertical-align:top; padding:2px; border:1px #CCC solid;}
&amp;lt;/style&amp;gt;
&amp;lt;script type=&quot;text/javascript&quot; src=&quot;http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js&quot;&amp;gt;&amp;lt;/script&amp;gt;
&amp;lt;script&amp;gt;

$(document).ready(function(){    
    
    $(&quot;.image&quot;).click(function() {    
        //$(&#39;#main&#39;).hide();
        var image = $(this).attr(&quot;href&quot;);
        $(&#39;#main&#39;).attr(&quot;src&quot;, image);
                
        $(&#39;#main&#39;).load(function() {            
              $(&#39;#main&#39;).fadeIn(&#39;slow&#39;);
        });
        
    return false;
    });
});    

&amp;lt;/script&amp;gt;
&amp;lt;/head&amp;gt;

&amp;lt;body&amp;gt;
&amp;lt;a href=&quot;images/image1.jpg&quot; class=&quot;image&quot;&amp;gt;&amp;lt;img alt=&quot;Image1&quot; src=&quot;thumb/image1.jpg&quot; class=&quot;thumb&quot; border=&quot;0&quot;/&amp;gt;&amp;lt;/a&amp;gt;
&amp;lt;a href=&quot;images/image2.jpg&quot; class=&quot;image&quot;&amp;gt;&amp;lt;img alt=&quot;Image2&quot; src=&quot;thumb/image2.jpg&quot; class=&quot;thumb&quot; border=&quot;0&quot;/&amp;gt;&amp;lt;/a&amp;gt;
&amp;lt;a href=&quot;images/image3.jpg&quot; class=&quot;image&quot;&amp;gt;&amp;lt;img alt=&quot;Image3&quot; src=&quot;thumb/image3.jpg&quot; class=&quot;thumb&quot; border=&quot;0&quot;/&amp;gt;&amp;lt;/a&amp;gt;
&amp;lt;a href=&quot;images/image4.jpg&quot; class=&quot;image&quot;&amp;gt;&amp;lt;img alt=&quot;Image4&quot; src=&quot;thumb/image4.jpg&quot; class=&quot;thumb&quot; border=&quot;0&quot;/&amp;gt;&amp;lt;/a&amp;gt;
&amp;lt;div id=&quot;container&quot; style=&quot;height:400px; padding-top:20px;&quot;&amp;gt;&amp;lt;img id=&quot;main&quot; src=&quot;images/image1.jpg&quot; /&amp;gt;&amp;lt;/div&amp;gt;

&amp;lt;/body&amp;gt;
&amp;lt;/html&amp;gt;

&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;
&lt;a href=&quot;http://kuppiya.com/demo/easy_simple_gallery_jquery/&quot; target=&quot;_blank&quot;&gt;View Demo&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;div style=&quot;text-align: center;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;text-align: center;&quot;&gt;&lt;iframe frameborder=&quot;0&quot; marginheight=&quot;0&quot; marginwidth=&quot;0&quot; scrolling=&quot;no&quot; src=&quot;http://rcm.amazon.com/e/cm?t=whiswh-20&amp;amp;o=1&amp;amp;p=8&amp;amp;l=bpl&amp;amp;asins=0596159773&amp;amp;fc1=000000&amp;amp;IS2=1&amp;amp;lt1=_blank&amp;amp;m=amazon&amp;amp;lc1=0000FF&amp;amp;bc1=000000&amp;amp;bg1=FFFFFF&amp;amp;f=ifr&quot; style=&quot;height: 245px; padding-right: 10px; padding-top: 5px; text-align: left; width: 131px;&quot;&gt;&lt;/iframe&gt;&lt;/div&gt;</description><link>http://my-sliit.blogspot.com/2010/08/quick-simple-and-easy-image-gallery.html</link><author>noreply@blogger.com (my node)</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-5813540589519490137.post-3130395460185118294</guid><pubDate>Sun, 29 Aug 2010 17:17:00 +0000</pubDate><atom:updated>2010-08-29T22:47:42.510+05:30</atom:updated><category domain="http://www.blogger.com/atom/ns#">fadeIn</category><category domain="http://www.blogger.com/atom/ns#">jQuery</category><title>Wait till a dynamically loaded image fully load using jQuery</title><description>I had this problem when I was creating simple jQuery gallery with thumbs. Once the thumb is clicked I wanted to wait till the image is fully loaded until I called the fadeIn. &lt;br /&gt;
we can use jQuery load to achieve this.&lt;br /&gt;
&lt;br /&gt;
&lt;pre style=&quot;font-family: Andale Mono, Lucida Console, Monaco, fixed, monospace; color: #000000; background-color: #eee;font-size: 12px;border: 1px dashed #999999;line-height: 14px;padding: 5px; overflow: auto; width: 100%&quot;&gt;&lt;code&gt;$(&#39;#image&#39;).hide();
$(&#39;#image&#39;).attr(&amp;quot;src&amp;quot;, image); //next image path
//still in hide
$(&#39;#image&#39;).load(function() {    
    $(&#39;#image&#39;).fadeIn(&#39;slow&#39;);
});        
&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;
&lt;div style=&quot;text-align: center;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;text-align: center;&quot;&gt;&lt;iframe frameborder=&quot;0&quot; marginheight=&quot;0&quot; marginwidth=&quot;0&quot; scrolling=&quot;no&quot; src=&quot;http://rcm.amazon.com/e/cm?t=whiswh-20&amp;amp;o=1&amp;amp;p=8&amp;amp;l=bpl&amp;amp;asins=0980576857&amp;amp;fc1=000000&amp;amp;IS2=1&amp;amp;lt1=_blank&amp;amp;m=amazon&amp;amp;lc1=0000FF&amp;amp;bc1=000000&amp;amp;bg1=FFFFFF&amp;amp;f=ifr&quot; style=&quot;height: 245px; padding-right: 10px; padding-top: 5px; text-align: left; width: 131px;&quot;&gt;&lt;/iframe&gt;&lt;/div&gt;</description><link>http://my-sliit.blogspot.com/2010/08/wait-till-dynamically-loaded-image.html</link><author>noreply@blogger.com (my node)</author><thr:total>4</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-5813540589519490137.post-2676549135148704365</guid><pubDate>Sat, 28 Aug 2010 20:59:00 +0000</pubDate><atom:updated>2010-08-29T02:30:25.414+05:30</atom:updated><category domain="http://www.blogger.com/atom/ns#">JavaScript</category><title>How to round numbers in JavaScript</title><description>JavaScript number rounding is done using Math.round&lt;br /&gt;
This will round a given number to the nearest whole number&lt;br /&gt;
&lt;br /&gt;
&lt;pre style=&quot;font-family: Andale Mono, Lucida Console, Monaco, fixed, monospace; color: #000000; background-color: #eee;font-size: 12px;border: 1px dashed #999999;line-height: 14px;padding: 5px; overflow: auto; width: 100%&quot;&gt;&lt;code&gt;&amp;lt;script type=&amp;quot;text/javascript&amp;quot;&amp;gt;

var number = 100.58;
number = Math.round(number);
alert(number); //101

&amp;lt;/script&amp;gt;
&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;
&lt;br /&gt;
If you do need some decimal points preserved, following code will round the number to the nearest tenth.&lt;br /&gt;
&lt;br /&gt;
&lt;pre style=&quot;font-family: Andale Mono, Lucida Console, Monaco, fixed, monospace; color: #000000; background-color: #eee;font-size: 12px;border: 1px dashed #999999;line-height: 14px;padding: 5px; overflow: auto; width: 100%&quot;&gt;&lt;code&gt;&amp;lt;script type=&amp;quot;text/javascript&amp;quot;&amp;gt;

var number = 100.58;
number = Math.round(number*10)/10;
alert(number); //100.6

&amp;lt;/script&amp;gt;
&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;
&lt;div style=&quot;text-align: center;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;text-align: center;&quot;&gt;&lt;iframe frameborder=&quot;0&quot; marginheight=&quot;0&quot; marginwidth=&quot;0&quot; scrolling=&quot;no&quot; src=&quot;http://rcm.amazon.com/e/cm?t=whiswh-20&amp;amp;o=1&amp;amp;p=8&amp;amp;l=bpl&amp;amp;asins=0071632956&amp;amp;fc1=000000&amp;amp;IS2=1&amp;amp;lt1=_blank&amp;amp;m=amazon&amp;amp;lc1=0000FF&amp;amp;bc1=000000&amp;amp;bg1=FFFFFF&amp;amp;f=ifr&quot; style=&quot;height: 245px; padding-right: 10px; padding-top: 5px; text-align: left; width: 131px;&quot;&gt;&lt;/iframe&gt;&lt;/div&gt;</description><link>http://my-sliit.blogspot.com/2010/08/how-to-round-numbers-in-javascript.html</link><author>noreply@blogger.com (my node)</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-5813540589519490137.post-6402014419912305045</guid><pubDate>Sat, 28 Aug 2010 18:44:00 +0000</pubDate><atom:updated>2010-08-29T00:16:00.718+05:30</atom:updated><category domain="http://www.blogger.com/atom/ns#">JavaScript</category><title>Javascript Go Back Link With History</title><description>Here is a really easy way to add a go back link to your page navigation.&lt;br /&gt;
This code uses JavaScript to get the browser history for the specific site.&lt;br /&gt;
&lt;br /&gt;
&lt;pre style=&quot;font-family: Andale Mono, Lucida Console, Monaco, fixed, monospace; color: #000000; background-color: #eee;font-size: 12px;border: 1px dashed #999999;line-height: 14px;padding: 5px; overflow: auto; width: 100%&quot;&gt;&lt;code&gt;&amp;lt;a href=&amp;quot;#&amp;quot; onClick=&amp;quot;history.go(-1)&amp;quot;&amp;gt;Back&amp;lt;/a&amp;gt; 
&amp;lt;input type=button value=&amp;quot;Back&amp;quot; onClick=&amp;quot;history.go(-1)&amp;quot;&amp;gt;
&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;
&lt;br /&gt;
You can change the -1 to any number of pages you need to go back in history :D&lt;br /&gt;
&lt;br /&gt;
&lt;iframe src=&quot;http://rcm.amazon.com/e/cm?t=whiswh-20&amp;o=1&amp;p=8&amp;l=bpl&amp;asins=0596101996&amp;fc1=000000&amp;IS2=1&amp;lt1=_blank&amp;m=amazon&amp;lc1=0000FF&amp;bc1=000000&amp;bg1=FFFFFF&amp;f=ifr&quot; style=&quot;align:left;padding-top:5px;width:131px;height:245px;padding-right:10px;&quot;align=&quot;left&quot; scrolling=&quot;no&quot; marginwidth=&quot;0&quot; marginheight=&quot;0&quot; frameborder=&quot;0&quot;&gt;&lt;/iframe&gt;</description><link>http://my-sliit.blogspot.com/2010/08/javascript-go-back-link-with-history.html</link><author>noreply@blogger.com (my node)</author><thr:total>0</thr:total></item></channel></rss>