<?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>Make Last Option As Selected In Select &#8211; Sibeesh Passion</title>
	<atom:link href="https://sibeeshpassion.com/tag/make-last-option-as-selected-in-select/feed/" rel="self" type="application/rss+xml" />
	<link>https://sibeeshpassion.com</link>
	<description>My passion towards life</description>
	<lastBuildDate>Tue, 25 Aug 2015 13:00:34 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=6.9.4</generator>

<image>
	<url>/wp-content/uploads/2017/04/Sibeesh_Passion_Logo_Small.png</url>
	<title>Make Last Option As Selected In Select &#8211; Sibeesh Passion</title>
	<link>https://sibeeshpassion.com</link>
	<width>32</width>
	<height>32</height>
</image> 
	<item>
		<title>Make Last Option As Selected In Select,Drop Down,Combo Box</title>
		<link>https://sibeeshpassion.com/make-last-option-as-selected-in-select-drop-down-combo-box/</link>
					<comments>https://sibeeshpassion.com/make-last-option-as-selected-in-select-drop-down-combo-box/#disqus_thread</comments>
		
		<dc:creator><![CDATA[SibeeshVenu]]></dc:creator>
		<pubDate>Tue, 25 Aug 2015 12:59:38 +0000</pubDate>
				<category><![CDATA[Code Snippets]]></category>
		<category><![CDATA[JQuery]]></category>
		<category><![CDATA[Combo Box Last Option]]></category>
		<category><![CDATA[Drop Down Last Option]]></category>
		<category><![CDATA[JQuery Selectors]]></category>
		<category><![CDATA[Make Last Option As Selected In Select]]></category>
		<guid isPermaLink="false">http://sibeecst_passion.com/?p=10351</guid>

					<description><![CDATA[In this post we will see how we can make the selected property to the last option of a select or drop down or combo box. We will use a jquery selector for making the last option as selected. Consider I have a following select element. [html] &#60;select name=&#34;mySelect&#34; id=&#34;mySelect&#34; class=&#34;select&#34;&#62; &#60;option&#62;1&#60;/option&#62; &#60;option&#62;2&#60;/option&#62; &#60;option&#62;3&#60;/option&#62; &#60;option&#62;4&#60;/option&#62; &#60;option&#62;5&#60;/option&#62; &#60;/select&#62; [/html] Now by default we need that last option as selected right? To do that we can use the following script. [js] $(&#34;#mySelect option:last&#34;).attr(&#34;selected&#34;, &#34;selected&#34;); [/js] Here mySelect is the ID of our element. Please see my other posts related to JQuery here: [&#8230;]]]></description>
										<content:encoded><![CDATA[<p>In this post we will see how we can make the selected property to the last option of a select or drop down or combo box. We will use a jquery selector for making the last option as selected.</p>
<p>Consider I have a following select element.</p>
<p>[html]<br />
&lt;select name=&quot;mySelect&quot; id=&quot;mySelect&quot; class=&quot;select&quot;&gt;<br />
    &lt;option&gt;1&lt;/option&gt;<br />
    &lt;option&gt;2&lt;/option&gt;<br />
    &lt;option&gt;3&lt;/option&gt;<br />
    &lt;option&gt;4&lt;/option&gt;<br />
    &lt;option&gt;5&lt;/option&gt;<br />
&lt;/select&gt;<br />
[/html]</p>
<p>Now by default we need that last option as selected right? To do that we can use the following script.</p>
<p>[js]<br />
$(&quot;#mySelect option:last&quot;).attr(&quot;selected&quot;, &quot;selected&quot;);<br />
[/js]</p>
<p>Here mySelect is the ID of our element.</p>
<p>Please see my other posts related to JQuery here: <a href="http://sibeeshpassion.com/tag/jquery/" target="_blank">JQuery Posts</a></p>
<p>Kindest Regards<br />
Sibeesh Venu</p>
]]></content:encoded>
					
					<wfw:commentRss>https://sibeeshpassion.com/make-last-option-as-selected-in-select-drop-down-combo-box/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
	</channel>
</rss>
