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

<channel>
	<title>Prism Studio &#187; jQuery</title>
	<atom:link href="http://www.prismstudio.co.uk/category/jquery/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.prismstudio.co.uk</link>
	<description>Creative Web Design &#38; Photography</description>
	<lastBuildDate>Sat, 20 Mar 2010 23:30:29 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0</generator>
		<item>
		<title>jQuery plugin: Stylish Select Box &#8211; Unobtrusive select box replacement</title>
		<link>http://www.prismstudio.co.uk/2009/05/jquery-plugin-stylish-select-unobstrusive-select-box-replacement/</link>
		<comments>http://www.prismstudio.co.uk/2009/05/jquery-plugin-stylish-select-unobstrusive-select-box-replacement/#comments</comments>
		<pubDate>Thu, 28 May 2009 15:20:32 +0000</pubDate>
		<dc:creator>Scott Darby</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[jQuery]]></category>
		<category><![CDATA[CSS]]></category>
		<category><![CDATA[HTML]]></category>
		<category><![CDATA[UI]]></category>

		<guid isPermaLink="false">http://www.scottdarby.com/?p=158</guid>
		<description><![CDATA[I have released a new jQuery plugin that allows you to style the standard &#60;select&#62; form element with CSS so that it looks the same in all major browsers. View a working demonstration. Checkout the latest source on GitHub The plugin is available to download from the jQuery website. Tested and works with: Firefox 3.0, [...]]]></description>
			<content:encoded><![CDATA[<p>I have released a new jQuery plugin that allows you to style the standard <span class="codeEl">&lt;select&gt;</span> form element with CSS so that it looks the same in all major browsers.</p>
<p><a  rel="blank" href="http://www.prismstudio.co.uk/plugins/stylish-select/0.4/">View a working demonstration</a>.</p>
<p><a href="http://github.com/sko77sun/Stylish-Select">Checkout the latest source on GitHub</a></p>
<p>The plugin is available to download from the <a rel="blank" href="http://plugins.jquery.com/project/stylish-select-box/">jQuery website</a>.</p>
<p>Tested and works with:<br />
Firefox 3.0, Firefox2.0, Chrome 3, Safari 4, IE8, IE7, IE6</p>
<h2>Why?</h2>
<p>Because sometimes the browser default form styles look ugly with the rest of your site and <span class="codeEl">&lt;select&gt;</span> elements are notoriously difficult to style with <acronym title="Cascading Style Sheets">CSS</acronym>. You can see how wildly different <span class="codeEl">&lt;select&gt;</span> elements can look in different browsers with the same <acronym title="Cascading Style Sheets">CSS</acronym> applied <a  rel="blank" href="http://www.456bereastreet.com/lab/styling-form-controls-revisited/select-single/">here</a>.</p>
<h3>The IE6 issue(s)</h3>
<p>IE6 has a nasty habit of always displaying <span class="codeEl">&lt;select&gt;</span> elements on top of any other content, regardless of any z-index. This can be very annoying when using JavaScript overlays, drop down navigation etc. The only way around this issue is to use the <a rel="blank" href="http://www.cssplay.co.uk/menus/pro_drop8.html">iframe shim technique</a> which places an iframe around the content that needs to appear above the <span class="codeEl">&lt;select&gt;</span>.</p>
<p>Then there&#8217;s that <a  rel="blank" href="http://css-tricks.com/select-cuts-off-options-in-ie-fix/"> other issue of not being able to set a width</a> on <span class="codeEl">&lt;select&gt;</span> elements without clipping off any options wider than the set width.</p>
<p>While workarounds do exist for these issues, I wanted to create a drop down menu that worked exactly the same in every browser and did away with these IE6 oddities.</p>
<h2>So how does it work?</h2>
<p>Stylish Select basically grabs all of the options from your select menu, puts them into an unordered list and hides the original <span class="codeEl">&lt;select&gt;</span>. This unordered list is then made interactive, so that it functions like a browser native <span class="codeEl">&lt;select&gt;</span>. When you click on or navigate through the list with the keyboard, it updates the <span class="codeEl">&lt;select&gt;</span> in the background, so that when you submit your form, it is just like you were using the original <span class="codeEl">&lt;select&gt;</span>.</p>
<p>This newly created <span class="codeEl">&lt;select&gt;</span> now has the flexibility to be styled in whatever way you choose.</p>
<p>Alot of work has been done to make the newly created <span class="codeEl">&lt;select&gt;</span> to function like the original browser default. The plugin offers the following features:</p>
<p>Supports keyboard navigation including alpha-numerical keys<br />
If the <span class="codeEl">&lt;select&gt;</span> is at the bottom of the screen, the drop down menu stays on the screen<br />
Support for grouped options with <span class="codeEl">&lt;optgroup&gt;</span><br />
If a value is selected, the new select menu shows this option as selected</p>
<p>You can invoke the plugin on any <span class="codeEl">&lt;optgroup&gt;</span> with the following method:</p>
<p><span class="codeEl">$(&#8216;.my-dropdown&#8217;).sSelect();</span></p>
<p><a  rel="blank" href="http://www.scottdarby.com/plugins/stylish-select/0.4/">Working demonstration</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.prismstudio.co.uk/2009/05/jquery-plugin-stylish-select-unobstrusive-select-box-replacement/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

<!-- Performance optimized by W3 Total Cache. Learn more: http://www.w3-edge.com/wordpress-plugins/

Minified using disk
Page Caching using disk (enhanced)

Served from: www.prismstudio.co.uk @ 2010-08-01 03:50:16 -->