<?xml version="1.0" encoding="iso-8859-1"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Pure-Essence.Net &#187; non php code</title>
	<atom:link href="http://pure-essence.net/category/geeky/non-php-code/feed/" rel="self" type="application/rss+xml" />
	<link>http://pure-essence.net</link>
	<description>you must visit this geeky girl's weblog!</description>
	<lastBuildDate>Fri, 20 Nov 2009 14:31:29 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8.6</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>log4j properties loading problem + put ivy jar on classpath in ant</title>
		<link>http://pure-essence.net/2009/10/06/log4j-properties-loading-problem-put-ivy-jar-on-classpath-in-ant/</link>
		<comments>http://pure-essence.net/2009/10/06/log4j-properties-loading-problem-put-ivy-jar-on-classpath-in-ant/#comments</comments>
		<pubDate>Tue, 06 Oct 2009 22:12:54 +0000</pubDate>
		<dc:creator>dodo</dc:creator>
				<category><![CDATA[geeky]]></category>
		<category><![CDATA[non php code]]></category>

		<guid isPermaLink="false">http://pure-essence.net/?p=1432</guid>
		<description><![CDATA[I learned a few new tricks recently that I thought are pretty cool.
If you use apache log4j, you can get very frustrated sometimes that it does not log based on what you defined in your log4j.properties file. This is because if your java web application contains other jars that also have log4j.properties, the log4j will [...]]]></description>
			<content:encoded><![CDATA[<p>I learned a few new tricks recently that I thought are pretty cool.</p>
<p>If you use <a href="http://logging.apache.org/log4j/1.2/index.html">apache log4j</a>, you can get very frustrated sometimes that it does not log based on what you defined in your log4j.properties file. This is because if your java web application contains other jars that also have log4j.properties, the log4j will use the first log4j.properties on the classpath which most of the times is NOT what you defined for your web app. I never knew a solution to this until recently my coworker was able to use spring to get around it. In your spring context, add<br />
<code>&lt;bean class="org.springframework.beans.factory.config.MethodInvokingFactoryBean"&gt;
  &lt;property name="targetClass" value="org.springframework.util.Log4jConfigurer"/&gt;
  &lt;property name="targetMethod" value="initLogging" /&gt;
  &lt;property name="arguments"&gt;
   &lt;list&gt;
    &lt;value&gt;log4j.properties&lt;/value&gt;
   &lt;/list&gt;
  &lt;/property&gt;
 &lt;/bean&gt;</code><br />
This will make sure the one you defined for your web app is used.</p>
<p>Also I recently wrote a <a href="http://groovy.codehaus.org/">groovy script</a> in <a href="http://ant.apache.org/">ant</a>. I learned that you can use <a href="http://ant.apache.org/ivy/">ivy</a> to cache as instance of a jar and then you can use it in your ant script.<br />
<code>&lt;target name="groovyScript"&gt;
  &lt;ivy:configure url="http://ivy.rainhail.com/ivyRepository/ivysettings.xml" /&gt;
  &lt;ivy:resolve conf="ant"/&gt;
  &lt;ivy:cachepath pathid="cp" conf="ant"/&gt;
  &lt;taskdef name="groovy" classpathref="cp" classname="org.codehaus.groovy.ant.Groovy"/&gt;
  &lt;groovy&gt;
	&lt;!-- your groovy script here --&gt;
  &lt;/groovy&gt;
 &lt;/target&gt;</code></p>
]]></content:encoded>
			<wfw:commentRss>http://pure-essence.net/2009/10/06/log4j-properties-loading-problem-put-ivy-jar-on-classpath-in-ant/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Custom font</title>
		<link>http://pure-essence.net/2008/10/28/custom-font/</link>
		<comments>http://pure-essence.net/2008/10/28/custom-font/#comments</comments>
		<pubDate>Tue, 28 Oct 2008 14:35:07 +0000</pubDate>
		<dc:creator>dodo</dc:creator>
				<category><![CDATA[geeky]]></category>
		<category><![CDATA[non php code]]></category>
		<category><![CDATA[browsers]]></category>
		<category><![CDATA[css]]></category>
		<category><![CDATA[custom font]]></category>

		<guid isPermaLink="false">http://pure-essence.net/?p=1350</guid>
		<description><![CDATA[I saw another custom font solution today: typeface
Instead of creating images or using flash just to show your site&#8217;s graphic text in the font you want, you can use typeface.js and write in plain HTML and CSS, just as if your visitors had the font installed locally. 
A while ago, I blogged about the SIFR [...]]]></description>
			<content:encoded><![CDATA[<p>I saw another custom font solution today: <a href="http://typeface.neocracy.org/">typeface</a></p>
<blockquote><p>Instead of creating images or using flash just to show your site&#8217;s graphic text in the font you want, you can use typeface.js and write in plain HTML and CSS, just as if your visitors had the font installed locally. </p></blockquote>
<p>A while ago, I blogged about the <a href="http://pure-essence.net/2008/09/17/sifr-3/">SIFR 3</a>. And there are many other solutions to render text in fonts that your client&#8217;s machine does not have. For example, generating the text as an image. BTW wasn&#8217;t there a wordpress plugin that does this? I wasn&#8217;t able to find it in my quick search. Can someone enlighten me?</p>
<p>One thing I hate about all these solutions is that you may no longer highlight the text in order to copy its content in all the browsers I know. It just bugs me to no end when expected browser behaviors get changed because you want some fancy fonts for your site.</p>
<p>I wish more browsers would implement <a href="http://www.css3.info/font-face-fonts-the-way-you-want-them/">the @font-face css rule</a> so maybe then we can get around this issue?</p>
]]></content:encoded>
			<wfw:commentRss>http://pure-essence.net/2008/10/28/custom-font/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>jQuery may just win</title>
		<link>http://pure-essence.net/2008/10/27/jquery-may-just-win/</link>
		<comments>http://pure-essence.net/2008/10/27/jquery-may-just-win/#comments</comments>
		<pubDate>Mon, 27 Oct 2008 22:45:47 +0000</pubDate>
		<dc:creator>dodo</dc:creator>
				<category><![CDATA[geeky]]></category>
		<category><![CDATA[non php code]]></category>
		<category><![CDATA[jQuery]]></category>

		<guid isPermaLink="false">http://pure-essence.net/?p=1346</guid>
		<description><![CDATA[I&#8217;m still unhappy how I lost the jQuery battle at work. Although I&#8217;m not banned from using it but hey this is encouraging! jQuery may just win the javascript framework battle at least in the popularity category.

Other frameworks are just not as user friendly IMO.
]]></description>
			<content:encoded><![CDATA[<p>I&#8217;m still unhappy how I lost the jQuery battle at work. Although I&#8217;m not banned from using it but hey this is encouraging! jQuery may just win the javascript framework battle at least in the popularity category.</p>
<p><a href="http://www.google.com/trends?q=prototype+javascript%2C+jquery+javascript%2C+YUI+javascript%2C+dojo+javascript%2C+mootools+javascript&#038;ctab=0&#038;geo=all&#038;date=all&#038;sort=0" title="Provided by google trend"><img src="http://pure-essence.net/stuff/geeky/jQueryTrend.png" alt="jQuery" class="blogpic" /></a></p>
<p>Other frameworks are just not as user friendly IMO.</p>
]]></content:encoded>
			<wfw:commentRss>http://pure-essence.net/2008/10/27/jquery-may-just-win/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>Javascript Error: submit is not a function</title>
		<link>http://pure-essence.net/2008/10/15/javascript-error-submit-is-not-a-function/</link>
		<comments>http://pure-essence.net/2008/10/15/javascript-error-submit-is-not-a-function/#comments</comments>
		<pubDate>Wed, 15 Oct 2008 18:13:35 +0000</pubDate>
		<dc:creator>dodo</dc:creator>
				<category><![CDATA[geeky]]></category>
		<category><![CDATA[non php code]]></category>
		<category><![CDATA[javascript]]></category>
		<category><![CDATA[javascript error]]></category>
		<category><![CDATA[submit is not a function]]></category>

		<guid isPermaLink="false">http://pure-essence.net/?p=1333</guid>
		<description><![CDATA[Just my luck and I ran into the dreaded submit is not a function javascript error.
Here&#8217;s the scenario.
While coding javascript along, you get a form via id or name on your html page and calls the submit() function on it. You think it should just behave as expected (submits the form) instead nothing happens and [...]]]></description>
			<content:encoded><![CDATA[<p>Just my luck and I ran into the dreaded submit is not a function javascript error.</p>
<p>Here&#8217;s the scenario.</p>
<p>While coding javascript along, you get a form via id or name on your html page and calls the submit() function on it. You think it should just behave as expected (submits the form) instead nothing happens and in firebug, you get a submit is not a function error. You are like WTF is going on? You start to wonder if you remembered the syntax correctly so you do some research and all the pages tell you yes it&#8217;s just submit() and nothing else.</p>
<p>Finally you start to search on the error &#8220;submit is not a function&#8221; you get to <a href="http://www.chovy.com/javascript/javascript-error-submit-is-not-a-function/">this page</a> and you learned:</p>
<blockquote><p>
The reason was the statement &#8220;formObj.submit();&#8221; in the javascript was colliding (resulting in ambiguity within the browser) with the form button, which was also named &#8220;submit&#8221;.
</p></blockquote>
<p>So just rename the element within the form tag that is named &#8220;submit&#8221; will fix the problem.</p>
<p>Here&#8217;s an example.</p>
<p>HTML:<br />
<code>&lt;form id="search"&gt;&lt;input name="something" /&gt;&lt;input type="submit" name="submit" /&gt;&lt;/form&gt;</code></p>
<p>Javascript:<br />
<code>function submitForm() {
  document.getElementById('search').submit();
}</code><br />
gives &#8220;submit is not a function&#8221; error.</p>
<p>Change HTML to:<br />
<code>&lt;form id="search"&gt;&lt;input name="something" /&gt;&lt;input type="submit" name="NOT_SUBMIT" /&gt;&lt;/form&gt;</code></p>
]]></content:encoded>
			<wfw:commentRss>http://pure-essence.net/2008/10/15/javascript-error-submit-is-not-a-function/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Why I prefer jQuery over YUI</title>
		<link>http://pure-essence.net/2008/10/11/why-i-prefer-jquery-over-yui/</link>
		<comments>http://pure-essence.net/2008/10/11/why-i-prefer-jquery-over-yui/#comments</comments>
		<pubDate>Sat, 11 Oct 2008 14:16:26 +0000</pubDate>
		<dc:creator>dodo</dc:creator>
				<category><![CDATA[geeky]]></category>
		<category><![CDATA[non php code]]></category>
		<category><![CDATA[ajax]]></category>
		<category><![CDATA[component]]></category>
		<category><![CDATA[datatable]]></category>
		<category><![CDATA[date picker]]></category>
		<category><![CDATA[jQuery]]></category>
		<category><![CDATA[pagination]]></category>
		<category><![CDATA[paginator]]></category>
		<category><![CDATA[plugin]]></category>
		<category><![CDATA[widget]]></category>
		<category><![CDATA[YUI]]></category>

		<guid isPermaLink="false">http://pure-essence.net/?p=1327</guid>
		<description><![CDATA[While at work, I was trying to find a way to easily do server side pagination without writing all the lovely logic myself. Due to some constraints, I am unable to use more high end framework such as JSF and struts. Which in a way I believe is a good thing. I would have more [...]]]></description>
			<content:encoded><![CDATA[<p>While at work, I was trying to find a way to easily do server side pagination without writing all the lovely logic myself. Due to some constraints, I am unable to use more high end framework such as JSF and struts. Which in a way I believe is a good thing. I would have more control over just writing servlets. However, having written pagination logic before, I really did not want to write that again. Somehow I thought of jQuery. Just for amusement, I looked for <a href="http://jquery.com/">jQuery</a> pagination plugin and guess what <a href="http://plugins.jquery.com/project/pagination">I found it</a>! By using this plugin, I can pass in some simple parameters such as total records, records per page, number of pages shown etc. to have jQuery generate a paginator for me. That&#8217;s beyond cool so I put it into action.</p>
<p><a href="http://regretless.com/work/eAdjusterActivityReport/uploadReport.php">Upload Report Mock</a> uses the jQuery pagination plugin but handles the pagination on the server side via php.</p>
<p>Ultimately what I also want to handle is the following scenario:</p>
<ul>
<li> I have a table of data, one of the column is editable.</li>
<li> If the user clicks on the column of a particular table row, a modal window will pop up asking for additional information.</li>
<li> The user fills out the information and submits.</li>
<li> The window updates the info for that table via AJAX and updates the results screen</li>
</ul>
<p>While I was eager for figure out how to accomplish that in jQuery, I found out that it is not one of the previously used javascript framework at work so they asked if I could look into <a href="http://developer.yahoo.com/yui/">YUI</a>.</p>
<p>Digging into YUI, first I tried to accomplish the same thing using the <a href="http://developer.yahoo.com/yui/paginator/">YUI paginator widget</a>. I spent two hours but it really does not seem like I can generate some href tags with this component like I could with the jQuery plugin. With jQuery, I could produce:<br />
<code>&lt;div id="pagination"&gt;
&lt;a class="prev" href="/work/eAdjusterActivityReport/uploadReport.php?page=1"&gt;Prev&lt;/a&gt;
&lt;a href="/work/eAdjusterActivityReport/uploadReport.php?page=1"&gt;1&lt;/a&gt;
&lt;span class="current"&gt;2&lt;/span&gt;
&lt;a href="/work/eAdjusterActivityReport/uploadReport.php?page=3"&gt;3&lt;/a&gt;
&lt;a href="/work/eAdjusterActivityReport/uploadReport.php?page=4"&gt;4&lt;/a&gt;
&lt;a href="/work/eAdjusterActivityReport/uploadReport.php?page=5"&gt;5&lt;/a&gt;
&lt;a href="/work/eAdjusterActivityReport/uploadReport.php?page=6"&gt;6&lt;/a&gt;
&lt;a href="/work/eAdjusterActivityReport/uploadReport.php?page=7"&gt;7&lt;/a&gt;
&lt;a href="/work/eAdjusterActivityReport/uploadReport.php?page=8"&gt;8&lt;/a&gt;
&lt;span&gt;...&lt;/span&gt;
&lt;a href="/work/eAdjusterActivityReport/uploadReport.php?page=10"&gt;10&lt;/a&gt;
&lt;a href="/work/eAdjusterActivityReport/uploadReport.php?page=11"&gt;11&lt;/a&gt;
&lt;a class="next" href="/work/eAdjusterActivityReport/uploadReport.php?page=3"&gt;Next&lt;/a&gt;
&lt;/div&gt;</code><br />
With YUI, I have to hook up the paginator with another javascript or YUI widget. So to make things easier, I looked into <a href="http://developer.yahoo.com/yui/datatable/">YUI&#8217;s datatable component</a> and found <a href="http://developer.yahoo.com/yui/examples/datatable/dt_dynamicdata.html">an example to use it with server side pagination and sorting</a>. That seems to accomplish the overall need of pagination. Although that&#8217;s a bit of overkill but I thought it&#8217;s worth a shot. I spent 8 hours implementing it via server side JSON. Here&#8217;s what I produced:<br />
<a href="http://regretless.com/work/eAdjusterActivityReport/uploadReportYUI.php">Upload Report Mock with YUI</a></p>
<p>Instead of 10 lines of javascript code <a href="http://regretless.com/work/eAdjusterActivityReport/uploadReport.php">like the previous</a>, this one has 68 lines. But it does provide AJAX pagination so I thought that&#8217;s mostly fair.</p>
<p>Next I looked for a simple date picker calendar in YUI like <a href="http://marcgrabanski.com/pages/code/jquery-ui-datepicker">the jQuery date picker plugin</a>. The date picker is a necessary functionality of the application. With jQuery, it&#8217;s extremely easy to use. You add the plugin js &amp; css links, and then you give your input css class or unique IDs and with jQuery selector, just call the plugin via:<code>$("#startDate").datepicker()</code></p>
<p>Click on the start and end dates in <a href="http://regretless.com/work/eAdjusterActivityReport/uploadReport.php">Upload Report Mock</a> to see it in action.</p>
<p>Using YUI, I looked into its calendar component.  The closest thing I could find is <a href="http://developer.yahoo.com/yui/examples/calendar/calcontainer.html">this example</a>.</p>
<p>Not only would it need all these extra js includes<br />
<code>&lt;script type="text/javascript" src="http://yui.yahooapis.com/2.6.0/build/event/event-min.js"&gt;&lt;/script&gt;
&lt;script type="text/javascript" src="http://yui.yahooapis.com/2.6.0/build/dragdrop/dragdrop-min.js"&gt;&lt;/script&gt;
&lt;script type="text/javascript" src="http://yui.yahooapis.com/2.6.0/build/element/element-beta-min.js"&gt;&lt;/script&gt;
&lt;script type="text/javascript" src="http://yui.yahooapis.com/2.6.0/build/button/button-min.js"&gt;&lt;/script&gt;
&lt;script type="text/javascript" src="http://yui.yahooapis.com/2.6.0/build/container/container-min.js"&gt;&lt;/script&gt;
&lt;script type="text/javascript" src="http://yui.yahooapis.com/2.6.0/build/calendar/calendar-min.js"&gt;&lt;/script&gt;</code><br />
It also requires another <a href="http://regretless.com/work/eAdjusterActivityReport/YUICalendarCode.txt">76 lines of javascript code</a> for just adding one date picker.</p>
<p>Despite the complication, I tried to make it work with <a href="http://regretless.com/work/eAdjusterActivityReport/uploadReportYUI.php">my Upload Report Mock with YUI</a> but I failed pretty miserably. Sure if I put in enough hours, I will eventually make it work but WHY? Why would you stop yourself from using something else that takes 2 seconds?</p>
<p>At this point, I presented my findings to my co-workers. I really hope they will accept jQuery. Yea sure it&#8217;s yet another new javascript framework but it will save coding time.</p>
<p>Here&#8217;s another comparison. I found a very <a href="http://www.webplicity.net/flexigrid/">YUI datatable like jQuery plugin flexigrid</a>. Take a look at example 3. Lines of code to use server side pagination and sorting: 33.  In <a href="http://regretless.com/work/eAdjusterActivityReport/uploadReportYUI.php">my Upload Report Mock with YUI</a>, <a href="http://regretless.com/work/eAdjusterActivityReport/YUIDataTableCode.txt">I used 68 lines</a>. Also let&#8217;s do a comparison to see which one makes more sense and is less verbose.</p>
<p>jQuery:<br />
<code>$("#flex1").flexigrid({
	url: 'post2.php',
	dataType: 'json',
	colModel : [
		{display: 'ISO', name : 'iso', width : 40, sortable : true, align: 'center'},
		{display: 'Name', name : 'name', width : 180, sortable : true, align: 'left'},
		{display: 'Printable Name', name : 'printable_name', width : 120, sortable : true, align: 'left'},
		{display: 'ISO3', name : 'iso3', width : 130, sortable : true, align: 'left', hide: true},
		{display: 'Number Code', name : 'numcode', width : 80, sortable : true, align: 'right'}
		],
	buttons : [
		{name: 'Add', bclass: 'add', onpress : test},
		{name: 'Delete', bclass: 'delete', onpress : test},
		{separator: true}
		],
	searchitems : [
		{display: 'ISO', name : 'iso'},
		{display: 'Name', name : 'name', isdefault: true}
		],
	sortname: "iso",
	sortorder: "asc",
	usepager: true,
	title: 'Countries',
	useRp: true,
	rp: 15,
	showTableToggleBtn: true,
	width: 700,
	height: 200
	}
);</code></p>
<p>YUI: <a href="http://regretless.com/work/eAdjusterActivityReport/YUIDataTableCode.txt">click for source</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://pure-essence.net/2008/10/11/why-i-prefer-jquery-over-yui/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Dodo&#8217;s Text Counter</title>
		<link>http://pure-essence.net/2008/05/30/dodos-text-counter/</link>
		<comments>http://pure-essence.net/2008/05/30/dodos-text-counter/#comments</comments>
		<pubDate>Sat, 31 May 2008 02:31:35 +0000</pubDate>
		<dc:creator>dodo</dc:creator>
				<category><![CDATA[geeky]]></category>
		<category><![CDATA[non php code]]></category>
		<category><![CDATA[plug]]></category>
		<category><![CDATA[jQuery]]></category>
		<category><![CDATA[maximum characters]]></category>
		<category><![CDATA[text counter]]></category>
		<category><![CDATA[text input]]></category>

		<guid isPermaLink="false">http://pure-essence.net/?p=1231</guid>
		<description><![CDATA[I needed a text counter at work. I searched around trying to find a jQuery plugin that fits the bill but I didn&#8217;t find anything. So I wrote one myself. Check it out  It should be pretty flexible.

Requires jQuery
Define the maximum of characters the user may input
May be applied to one or more input [...]]]></description>
			<content:encoded><![CDATA[<p>I needed a text counter at work. I searched around trying to find a jQuery plugin that fits the bill but I didn&#8217;t find anything. So I wrote one myself. Check it out <img src='http://pure-essence.net/wp-includes/images/smilies/smile.gif' alt=':)' class='wp-smiley' /> It should be pretty flexible.</p>
<ul>
<li>Requires <a href="http://jquery.com/">jQuery</a></li>
<li>Define the maximum of characters the user may input</li>
<li>May be applied to one or more input text or textarea fields</li>
<li>Also disable the user from entering more characters after s/he reaches the maximum</li>
</ul>
<p><a href="http://pure-essence.net/stuff/webTips/dodosTextCounter/index.html">Live demo + Documentation + Download</a></p>
]]></content:encoded>
			<wfw:commentRss>http://pure-essence.net/2008/05/30/dodos-text-counter/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Dodo&#8217;s Picklist</title>
		<link>http://pure-essence.net/2008/03/23/dodos-picklist/</link>
		<comments>http://pure-essence.net/2008/03/23/dodos-picklist/#comments</comments>
		<pubDate>Sun, 23 Mar 2008 14:27:37 +0000</pubDate>
		<dc:creator>dodo</dc:creator>
				<category><![CDATA[geeky]]></category>
		<category><![CDATA[non php code]]></category>
		<category><![CDATA[plug]]></category>
		<category><![CDATA[jQuery]]></category>
		<category><![CDATA[picklist]]></category>
		<category><![CDATA[plugin]]></category>

		<guid isPermaLink="false">http://pure-essence.net/2008/03/23/dodos-picklist/</guid>
		<description><![CDATA[I needed a pick list script at work. I looked around and found a jQuery plugin but it didn&#8217;t do all I wanted so I modified it. I thought I&#8217;d share my final results with you. I will contact the original author to see if he wants to include my changes to his version as [...]]]></description>
			<content:encoded><![CDATA[<p>I needed a pick list script at work. I looked around and found <a href="http://code.google.com/p/jqmultiselects/">a jQuery plugin</a> but it didn&#8217;t do all I wanted so I modified it. I thought I&#8217;d share my final results with you. I will contact the original author to see if he wants to include my changes to his version as well.</p>
<ul>
<li>Requires <a href="http://jquery.com/">jQuery</a></li>
<li>A modified version of <a href="http://code.google.com/p/jqmultiselects/">jqmultiselects jQuery plugin</a></li>
<li>Select options sorting code taken from <a href="http://www.texotela.co.uk/code/jquery/select/">select box manipulation</a></li>
<li>Choose one or more to add or remove. Or add all or remove all at once</li>
<li>Options are sorted to keep them in the same order</li>
</ul>
<p><a href="http://pure-essence.net/stuff/webTips/dodosPicklist/index.html"><img src="http://pure-essence.net/stuff/webTips/dodosPicklist.png" alt="Dodo's Picklist" class="blogpic" /></a></p>
<p><a href="http://pure-essence.net/stuff/webTips/dodosPicklist/index.html">Live demo + Documentation + Download</a></p>
]]></content:encoded>
			<wfw:commentRss>http://pure-essence.net/2008/03/23/dodos-picklist/feed/</wfw:commentRss>
		<slash:comments>7</slash:comments>
		</item>
		<item>
		<title>IE input background image issue</title>
		<link>http://pure-essence.net/2008/02/28/ie-input-background-image-issue/</link>
		<comments>http://pure-essence.net/2008/02/28/ie-input-background-image-issue/#comments</comments>
		<pubDate>Thu, 28 Feb 2008 06:19:36 +0000</pubDate>
		<dc:creator>dodo</dc:creator>
				<category><![CDATA[geeky]]></category>
		<category><![CDATA[non php code]]></category>
		<category><![CDATA[rants]]></category>
		<category><![CDATA[IE]]></category>
		<category><![CDATA[input background image]]></category>
		<category><![CDATA[long text]]></category>
		<category><![CDATA[scroll]]></category>

		<guid isPermaLink="false">http://pure-essence.net/2008/02/28/ie-input-background-image-issue/</guid>
		<description><![CDATA[IE strikes AGAIN!
Just when I thought I was 100% done with the revamp of New Millennium, I noticed an UI issue in IE. I&#8217;m surprised I didn&#8217;t notice this before. It shouldn&#8217;t be anything new. I did some google research but didn&#8217;t find anyone mentioning it either.
Applying background image to input tags should be nothing [...]]]></description>
			<content:encoded><![CDATA[<p>IE strikes AGAIN!</p>
<p>Just when I thought I was 100% done with the revamp of New Millennium, I noticed an UI issue in IE. I&#8217;m surprised I didn&#8217;t notice this before. It shouldn&#8217;t be anything new. I did some google research but didn&#8217;t find anyone mentioning it either.</p>
<p>Applying background image to input tags should be nothing new. You see the little search icons for search inputs all over the web now but did anyone notice in IE if you have a background image set to no-repeat and someone puts some very LONG text in the input field, the background image SCROLLS with the text? This causes very odd behavior.</p>
<p>Here&#8217;s my input background-image. I pick this one so I can do background image affect on hover by manipulating background-position.<br />
<img src="http://pure-essence.net/stuff/webTips/inputBackgroundImage/formInput.gif" alt="background image" /><br />
CSS:<br />
<code>input.formInput {
	width: 255px;
	background: #a99787 url(formInput.gif) left top no-repeat;
	border: 0;
	padding: 3px;
	height: 22px;
	color: #302721;
}
input.formInput:hover,
input.formInput:focus {
	background-position: -261px top;
}</code></p>
<p>In Firefox, it looks great but in IE if you start putting very looooooooooooooooong text in the input, it will look like crap.<br />
<img src="http://pure-essence.net/stuff/webTips/inputBackgroundImage/inputBackgroundImageIEIssue.png" alt="background image looks like crap in IE" /></p>
<p><a href="http://pure-essence.net/stuff/webTips/inputBackgroundImage/">Try it out yourself</a></p>
<p>So does anyone have a good solution for this issue? </p>
<p>If I were to do it, I&#8217;d wrap the input in a container and put the background image on the container and hopefully by applying the hover affect on the container, it would get the desirable effect. <del datetime="2008-02-28T23:46:18+00:00">Of course I will need to test out my theory. But it&#8217;s past midnight so I should get some sleep for now.</del></p>
<p><strong>AND it does work. <a href="http://pure-essence.net/stuff/webTips/inputBackgroundImage/">check it out</a>.</strong></p>
<p>Man, I just love IE.</p>
]]></content:encoded>
			<wfw:commentRss>http://pure-essence.net/2008/02/28/ie-input-background-image-issue/feed/</wfw:commentRss>
		<slash:comments>15</slash:comments>
		</item>
		<item>
		<title>jQuery and Tamper data rock</title>
		<link>http://pure-essence.net/2008/02/27/jquery-and-tamper-data-rock/</link>
		<comments>http://pure-essence.net/2008/02/27/jquery-and-tamper-data-rock/#comments</comments>
		<pubDate>Wed, 27 Feb 2008 19:36:20 +0000</pubDate>
		<dc:creator>dodo</dc:creator>
				<category><![CDATA[geeky]]></category>
		<category><![CDATA[non php code]]></category>
		<category><![CDATA[plug]]></category>
		<category><![CDATA[Firefox addon]]></category>
		<category><![CDATA[hijack get request]]></category>
		<category><![CDATA[hijack http request]]></category>
		<category><![CDATA[hijack post request]]></category>
		<category><![CDATA[jQuery]]></category>
		<category><![CDATA[proxy server]]></category>
		<category><![CDATA[Tamper data]]></category>
		<category><![CDATA[WebScarab]]></category>

		<guid isPermaLink="false">http://pure-essence.net/2008/02/27/jquery-and-tamper-data-rock/</guid>
		<description><![CDATA[I&#8217;ve been working on a UI design at work and some of the build in components have border=&#8221;1&#8243; on their generated table code. To achieve a consistent look, I always want border=&#8221;0&#8243; on the table so I can control the table border with CSS. There is no way as far as I know you can [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve been working on a UI design at work and some of the build in components have border=&#8221;1&#8243; on their generated table code. To achieve a consistent look, I always want border=&#8221;0&#8243; on the table so I can control the table border with CSS. There is no way as far as I know you can get rid of the table border with CSS once the source have border=&#8221;1&#8243; in the table tag. But you can get rid of all table borders with this single line of code in <a href="http://jquery.com">jQuery</a>:<br />
<code>$("table[border!='0']").attr("border", "0");</code><br />
It completely rules!!</p>
<p>While debugging, I also found this awesome Firefox plugin: <a href="https://addons.mozilla.org/en-US/firefox/addon/966">Tamper data</a>. It lets you hijack a post/get http request on the fly so you can view and modify the submitted parameters. I used to use <a href="http://www.owasp.org/index.php/Category:OWASP_WebScarab_Project">WebScarab</a>. But this is so much lighter weight. Although it only works in Firefox while <a href="http://www.owasp.org/index.php/Category:OWASP_WebScarab_Project">WebScarab</a>, a proxy server, would work with any browsers.</p>
]]></content:encoded>
			<wfw:commentRss>http://pure-essence.net/2008/02/27/jquery-and-tamper-data-rock/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>jQuery plugin &#8211; tableRowCheckboxToggle</title>
		<link>http://pure-essence.net/2008/02/26/jquery-plugin-tablerowcheckboxtoggle/</link>
		<comments>http://pure-essence.net/2008/02/26/jquery-plugin-tablerowcheckboxtoggle/#comments</comments>
		<pubDate>Tue, 26 Feb 2008 20:58:41 +0000</pubDate>
		<dc:creator>dodo</dc:creator>
				<category><![CDATA[geeky]]></category>
		<category><![CDATA[non php code]]></category>
		<category><![CDATA[javascript]]></category>
		<category><![CDATA[jQuery]]></category>
		<category><![CDATA[plugin]]></category>
		<category><![CDATA[table row]]></category>
		<category><![CDATA[toggle checkbox]]></category>

		<guid isPermaLink="false">http://pure-essence.net/2008/02/26/jquery-plugin-tablerowcheckboxtoggle/</guid>
		<description><![CDATA[So since I&#8217;ve been playing with jQuery on my spare time while putting together an ajax site, I&#8217;ve decided to tackle a design issue I&#8217;ve run into many times at work with jQuery. This idea originally comes from phpMyAdmin. If you&#8217;ve used that software, you know that when you click on any table row, it [...]]]></description>
			<content:encoded><![CDATA[<p>So since I&#8217;ve been playing with jQuery on my spare time while putting together an ajax site, I&#8217;ve decided to tackle a design issue I&#8217;ve run into many times at work with jQuery. This idea originally comes from phpMyAdmin. If you&#8217;ve used that software, you know that when you click on any table row, it automatically toggles the checked state of the checkbox in the first cell. I think that&#8217;s an extremely user friendly thing to have since checkboxes are so small and hard to click on.</p>
<p>Let me present you my friends, my first jQuery plugin. It generically adds the toggle function to any table rows you specify based on the css class names. It will by default toggle any checkboxes within the table row. However, you can manually exclude checkboxes based on name, id or css classes in the script. In addition to the phpMyAdmin function, I added an initialization step in the script that correctly marks a row when it&#8217;s considered checked on page load.</p>
<h3>tableRowCheckboxToggle</h3>
<ul>
<li>It generically adds the toggle checkbox function to any table rows you specify based on the css class names.</li>
<li>It will by default toggle any checkboxes within the table row.</li>
<li>You can manually exclude checkboxes based on name, id or css classes in the script.</li>
<li>If there is any applicable checkboxes inside of the table row that are checked, it will apply a class to the table row.</li>
<li>It also marks table rows when there are checked applicable checkboxes on page load.</li>
</ul>
<p><a href="http://pure-essence.net/stuff/webTips/jquery.tableRowCheckboxToggle.zip">Download version 1.0</a></p>
<p><a href="http://pure-essence.net/stuff/webTips/jqueryTableRowCheckboxToggle.html">Live demonstration</a></p>
<p><a href="http://plugins.jquery.com/project/tableRowCheckboxToggle">jQuery plugin tableRowCheckboxToggle</a></p>
]]></content:encoded>
			<wfw:commentRss>http://pure-essence.net/2008/02/26/jquery-plugin-tablerowcheckboxtoggle/feed/</wfw:commentRss>
		<slash:comments>11</slash:comments>
		</item>
	</channel>
</rss>
