<?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"
	>

<channel>
	<title>Remember the code?</title>
	<atom:link href="http://code.neox.net/feed/" rel="self" type="application/rss+xml" />
	<link>http://code.neox.net</link>
	<description>a place where I store my secret powerful coding snippets, or just to remember how to do things</description>
	<pubDate>Wed, 25 Jun 2008 17:20:59 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.5.1</generator>
	<language>en</language>
			<item>
		<title>hosting migration - moving email data from Mbox to Maildir</title>
		<link>http://code.neox.net/2008/06/25/hosting-server-migration-moving-email-data/</link>
		<comments>http://code.neox.net/2008/06/25/hosting-server-migration-moving-email-data/#comments</comments>
		<pubDate>Wed, 25 Jun 2008 17:11:47 +0000</pubDate>
		<dc:creator>HanaDaddy</dc:creator>
		
		<category><![CDATA[system]]></category>

		<category><![CDATA[imap]]></category>

		<category><![CDATA[maildir]]></category>

		<category><![CDATA[mbox]]></category>

		<guid isPermaLink="false">http://code.neox.net/?p=36</guid>
		<description><![CDATA[Recently I moved to a new hosting provider . It&#8217;s much better than the previous one.  I used to use a dedicated server but I have no time to take care the server and softwares and it was much expensive anyway. This new server provides cpanel and I like it . Its easy to [...]]]></description>
			<content:encoded><![CDATA[<p>Recently I moved to a new hosting provider . It&#8217;s much better than the previous one.  I used to use a dedicated server but I have no time to take care the server and softwares and it was much expensive anyway. This new server provides cpanel and I like it . Its easy to use and provides powerful functions. </p>
<p>But there was no function to migrate or import existing mails into the newly created email account. </p>
<p>So I have searched the Internet and found <a href='http://batleth.sapienti-sat.org/projects/mb2md/'>mb2md.pl</a> . Mbox to Maildir migration perl utility. You can download and save it into PATH registered folder and rename it to mb2md and <code>chmod 755 mb2md</code> to execute it.</p>
<p><strong>Inbox import </strong>: Importing <code>source_mbox_file</code> into current maildir account. Note that  <code>/home/userid/target_dir</code> is the root folder of your maildir account. You will need to use full path for both source file and target dir.</p>

<div class="wp_syntax"><div class="code"><pre>mb2md -s  /home/userid/source_mbox_file -d /home/userid/target_dir</pre></div></div>

<p><strong>Multi files in a folder</strong> : multi mbox files are located in <code>/home/userid/source_dir</code> and the <code>/home/userid/target_dir</code> is the root of your maildir account. Also you need to use full path for source and target dir.</p>

<div class="wp_syntax"><div class="code"><pre>mb2md -s /home/userid/source_dir -R -d /home/userid/target_dir</pre></div></div>

<p>After importing mutliple mboxes , you want to login to your Squirrelmail or Roundcube webmail and subscribe mailboxes to make them showing in the mailbox list.</p>
]]></content:encoded>
			<wfw:commentRss>http://code.neox.net/2008/06/25/hosting-server-migration-moving-email-data/feed/</wfw:commentRss>
		</item>
		<item>
		<title>SarahAjax Javascript Ajax Class</title>
		<link>http://code.neox.net/2008/06/03/sarahajax-javascript-ajax-class/</link>
		<comments>http://code.neox.net/2008/06/03/sarahajax-javascript-ajax-class/#comments</comments>
		<pubDate>Wed, 04 Jun 2008 03:17:17 +0000</pubDate>
		<dc:creator>HanaDaddy</dc:creator>
		
		<category><![CDATA[Javascript and CSS]]></category>

		<category><![CDATA[ajax]]></category>

		<category><![CDATA[javascript]]></category>

		<category><![CDATA[sarah]]></category>

		<guid isPermaLink="false">http://code.neox.net/?p=34</guid>
		<description><![CDATA[Download sarahajax.zip
Okay, here is my SarahAjax Javascript Class. You can use it without hassle!
You can either inherit and &#8216;action&#8217; function or by prototyping a function named &#8216;action&#8217;. &#8216;action&#8217; function will be called when the request to the resource is successful.
This is SarahAjax Class.

// 6/2/2008 HanaDaddy  hanadaddy at gmail.com
&#160;
/* SarahAjax is a very simple ajax [...]]]></description>
			<content:encoded><![CDATA[<p><a href='/sarahajax.zip'><strong>Download sarahajax.zip</strong></a></p>
<p>Okay, here is my SarahAjax Javascript Class. You can use it without hassle!</p>
<p>You can either inherit and &#8216;action&#8217; function or by prototyping a function named &#8216;action&#8217;. &#8216;action&#8217; function will be called when the request to the resource is successful.</p>
<p>This is SarahAjax Class.</p>

<div class="wp_syntax"><div class="code"><pre class="javascript"><span style="color: #009900; font-style: italic;">// 6/2/2008 HanaDaddy  hanadaddy at gmail.com</span>
&nbsp;
<span style="color: #009900; font-style: italic;">/* SarahAjax is a very simple ajax class.
 * url: target url to call. It is usally dynamic script or a simple page return xml or text.
 */</span>
<span style="color: #003366; font-weight: bold;">function</span> SarahAjax<span style="color: #66cc66;">&#40;</span>url<span style="color: #66cc66;">&#41;</span><span style="color: #66cc66;">&#123;</span>
	<span style="color: #000066; font-weight: bold;">this</span>.<span style="color: #006600;">url</span>=url;
	<span style="color: #000066; font-weight: bold;">this</span>.<span style="color: #006600;">reqobj</span> ; 
	<span style="color: #000066; font-weight: bold;">this</span>.<span style="color: #006600;">method</span>=<span style="color: #3366CC;">&quot;GET&quot;</span>;
	<span style="color: #000066; font-weight: bold;">this</span>.<span style="color: #006600;">async</span>= <span style="color: #003366; font-weight: bold;">true</span>; <span style="color: #009900; font-style: italic;">//if false , the connection will be synchronous ( you have to wait for the reply)</span>
	<span style="color: #009900; font-style: italic;">//this.action = function (obj) { }  // Success reply handler. : youre responsibilty </span>
	<span style="color: #009900; font-style: italic;">//this.error  = function (obj) { }  // Error reply handler : your responsiblity to implement.	</span>
&nbsp;
	<span style="color: #000066; font-weight: bold;">this</span>.<span style="color: #006600;">sendRequest</span> = <span style="color: #003366; font-weight: bold;">function</span><span style="color: #66cc66;">&#40;</span><span style="color: #66cc66;">&#41;</span> <span style="color: #66cc66;">&#123;</span>
		<span style="color: #000066; font-weight: bold;">if</span><span style="color: #66cc66;">&#40;</span><span style="color: #000066; font-weight: bold;">this</span>.<span style="color: #006600;">reqobj</span> == <span style="color: #003366; font-weight: bold;">null</span><span style="color: #66cc66;">&#41;</span><span style="color: #66cc66;">&#123;</span>
    			<span style="color: #000066; font-weight: bold;">if</span> <span style="color: #66cc66;">&#40;</span>window.<span style="color: #006600;">XMLHttpRequest</span><span style="color: #66cc66;">&#41;</span> <span style="color: #66cc66;">&#123;</span>
				<span style="color: #000066; font-weight: bold;">this</span>.<span style="color: #006600;">reqobj</span> = <span style="color: #003366; font-weight: bold;">new</span> XMLHttpRequest<span style="color: #66cc66;">&#40;</span><span style="color: #66cc66;">&#41;</span>;
    			<span style="color: #66cc66;">&#125;</span> <span style="color: #000066; font-weight: bold;">else</span> <span style="color: #000066; font-weight: bold;">if</span> <span style="color: #66cc66;">&#40;</span>window.<span style="color: #006600;">ActiveXObject</span><span style="color: #66cc66;">&#41;</span> <span style="color: #66cc66;">&#123;</span>
    				<span style="color: #000066; font-weight: bold;">this</span>.<span style="color: #006600;">reqobj</span> = <span style="color: #003366; font-weight: bold;">new</span> ActiveXObject<span style="color: #66cc66;">&#40;</span><span style="color: #3366CC;">&quot;Microsoft.XMLHTTP&quot;</span><span style="color: #66cc66;">&#41;</span>;
    			<span style="color: #66cc66;">&#125;</span>
		<span style="color: #66cc66;">&#125;</span>
&nbsp;
		<span style="color: #000066; font-weight: bold;">if</span> <span style="color: #66cc66;">&#40;</span><span style="color: #66cc66;">!</span><span style="color: #000066; font-weight: bold;">this</span>.<span style="color: #006600;">action</span><span style="color: #66cc66;">&#41;</span><span style="color: #66cc66;">&#123;</span>
			<span style="color: #000066;">alert</span><span style="color: #66cc66;">&#40;</span><span style="color: #3366CC;">&quot;SaraAjax:Action member function is not defined! We need the reply handler!&quot;</span><span style="color: #66cc66;">&#41;</span>;
			<span style="color: #000066; font-weight: bold;">return</span>;
		<span style="color: #66cc66;">&#125;</span>
		<span style="color: #000066; font-weight: bold;">this</span>.<span style="color: #006600;">reqobj</span>.<span style="color: #000066;">open</span><span style="color: #66cc66;">&#40;</span><span style="color: #000066; font-weight: bold;">this</span>.<span style="color: #006600;">method</span>, <span style="color: #000066; font-weight: bold;">this</span>.<span style="color: #006600;">url</span>, <span style="color: #000066; font-weight: bold;">this</span>.<span style="color: #006600;">async</span><span style="color: #66cc66;">&#41;</span>;
&nbsp;
		<span style="color: #003366; font-weight: bold;">var</span> sajaxreq = <span style="color: #000066; font-weight: bold;">this</span>; <span style="color: #009900; font-style: italic;">// this is necessary to access myself in the callback function</span>
		<span style="color: #000066; font-weight: bold;">this</span>.<span style="color: #006600;">reqobj</span>.<span style="color: #006600;">onreadystatechange</span> = <span style="color: #003366; font-weight: bold;">function</span><span style="color: #66cc66;">&#40;</span><span style="color: #66cc66;">&#41;</span> <span style="color: #66cc66;">&#123;</span> sajaxreq.<span style="color: #006600;">callback</span><span style="color: #66cc66;">&#40;</span><span style="color: #66cc66;">&#41;</span>; <span style="color: #66cc66;">&#125;</span>
&nbsp;
		<span style="color: #000066; font-weight: bold;">this</span>.<span style="color: #006600;">reqobj</span>.<span style="color: #006600;">send</span><span style="color: #66cc66;">&#40;</span><span style="color: #003366; font-weight: bold;">null</span><span style="color: #66cc66;">&#41;</span>;
	<span style="color: #66cc66;">&#125;</span>
&nbsp;
	<span style="color: #000066; font-weight: bold;">this</span>.<span style="color: #006600;">callback</span> = <span style="color: #003366; font-weight: bold;">function</span> <span style="color: #66cc66;">&#40;</span><span style="color: #66cc66;">&#41;</span> <span style="color: #66cc66;">&#123;</span>
&nbsp;
		<span style="color: #000066; font-weight: bold;">if</span> <span style="color: #66cc66;">&#40;</span><span style="color: #000066; font-weight: bold;">this</span>.<span style="color: #006600;">reqobj</span>.<span style="color: #006600;">readyState</span> == <span style="color: #CC0000;">4</span><span style="color: #66cc66;">&#41;</span> <span style="color: #66cc66;">&#123;</span>
			<span style="color: #000066; font-weight: bold;">if</span> <span style="color: #66cc66;">&#40;</span><span style="color: #000066; font-weight: bold;">this</span>.<span style="color: #006600;">reqobj</span>.<span style="color: #000066;">status</span> == <span style="color: #CC0000;">200</span><span style="color: #66cc66;">&#41;</span> <span style="color: #66cc66;">&#123;</span>
				<span style="color: #009900; font-style: italic;">//alert(&quot;reply is back?&quot;+this.reqobj.responseText);</span>
				<span style="color: #000066; font-weight: bold;">this</span>.<span style="color: #006600;">action</span><span style="color: #66cc66;">&#40;</span><span style="color: #000066; font-weight: bold;">this</span>.<span style="color: #006600;">reqobj</span><span style="color: #66cc66;">&#41;</span>;
			<span style="color: #66cc66;">&#125;</span><span style="color: #000066; font-weight: bold;">else</span><span style="color: #66cc66;">&#123;</span>
			 	<span style="color: #009900; font-style: italic;">//alert(&quot;There was a problem retrieving data:\n&quot; + this.reqobj.statusText);</span>
			 	<span style="color: #000066; font-weight: bold;">if</span> <span style="color: #66cc66;">&#40;</span><span style="color: #000066; font-weight: bold;">this</span>.<span style="color: #006600;">error</span><span style="color: #66cc66;">&#41;</span><span style="color: #66cc66;">&#123;</span>
			 		<span style="color: #000066; font-weight: bold;">this</span>.<span style="color: #006600;">error</span><span style="color: #66cc66;">&#40;</span><span style="color: #000066; font-weight: bold;">this</span>.<span style="color: #006600;">reqobj</span><span style="color: #66cc66;">&#41;</span>;
			 	<span style="color: #66cc66;">&#125;</span>
			<span style="color: #66cc66;">&#125;</span>
		<span style="color: #66cc66;">&#125;</span>		
	<span style="color: #66cc66;">&#125;</span>	
<span style="color: #66cc66;">&#125;</span></pre></div></div>

<p><span id="more-34"></span><br />
<a href='/sarahajax/usage1.html'><strong>Click here for Usage Example1: Prototyping</strong></a><br />
How to use: </p>
<ol>
<li>Include the script <code>sarahajax.js</code> file in your html file.</li>
<li>Implement &#8216;<code>action</code>&#8216; function by prototyping. This function is only called when request reply is OK.</li>
<li>Optionally add &#8216;<code>error</code>&#8216; function. It is called by SarahAjax object when there was error occured or the request reply is not normal.
<li>Initialize a SarahAjax object with Target URL to send request to.</li>
<li>Call the object&#8217;s &#8216;<code>sendRequest()</code>&#8216; method to send request to the URL</li>
</ol>

<div class="wp_syntax"><div class="code"><pre class="javascript"><span style="color: #66cc66;">&lt;</span>html<span style="color: #66cc66;">&gt;</span>
<span style="color: #66cc66;">&lt;</span>head<span style="color: #66cc66;">&gt;&lt;</span>title<span style="color: #66cc66;">&gt;</span>SarahAjax Testing <span style="color: #CC0000;">1</span> using prototyping<span style="color: #66cc66;">&lt;/</span>title<span style="color: #66cc66;">&gt;</span>
&nbsp;
&nbsp;
<span style="color: #66cc66;">&lt;</span>script type=<span style="color: #3366CC;">&quot;text/javascript&quot;</span> src=<span style="color: #3366CC;">&quot;sarahajax.js&quot;</span><span style="color: #66cc66;">&gt;&lt;/</span>script<span style="color: #66cc66;">&gt;</span>
<span style="color: #66cc66;">&lt;</span>script type=<span style="color: #3366CC;">&quot;text/javascript&quot;</span><span style="color: #66cc66;">&gt;</span>
&nbsp;
<span style="color: #009900; font-style: italic;">//The action function must have the  argument for XMLHttpRequest object</span>
SarahAjax.<span style="color: #006600;">prototype</span>.<span style="color: #006600;">action</span>= <span style="color: #003366; font-weight: bold;">function</span> <span style="color: #66cc66;">&#40;</span>obj<span style="color: #66cc66;">&#41;</span> <span style="color: #66cc66;">&#123;</span>
	<span style="color: #009900; font-style: italic;">//obj.responseText : Regualar string</span>
	<span style="color: #009900; font-style: italic;">//obj.statusText : Showing Requst Result Status</span>
	<span style="color: #009900; font-style: italic;">//obj.responseXML : XML string</span>
	<span style="color: #003366; font-weight: bold;">var</span> div = document.<span style="color: #006600;">getElementById</span><span style="color: #66cc66;">&#40;</span><span style="color: #3366CC;">&quot;result&quot;</span><span style="color: #66cc66;">&#41;</span>;
	<span style="color: #000066; font-weight: bold;">if</span> <span style="color: #66cc66;">&#40;</span>div<span style="color: #66cc66;">&#41;</span>
		div.<span style="color: #006600;">innerHTML</span> = obj.<span style="color: #006600;">responseText</span>; 
	<span style="color: #000066; font-weight: bold;">else</span>
		<span style="color: #000066;">alert</span><span style="color: #66cc66;">&#40;</span><span style="color: #3366CC;">&quot;hey where should I show the reply text?&quot;</span><span style="color: #66cc66;">&#41;</span>;
&nbsp;
<span style="color: #66cc66;">&#125;</span>
&nbsp;
<span style="color: #009900; font-style: italic;">//error functino is optional, but it's a good idea to create one.</span>
SarahAjax.<span style="color: #006600;">prototype</span>.<span style="color: #006600;">error</span> = <span style="color: #003366; font-weight: bold;">function</span><span style="color: #66cc66;">&#40;</span>obj<span style="color: #66cc66;">&#41;</span><span style="color: #66cc66;">&#123;</span>
	<span style="color: #000066;">alert</span><span style="color: #66cc66;">&#40;</span>obj.<span style="color: #006600;">statusText</span><span style="color: #66cc66;">&#41;</span>;
&nbsp;
<span style="color: #66cc66;">&#125;</span>
&nbsp;
<span style="color: #009900; font-style: italic;">//Now create an object. The request will be sent to target_app.php</span>
<span style="color: #003366; font-weight: bold;">var</span> sajax = <span style="color: #003366; font-weight: bold;">new</span> SarahAjax<span style="color: #66cc66;">&#40;</span><span style="color: #3366CC;">&quot;target_app.php&quot;</span><span style="color: #66cc66;">&#41;</span>;
&nbsp;
&nbsp;
<span style="color: #66cc66;">&lt;/</span>script<span style="color: #66cc66;">&gt;</span>
&nbsp;
<span style="color: #66cc66;">&lt;</span>style type=<span style="color: #3366CC;">&quot;text/css&quot;</span><span style="color: #66cc66;">&gt;</span>
#result <span style="color: #66cc66;">&#123;</span>
	border:1px dashed black;
	width:300px;
	height:30px;
<span style="color: #66cc66;">&#125;</span>
<span style="color: #66cc66;">&lt;</span><span style="color: #0066FF;">/style&gt;&lt;/</span>head<span style="color: #66cc66;">&gt;</span>
<span style="color: #66cc66;">&lt;</span>body<span style="color: #66cc66;">&gt;</span>
<span style="color: #66cc66;">&lt;</span>h2<span style="color: #66cc66;">&gt;</span>This <span style="color: #000066; font-weight: bold;">is</span> SarahAjax Testing Page<span style="color: #66cc66;">&lt;/</span>h2<span style="color: #66cc66;">&gt;</span>
<span style="color: #66cc66;">&lt;</span>div id=<span style="color: #3366CC;">&quot;result&quot;</span><span style="color: #66cc66;">&gt;</span>
<span style="color: #000066; font-weight: bold;">This</span> <span style="color: #000066; font-weight: bold;">is</span> where the result should show.
<span style="color: #66cc66;">&lt;/</span>div<span style="color: #66cc66;">&gt;</span>
&nbsp;
<span style="color: #66cc66;">&lt;</span>a href=<span style="color: #3366CC;">'javascript:sajax.sendRequest();'</span><span style="color: #66cc66;">&gt;</span>Send Request<span style="color: #66cc66;">&lt;/</span>a<span style="color: #66cc66;">&gt;</span>
&nbsp;
<span style="color: #66cc66;">&lt;/</span>body<span style="color: #66cc66;">&gt;</span>
<span style="color: #66cc66;">&lt;/</span>html<span style="color: #66cc66;">&gt;</span></pre></div></div>

<p><a href='/sarahajax/usage2.html'><strong>Click here for Usage Example2: inherit SarahAjax class</strong></a><br />
You can also use the class by creating a subclass. Please Click on the title to see the source in action. </p>
<p><a href='/sarahajax.zip'><strong>Download sarahajax.zip</strong></a></p>
]]></content:encoded>
			<wfw:commentRss>http://code.neox.net/2008/06/03/sarahajax-javascript-ajax-class/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Javascript Class HowTo</title>
		<link>http://code.neox.net/2008/06/03/javascript-class-howto/</link>
		<comments>http://code.neox.net/2008/06/03/javascript-class-howto/#comments</comments>
		<pubDate>Tue, 03 Jun 2008 04:29:18 +0000</pubDate>
		<dc:creator>HanaDaddy</dc:creator>
		
		<category><![CDATA[Javascript and CSS]]></category>

		<category><![CDATA[javascript]]></category>

		<guid isPermaLink="false">http://code.neox.net/?p=33</guid>
		<description><![CDATA[Great Tutorial on Javascript Classes

function Person &#40;firstname,lastname,age&#41;&#123;
&#160;
	this.firstname=firstname;
	this.lastname=lastname;
	this.age=age;
&#160;
	this.introduction = function &#40;type&#41; &#123;
		if &#40;type=='simple'&#41;&#123;
			alert&#40;&#34;Hi, I am &#34; + this.firstname +&#34;.&#34;&#41;;
		&#125;else&#123;
&#160;
			alert&#40;&#34;Hello, my name is &#34;+this.firstname + &#34; &#34; + this.lastname+&#34;.&#34; +
			 	&#34; I am &#34; + this.age + &#34; years old.&#34;&#41;;
		&#125;	
	&#125;
&#160;
&#125;
&#160;
var p = new Person&#40;&#34;Hana&#34;,&#34;Daddy&#34;,30&#41;;
&#160;
p.introduction&#40;&#34;simple&#34;&#41;;
p.introduction&#40;&#41;;

Creating a Javascript class is just like creating a regular function. Two things to [...]]]></description>
			<content:encoded><![CDATA[<p><a href='http://www.javascriptkit.com/javatutors/oopjs2.shtml'>Great Tutorial on Javascript Classes</a></p>

<div class="wp_syntax"><div class="code"><pre class="javascript"><span style="color: #003366; font-weight: bold;">function</span> Person <span style="color: #66cc66;">&#40;</span>firstname,lastname,age<span style="color: #66cc66;">&#41;</span><span style="color: #66cc66;">&#123;</span>
&nbsp;
	<span style="color: #000066; font-weight: bold;">this</span>.<span style="color: #006600;">firstname</span>=firstname;
	<span style="color: #000066; font-weight: bold;">this</span>.<span style="color: #006600;">lastname</span>=lastname;
	<span style="color: #000066; font-weight: bold;">this</span>.<span style="color: #006600;">age</span>=age;
&nbsp;
	<span style="color: #000066; font-weight: bold;">this</span>.<span style="color: #006600;">introduction</span> = <span style="color: #003366; font-weight: bold;">function</span> <span style="color: #66cc66;">&#40;</span>type<span style="color: #66cc66;">&#41;</span> <span style="color: #66cc66;">&#123;</span>
		<span style="color: #000066; font-weight: bold;">if</span> <span style="color: #66cc66;">&#40;</span>type==<span style="color: #3366CC;">'simple'</span><span style="color: #66cc66;">&#41;</span><span style="color: #66cc66;">&#123;</span>
			<span style="color: #000066;">alert</span><span style="color: #66cc66;">&#40;</span><span style="color: #3366CC;">&quot;Hi, I am &quot;</span> + <span style="color: #000066; font-weight: bold;">this</span>.<span style="color: #006600;">firstname</span> +<span style="color: #3366CC;">&quot;.&quot;</span><span style="color: #66cc66;">&#41;</span>;
		<span style="color: #66cc66;">&#125;</span><span style="color: #000066; font-weight: bold;">else</span><span style="color: #66cc66;">&#123;</span>
&nbsp;
			<span style="color: #000066;">alert</span><span style="color: #66cc66;">&#40;</span><span style="color: #3366CC;">&quot;Hello, my name is &quot;</span>+<span style="color: #000066; font-weight: bold;">this</span>.<span style="color: #006600;">firstname</span> + <span style="color: #3366CC;">&quot; &quot;</span> + <span style="color: #000066; font-weight: bold;">this</span>.<span style="color: #006600;">lastname</span>+<span style="color: #3366CC;">&quot;.&quot;</span> +
			 	<span style="color: #3366CC;">&quot; I am &quot;</span> + <span style="color: #000066; font-weight: bold;">this</span>.<span style="color: #006600;">age</span> + <span style="color: #3366CC;">&quot; years old.&quot;</span><span style="color: #66cc66;">&#41;</span>;
		<span style="color: #66cc66;">&#125;</span>	
	<span style="color: #66cc66;">&#125;</span>
&nbsp;
<span style="color: #66cc66;">&#125;</span>
&nbsp;
<span style="color: #003366; font-weight: bold;">var</span> p = <span style="color: #003366; font-weight: bold;">new</span> Person<span style="color: #66cc66;">&#40;</span><span style="color: #3366CC;">&quot;Hana&quot;</span>,<span style="color: #3366CC;">&quot;Daddy&quot;</span>,<span style="color: #CC0000;">30</span><span style="color: #66cc66;">&#41;</span>;
&nbsp;
p.<span style="color: #006600;">introduction</span><span style="color: #66cc66;">&#40;</span><span style="color: #3366CC;">&quot;simple&quot;</span><span style="color: #66cc66;">&#41;</span>;
p.<span style="color: #006600;">introduction</span><span style="color: #66cc66;">&#40;</span><span style="color: #66cc66;">&#41;</span>;</pre></div></div>

<p>Creating a Javascript class is just like creating a regular function. Two things to remember. </p>
<ul>
<li> Use <code>'this'</code> to access member variables.</li>
<li> How to define member functions </li>
</ul>
<p>The above will show alert message dialog.<br />
First, &#8220;Hi, I am Hana&#8221;.<br />
Second, &#8220;Hello, my name is Hana Daddy. I am 30 years old.&#8221;.</p>
<p>Now by using prototyping, you can add additional functions to the predefined classes. Also all the initialized class objects instantly have access to the new function! That is very convenient.</p>

<div class="wp_syntax"><div class="code"><pre class="javascript"><span style="color: #009900; font-style: italic;">//Prototyping : add </span>
Person.<span style="color: #006600;">prototype</span>.<span style="color: #006600;">addAge</span> = <span style="color: #003366; font-weight: bold;">function</span> <span style="color: #66cc66;">&#40;</span>year<span style="color: #66cc66;">&#41;</span> <span style="color: #66cc66;">&#123;</span>
	<span style="color: #000066; font-weight: bold;">if</span> <span style="color: #66cc66;">&#40;</span>year<span style="color: #66cc66;">&#41;</span>
		<span style="color: #000066; font-weight: bold;">this</span>.<span style="color: #006600;">age</span> += year;
	<span style="color: #000066; font-weight: bold;">else</span>
		<span style="color: #000066; font-weight: bold;">this</span>.<span style="color: #006600;">age</span> +=<span style="color: #CC0000;">1</span>;
<span style="color: #66cc66;">&#125;</span>
p.<span style="color: #006600;">addAge</span><span style="color: #66cc66;">&#40;</span><span style="color: #CC0000;">5</span><span style="color: #66cc66;">&#41;</span>;
p.<span style="color: #006600;">introduction</span><span style="color: #66cc66;">&#40;</span><span style="color: #66cc66;">&#41;</span>;</pre></div></div>

<p>The new <code>addAge</code> function was called from the previously created Person object p. And it&#8217;s working without problem. The Dialog says &#8220;Hello, my name is Hana Daddy. I am 35 years old.&#8221;. 5 years more aged. Time surely flies.</p>
<p>Finally, inheritance is very simple, too. See below example.</p>

<div class="wp_syntax"><div class="code"><pre class="javascript"><span style="color: #009900; font-style: italic;">// new Person inherited class</span>
<span style="color: #003366; font-weight: bold;">function</span> GoodPerson<span style="color: #66cc66;">&#40;</span>firstname,lastname,age<span style="color: #66cc66;">&#41;</span><span style="color: #66cc66;">&#123;</span>
	<span style="color: #000066; font-weight: bold;">this</span>.<span style="color: #006600;">fromClass</span> = Person;
	<span style="color: #000066; font-weight: bold;">this</span>.<span style="color: #006600;">fromClass</span><span style="color: #66cc66;">&#40;</span>firstname,lastname,age<span style="color: #66cc66;">&#41;</span>;
&nbsp;
	<span style="color: #000066; font-weight: bold;">this</span>.<span style="color: #006600;">characteristic</span>=<span style="color: #3366CC;">&quot;Good&quot;</span>;
	<span style="color: #000066; font-weight: bold;">this</span>.<span style="color: #006600;">doSomethingGood</span> =  <span style="color: #003366; font-weight: bold;">function</span> <span style="color: #66cc66;">&#40;</span><span style="color: #66cc66;">&#41;</span><span style="color: #66cc66;">&#123;</span>
		<span style="color: #000066;">alert</span><span style="color: #66cc66;">&#40;</span><span style="color: #3366CC;">&quot;help others&quot;</span><span style="color: #66cc66;">&#41;</span>;
	<span style="color: #66cc66;">&#125;</span>
<span style="color: #66cc66;">&#125;</span>
&nbsp;
<span style="color: #003366; font-weight: bold;">var</span> a = <span style="color: #003366; font-weight: bold;">new</span> GoodPerson<span style="color: #66cc66;">&#40;</span><span style="color: #3366CC;">&quot;Good&quot;</span>,<span style="color: #3366CC;">&quot;Person&quot;</span>,<span style="color: #CC0000;">20</span><span style="color: #66cc66;">&#41;</span>;
a.<span style="color: #006600;">introduction</span><span style="color: #66cc66;">&#40;</span><span style="color: #66cc66;">&#41;</span>;</pre></div></div>

<p>Thats about a all for the quick HOWTO on Javascript class. I will post my very very simple Ajax Javascript Class next time.</p>
]]></content:encoded>
			<wfw:commentRss>http://code.neox.net/2008/06/03/javascript-class-howto/feed/</wfw:commentRss>
		</item>
		<item>
		<title>IE innerHTML property and NoScope element such as &#60;script&#62; and &#60;style&#62;</title>
		<link>http://code.neox.net/2008/06/02/ie-innerhtml-property-and-noscope-element-such-as-script-and-style/</link>
		<comments>http://code.neox.net/2008/06/02/ie-innerhtml-property-and-noscope-element-such-as-script-and-style/#comments</comments>
		<pubDate>Tue, 03 Jun 2008 01:02:59 +0000</pubDate>
		<dc:creator>HanaDaddy</dc:creator>
		
		<category><![CDATA[Javascript and CSS]]></category>

		<category><![CDATA[CSS]]></category>

		<category><![CDATA[IE]]></category>

		<guid isPermaLink="false">http://code.neox.net/?p=30</guid>
		<description><![CDATA[OK , I was working this my random sidebar image rotator. It uses ajax component to get html codes to show random images and it automatically rotates the image in every defined seconds.
In order to show horizontal and vertical images in a same spaced area, I have assigned pre defined squre div element and make [...]]]></description>
			<content:encoded><![CDATA[<p>OK , I was working this my random sidebar image rotator. It uses ajax component to get html codes to show random images and it automatically rotates the image in every defined seconds.</p>
<p>In order to show horizontal and vertical images in a same spaced area, I have assigned pre defined squre div element and make the ajax component to get html codes and set innetHTML property of this <code>&lt;div&gt;</code> element. The <code>&lt;img&gt;</code> element should be aligned in the center using calculated top and left CSS property.</p>
<p>So this is what I wanted to display (Normal) viewd with Firefox.<br />
<img src="http://code.neox.net/wp-content/uploads/2008/06/normal.jpg" alt="" title="normal" width="184" height="183" /></p>
<p>But when I tried with IE 7, I got below. It seems as if the <code>&lt;style&gt;</code> tag didn&#8217;t exist. The image was not aligned properly in the center.<br />
<img src="http://code.neox.net/wp-content/uploads/2008/06/abnormal.jpg" alt="" title="abnormal" width="184" height="183" /><br />
<span id="more-30"></span><br />
Here is my div injecting HTML code.</p>

<div class="wp_syntax"><div class="code"><pre class="html4strict"><span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;style</span> <span style="color: #000066;">type</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;text/css&quot;</span><span style="color: #000000; font-weight: bold;">&gt;</span></span>
.hana_ri {
	position: relative;
	width:180px;
	height:180px;
	/*border: 1px dashed grey;*/
}
&nbsp;
.hana_ri span {
	position: absolute;
	width: 51px;
	height: 19px;
	display:block;
&nbsp;
	top:80px;
	left:64px;
	background: url(http://localhost/wp/wp-content/themes/classic.neox/progress.gif) no-repeat;  
}
.hana_ri img {
	top:22.5px;
	left:0px;	
	position: absolute;
	width: 180px;
	height:135px;	
}
<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/style&gt;</span></span><span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;div</span> <span style="color: #000066;">class</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;hana_ri&quot;</span><span style="color: #000000; font-weight: bold;">&gt;</span></span><span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;a</span> <span style="color: #000066;">href</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;/wp/pics/IMG_2716.jpg&quot;</span><span style="color: #000000; font-weight: bold;">&gt;</span></span><span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;img</span> 
<span style="color: #000066;">src</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;http://localhost/wp/wp-content/themes/classic.neox/hana_random_image.php?image=IMG_2716.jpg&quot;</span> 
<span style="color: #000066;">title</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;IMG_2716.jpg&quot;</span> <span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">&gt;</span></span><span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;span</span> <span style="color: #000066;">id</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;hana_ri_span&quot;</span><span style="color: #000000; font-weight: bold;">&gt;</span></span><span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/span&gt;</span></span><span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/a&gt;</span></span><span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/div&gt;</span></span></pre></div></div>

<p>My code looks OK. I tried almost anything blaming and cursing the IE, why it has to be so difficult to do a simple thing. Searching Internet for any hints.</p>
<p>And I finally got my answer from Microsoft MSDN Website. <a href='http://msdn.microsoft.com/en-us/library/ms533897(VS.85).aspx'>This is a link MSDN regarding innerHtml property</a> of html element. It&#8217;s a nice little reference about innerHTML property. If you keep scrolling down to the bottom, there is a comment made by a user. It&#8217;s title is  &#8220;How to inject NoScope elements into a page with innerHTML.&#8221; </p>
<p>This is the quote from the comment.</p>
<blockquote><p>
Internally, Internet Explorer treats the <code>&lt;script&gt;</code> tag as a NoScope element, which means (according to a rather opaque comment in the source) that &#8220;no text in a textrun should point to it.&#8221; Examples of other tags that have this attribute are HTML comments <code>(&lt;!-- --&gt;)</code> and STYLE tags. All NoScope elements are removed from the beginning of the parsed HTML before it is injected with innerHTML or insertAdjacentHTML. To prevent this from happening, you must include at least one scoped element at the beginning of the injected HTML.</p>
<p>To make it work, you must start the injected HTML string with a scoped element, preferably an invisible one like a hidden input element.
</p></blockquote>
<p>So basically the user is suggesting to start the innerHTML with the regular scoped element. He is suggesting to start with <code>&lt;input&gt;</code> with hidden attribute. If the innerHTML starts with <code>&lt;style&gt;</code>, IE will simply ignore it.</p>
<p>So I immediately changed the code and made the &lt;style&gt; to come after &lt;div&gt; element. And viola! , it worked just like a magic!!!!! I really appreciate &#8216;John Sudds&#8217;, the commenter.</p>
<p>So here is the final version that worked.</p>

<div class="wp_syntax"><div class="code"><pre class="html4strict"><span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;div</span> <span style="color: #000066;">class</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;hana_ri&quot;</span><span style="color: #000000; font-weight: bold;">&gt;</span></span><span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;a</span> <span style="color: #000066;">href</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;/wp/pics/IMG_2716.jpg&quot;</span><span style="color: #000000; font-weight: bold;">&gt;</span></span><span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;img</span> 
<span style="color: #000066;">src</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;http://localhost/wp/wp-content/themes/classic.neox/hana_random_image.php?image=IMG_2716.jpg&quot;</span> 
<span style="color: #000066;">title</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;IMG_2716.jpg&quot;</span> <span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">&gt;</span></span><span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;span</span> <span style="color: #000066;">id</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;hana_ri_span&quot;</span><span style="color: #000000; font-weight: bold;">&gt;</span></span><span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/span&gt;</span></span><span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/a&gt;</span></span><span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/div&gt;</span></span>
<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;style</span> <span style="color: #000066;">type</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;text/css&quot;</span><span style="color: #000000; font-weight: bold;">&gt;</span></span>
.hana_ri {
	position: relative;
	width:180px;
	height:180px;
	/*border: 1px dashed grey;*/
}
&nbsp;
.hana_ri span {
	position: absolute;
	width: 51px;
	height: 19px;
	display:block;
&nbsp;
	top:80px;
	left:64px;
	background: url(http://localhost/wp/wp-content/themes/classic.neox/progress.gif) no-repeat;  
}
.hana_ri img {
	top:22.5px;
	left:0px;	
	position: absolute;
	width: 180px;
	height:135px;	
}
<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/style&gt;</span></span></pre></div></div>

]]></content:encoded>
			<wfw:commentRss>http://code.neox.net/2008/06/02/ie-innerhtml-property-and-noscope-element-such-as-script-and-style/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Wordpress Plugin repository HOWTO</title>
		<link>http://code.neox.net/2008/06/01/wordpress-plugin-repository-howto/</link>
		<comments>http://code.neox.net/2008/06/01/wordpress-plugin-repository-howto/#comments</comments>
		<pubDate>Mon, 02 Jun 2008 01:55:36 +0000</pubDate>
		<dc:creator>HanaDaddy</dc:creator>
		
		<category><![CDATA[WordPress]]></category>

		<category><![CDATA[plugin]]></category>

		<guid isPermaLink="false">http://code.neox.net/?p=28</guid>
		<description><![CDATA[This is wordpress&#8217;s own plugin repository http://wordpress.org/extend/plugins/ .
Once create your id, you can upload your plugin and share with the world. By the way, the plugin must be GPL compliant. 
Anyway, I had a hard time uploading my plugin Hana Flv Player because the necessary instructions are there but not in details missing something here [...]]]></description>
			<content:encoded><![CDATA[<p>This is wordpress&#8217;s own plugin repository <a href='http://wordpress.org/extend/plugins/'>http://wordpress.org/extend/plugins/</a> .</p>
<p>Once create your id, you can upload your plugin and share with the world. By the way, the plugin must be GPL compliant. </p>
<p>Anyway, I had a hard time uploading my plugin <a href='http://www.neox.net/w/2008/05/25/hana-flv-player-wordpress-plugin/'>Hana Flv Player</a> because the necessary instructions are there but not in details missing something here and missing something there.</p>
<p>So here is my explanation. I hope that this will help someone  too.</p>
<p>First little bit about readme.txt file. You need to create a readme.txt file.<br />
Make sure you define the Stable tag to indicate the current version.</p>

<div class="wp_syntax"><div class="code"><pre>== Hana Flv Player ===
Contributors: HanaDaddy
Donate link: http://www.neox.net/
Tags: FLV, Flash video
Requires at least: 2.0
Tested up to: 2.5
Stable tag: 1.5</pre></div></div>

<p>Below is how to show link (&lt;a href=&#8221;"&gt;). Link text comes first wrapped with [ ] and link URL goes next with ( ).</p>

<div class="wp_syntax"><div class="code"><pre>[Hana and Sarah's blog](http://www.neox.net/)</pre></div></div>

<p>In order to use &lt;code>&lt;/code>, use backtick (`).  Therefore <code>`THIS IS CODE`</code> will become <code>&lt;code&gt;THIS IS CODE&lt;/code&gt;</code></p>
<p>If you want to add screeshots, you need to define below section in your readme.txt and place the corresponding image in base trunk folder (refer svn section below for trunk folder . This is basically your plugin local  folder to work with svn) The image file name should be in format of screenshot-<strong>num</strong>.jpg. where num is actual sequentially increasing number. (screenshot-1.jpg, screenshot-2.jpg, screenshot-3.jpg&#8230;) Each descriptions go into the readme file with the corresponding number. So the screenshot-1.jpg will be shown with the description &#8220;Plugin Settings Page&#8221; as it was used with number 1.</p>

<div class="wp_syntax"><div class="code"><pre>== Screenshots ==
&nbsp;
1. Plugin Settings Page.
2. Adding the hana-flv-player tag in an article.
3. Example video working.</pre></div></div>

<p><span id="more-28"></span><br />
First make a request to add your plugin at <a href='http://wordpress.org/extend/plugins/add/'>http://wordpress.org/extend/plugins/add/</a></p>
<p>You will get email when the request is granted. Now you can upload your plugin using svn command.<br />
This is where you will need to learn basic svn command if you are not familiar with it. Here is the wordpress site howto.<br />
<a href='http://wordpress.org/extend/plugins/about/svn/'>http://wordpress.org/extend/plugins/about/svn/</a></p>
<p>But then I will summarize for better reference.</p>
<p><strong>Initial first uploading</strong></p>
<p>Create a folder. Check out the repository and copy your plugin files into the trunk subfolder. Then Checkin again.</p>

<div class="wp_syntax"><div class="code"><pre class="bash">$ <span style="color: #c20cb9; font-weight: bold;">mkdir</span> my-local-<span style="color: #c20cb9; font-weight: bold;">dir</span>
&nbsp;
<span style="color: #808080; font-style: italic;"># Check out the repository</span>
$ svn <span style="color: #c20cb9; font-weight: bold;">co</span> http:<span style="color: #000000; font-weight: bold;">//</span>svn.wp-plugins.org<span style="color: #000000; font-weight: bold;">/</span>your-plugin-name my-local-<span style="color: #c20cb9; font-weight: bold;">dir</span>
<span style="color: #000000; font-weight: bold;">&gt;</span> A	my-local-<span style="color: #c20cb9; font-weight: bold;">dir</span><span style="color: #000000; font-weight: bold;">/</span>trunk
<span style="color: #000000; font-weight: bold;">&gt;</span> A	my-local-<span style="color: #c20cb9; font-weight: bold;">dir</span><span style="color: #000000; font-weight: bold;">/</span>branches
<span style="color: #000000; font-weight: bold;">&gt;</span> A	my-local-<span style="color: #c20cb9; font-weight: bold;">dir</span><span style="color: #000000; font-weight: bold;">/</span>tags
<span style="color: #000000; font-weight: bold;">&gt;</span> Checked out revision <span style="color: #000000;">11325</span>.
&nbsp;
$ <span style="color: #7a0874; font-weight: bold;">cd</span> my-local-<span style="color: #c20cb9; font-weight: bold;">dir</span>
&nbsp;
my-local-<span style="color: #c20cb9; font-weight: bold;">dir</span><span style="color: #000000; font-weight: bold;">/</span>$ <span style="color: #c20cb9; font-weight: bold;">cp</span> ~<span style="color: #000000; font-weight: bold;">/</span>testing<span style="color: #000000; font-weight: bold;">/*</span> trunk<span style="color: #000000; font-weight: bold;">/</span>
&nbsp;
my-local-<span style="color: #c20cb9; font-weight: bold;">dir</span><span style="color: #000000; font-weight: bold;">/</span>$ svn add trunk<span style="color: #000000; font-weight: bold;">/*</span>
<span style="color: #000000; font-weight: bold;">&gt;</span> A	trunk<span style="color: #000000; font-weight: bold;">/</span>my-plugin.php
<span style="color: #000000; font-weight: bold;">&gt;</span> A	trunk<span style="color: #000000; font-weight: bold;">/</span>readme.txt
&nbsp;
my-local-<span style="color: #c20cb9; font-weight: bold;">dir</span><span style="color: #000000; font-weight: bold;">/</span>$ svn ci -m <span style="color: #ff0000;">&quot;The great plugin first update&quot;</span>
<span style="color: #000000; font-weight: bold;">&gt;</span> Adding	trunk<span style="color: #000000; font-weight: bold;">/</span>my-plugin.php
<span style="color: #000000; font-weight: bold;">&gt;</span> Adding	trunk<span style="color: #000000; font-weight: bold;">/</span>readme.txt
<span style="color: #000000; font-weight: bold;">&gt;</span> Committed revision <span style="color: #000000;">11326</span>.
&nbsp;
<span style="color: #808080; font-style: italic;"># Now create a new tag subfolder. You MUST create a new tag subfolder </span>
<span style="color: #808080; font-style: italic;"># if you upgrade it.</span>
my-local-<span style="color: #c20cb9; font-weight: bold;">dir</span><span style="color: #000000; font-weight: bold;">/</span>$ svn <span style="color: #c20cb9; font-weight: bold;">cp</span> trunk tags<span style="color: #000000; font-weight: bold;">/</span><span style="color: #000000;">1.0</span>
<span style="color: #000000; font-weight: bold;">&gt;</span> A         tags<span style="color: #000000; font-weight: bold;">/</span><span style="color: #000000;">1.0</span>
&nbsp;
my-local-<span style="color: #c20cb9; font-weight: bold;">dir</span><span style="color: #000000; font-weight: bold;">/</span>$ svn ci -m <span style="color: #ff0000;">&quot;tags v1.0 update&quot;</span>
<span style="color: #000000; font-weight: bold;">&gt;</span> Adding        tags<span style="color: #000000; font-weight: bold;">/</span><span style="color: #000000;">1.0</span><span style="color: #000000; font-weight: bold;">/</span>readme.txt
<span style="color: #000000; font-weight: bold;">&gt;</span> Adding        tags<span style="color: #000000; font-weight: bold;">/</span><span style="color: #000000;">1.0</span><span style="color: #000000; font-weight: bold;">/</span>my-plugin.php
<span style="color: #000000; font-weight: bold;">&gt;</span> Committed revision <span style="color: #000000;">11327</span>.</pre></div></div>

<p><strong>Upgrading the version.</strong><br />
Remember to update the &#8216;Stable Tag&#8217; field in trunk/readme.txt beforehand!</p>

<div class="wp_syntax"><div class="code"><pre class="bash"><span style="color: #808080; font-style: italic;">#Let's say you have upgraded the plugin. Makesure that you update the tags field in </span>
<span style="color: #808080; font-style: italic;">#readme.txt with the new version number</span>
$ <span style="color: #7a0874; font-weight: bold;">cd</span> my-local-<span style="color: #c20cb9; font-weight: bold;">dir</span>
my-local-<span style="color: #c20cb9; font-weight: bold;">dir</span><span style="color: #000000; font-weight: bold;">/</span>$ vi trunk<span style="color: #000000; font-weight: bold;">/</span>readme.txt
&nbsp;
<span style="color: #808080; font-style: italic;">#Check the status of which will be updated</span>
my-local-<span style="color: #c20cb9; font-weight: bold;">dir</span><span style="color: #000000; font-weight: bold;">/</span>$ svn <span style="color: #c20cb9; font-weight: bold;">stat</span> 
<span style="color: #000000; font-weight: bold;">&gt;</span> M      trunk<span style="color: #000000; font-weight: bold;">/</span>readme.txt
&nbsp;
my-local-<span style="color: #c20cb9; font-weight: bold;">dir</span><span style="color: #000000; font-weight: bold;">/</span>$ svn ci -m <span style="color: #ff0000;">&quot;trunk v1.5 update&quot;</span>
<span style="color: #000000; font-weight: bold;">&gt;</span> Adding	 trunk<span style="color: #000000; font-weight: bold;">/</span>readme.txt
<span style="color: #000000; font-weight: bold;">&gt;</span> Committed revision <span style="color: #000000;">11328</span>.
&nbsp;
<span style="color: #808080; font-style: italic;"># Now create a new tag subfolder. You MUST create a new tag subfolder if you upgrade it.</span>
my-local-<span style="color: #c20cb9; font-weight: bold;">dir</span><span style="color: #000000; font-weight: bold;">/</span>$ svn <span style="color: #c20cb9; font-weight: bold;">cp</span> trunk tags<span style="color: #000000; font-weight: bold;">/</span><span style="color: #000000;">1.5</span>
<span style="color: #000000; font-weight: bold;">&gt;</span> A         tags<span style="color: #000000; font-weight: bold;">/</span><span style="color: #000000;">1.5</span>
&nbsp;
my-local-<span style="color: #c20cb9; font-weight: bold;">dir</span><span style="color: #000000; font-weight: bold;">/</span>$ svn ci -m <span style="color: #ff0000;">&quot;tags v1.5 update&quot;</span>
<span style="color: #000000; font-weight: bold;">&gt;</span> Adding         tags<span style="color: #000000; font-weight: bold;">/</span><span style="color: #000000;">1.5</span><span style="color: #000000; font-weight: bold;">/</span>readme.txt
<span style="color: #000000; font-weight: bold;">&gt;</span> Committed revision <span style="color: #000000;">113289</span>.</pre></div></div>

<p>Some more svn commands example if you want to add a new file or delete existing file.</p>

<div class="wp_syntax"><div class="code"><pre class="bash"><span style="color: #808080; font-style: italic;">#delete file</span>
$ svn del trunk<span style="color: #000000; font-weight: bold;">/</span><span style="color: #c20cb9; font-weight: bold;">file</span>.php
&nbsp;
<span style="color: #808080; font-style: italic;">#add file</span>
$ svn add trunk<span style="color: #000000; font-weight: bold;">/</span><span style="color: #c20cb9; font-weight: bold;">file</span>.php
&nbsp;
<span style="color: #808080; font-style: italic;">#Checking status</span>
$ svn <span style="color: #c20cb9; font-weight: bold;">stat</span>
&nbsp;
<span style="color: #808080; font-style: italic;"># checkin command</span>
$ svn ci -m <span style="color: #ff0000;">&quot;add or delete files&quot;</span></pre></div></div>

<p><strong>readme.txt</strong><br />
So here is my readme.txt file for &#8216;hana-flv-player&#8217;.<br />
Check out <a href="http://wordpress.org/extend/plugins/hana-flv-player/#post-5733<br />
">the Wordpress Plugin</a> and compare the result side by side.</p>

<div class="wp_syntax"><div class="code"><pre>=== Hana Flv Player ===
Contributors: HanaDaddy
Donate link: http://www.neox.net/
Tags: FLV, Flash video
Requires at least: 2.0
Tested up to: 2.5
Stable tag: 1.5
&nbsp;
Easyly embed the Flash Video in your Wordpress featuring Flowplayer, OS FLV player, FLV Player Maxi.
&nbsp;
== Description ==
&nbsp;
Now you can easily embed the FLV Flash videos in your WordPress Blog. I have packaged the three FLV Flash player, [OS FLV](http://www.osflv.com/) , [FlowPlayer](http://flowplayer.org/), and [FLV Player Maxi](http://flv-player.net/players/maxi/). So you can use them freely without worries even for the commercial purpose unlike the JW player.
&nbsp;
You can place the specific tag element `[hana-flv-player]` in your wordpress article to show the video. The 'video' attribute is mandatory. There are other optional attributes. Default values for the options can be defined in this pages. See the bottom of the page for the example.
&nbsp;
`[hana-flv-player 
    video=&quot;http://yourwebsite.com/wp-content/plugins/hana-flv-player/babyhana.flv&quot;
    width=&quot;400&quot;
    height=&quot;320&quot;
    player=&quot;3&quot;
    autoplay=&quot;false&quot;
    loop=&quot;false&quot;
    autorewind=&quot;true&quot;
/]`
&nbsp;
&nbsp;
Attributes explained:
&nbsp;
*   video: URL of the flv video file. This is mandatory.
*   width: Width of the Flash player.
*   height: Height of the Flash player.
*   clickurl: If you want to open a website when a user clicks on the video, you can define the target website URL here.
*   player: If set to &quot;1&quot; , OS FLV will be used. If set to &quot;2&quot;, FlowPlayer will be used. &quot;3&quot; is for FLV Player Maxi.
*   autoload: If true, the movie will be loaded (downloaded). If false, the starting screen will be blank since no video is downloaded.
*   autoplay: If true, the movie will play automatically when the page is loaded.
*   loop: If Loop is true, the movie will replay itself constantly.
*   autorewind: If AutoRewind is true, the cursor will be reset to the start of the movie when the movie is ended.
*   splashimage: Only works with FlowPlayer and Maxi. When autoload is off, this splash image will be shown in the player. It only supports JPEG images.
&nbsp;
&nbsp;
&nbsp;
Note: Be careful when you use other website's video file as the video source. Since video files are usually large is size they can use up the bandwidth quickly. So you should ask for the owner's permission before using that link to the file.
&nbsp;
Thank you for using my plugin. -  [HanaDaddy](http://www.neox.net/)
&nbsp;
&nbsp;
== Installation ==
&nbsp;
This section describes how to install the plugin and get it working.
&nbsp;
1. Download and unzip the zip file. Upload `hana-flv-player` folder with all of its contents to the `/wp-content/plugins/` directory
2. Activate the plugin through the `Plugins` menu in WordPress Admin Interface.
3. Adjust the default settings in the 'Settings' menu in the Admin Interface if you want to.
4. Use `[hana-flv-player video='...'/]` in your blog article.  Attribute `video` is the only mandatory item where you define the video file. It can be full URL or absolute or relatvie path.
&nbsp;
If you want a quick test and see if it's working fine, goto Hana Flv Player settings admin page and copy the example shown in the bottom and paste in your blog article.
&nbsp;
== Frequently Asked Questions ==
&nbsp;
= Can I use FlowPlayer and OS FLV player in my commercial website? =
&nbsp;
Yes. They are under GPL licese and you are free to use them.
&nbsp;
= I would like to save my bandwidth as best as possible. What settings would guarantee the minimum usage? =
&nbsp;
Set autoplay and autoload to false in default setting admin page. You can override default by defining attributes inside the hana flv player tag.
&nbsp;
&nbsp;
== Screenshots ==
&nbsp;
1. Plugin Settings Page.
2. Adding the hana-flv-player tag in an article.
3. Example video working.</pre></div></div>

]]></content:encoded>
			<wfw:commentRss>http://code.neox.net/2008/06/01/wordpress-plugin-repository-howto/feed/</wfw:commentRss>
		</item>
	</channel>
</rss>
