<?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>DAN FOLKES</title>
	<atom:link href="http://danfolkes.com/feed/" rel="self" type="application/rss+xml" />
	<link>http://danfolkes.com</link>
	<description>programmers blog</description>
	<lastBuildDate>Wed, 08 May 2013 18:29:17 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.4.2</generator>
		<item>
		<title>Quick Weather App in Your URL</title>
		<link>http://danfolkes.com/2013/05/08/quick-weather-app-in-your-url/</link>
		<comments>http://danfolkes.com/2013/05/08/quick-weather-app-in-your-url/#comments</comments>
		<pubDate>Wed, 08 May 2013 17:03:16 +0000</pubDate>
		<dc:creator>dan</dc:creator>
				<category><![CDATA[Code]]></category>
		<category><![CDATA[App]]></category>
		<category><![CDATA[bookmark]]></category>
		<category><![CDATA[bookmarklet]]></category>
		<category><![CDATA[data:html]]></category>
		<category><![CDATA[data:text]]></category>
		<category><![CDATA[data:text/html]]></category>
		<category><![CDATA[HTML]]></category>
		<category><![CDATA[weather]]></category>

		<guid isPermaLink="false">http://danfolkes.com/?p=1677</guid>
		<description><![CDATA[I wanted to make a good little weather app for myself for Richmond, VA. I couldn&#8217;t find what I wanted, but I was able to write a little bookmarklet using Chrome and Firefox&#8217;s ability to have data:text urls. Here is the URL: LINK data:text/html,&#60;html&#62;&#60;head&#62;&#60;style&#62;body,img &#123;white-space:nowrap;float:left;&#125;&#60;/style&#62;&#60;/head&#62;&#60;body&#62;&#60;img src = &#34;http://forecast.weather.gov/wtf/meteograms/Plotter.php?lat=37.53819&#38;lon=-77.46955&#38;wfo=AKQ&#38;zcode=VAZ071&#38;gset=20&#38;gdiff=10&#38;unit=0&#38;tinfo=EY5&#38;ahour=0&#38;pcmd=101001100100000000000000000000000000000000000000000000000&#38;lg=en&#38;indu=1!1!1&#38;dd=0&#38;bw=0&#38;hrspan=48&#38;pqpfhr=6&#38;psnwhr=6&#34; /&#62;&#60;img src = &#34;http://forecast.weather.gov/wtf/meteograms/Plotter.php?lat=37.53819&#38;lon=-77.46955&#38;wfo=AKQ&#38;zcode=VAZ071&#38;gset=20&#38;gdiff=10&#38;unit=0&#38;tinfo=EY5&#38;ahour=48&#38;pcmd=101001100100000000000000000000000000000000000000000000000&#38;lg=en&#38;indu=1!1!1&#38;dd=0&#38;bw=0&#38;hrspan=48&#38;pqpfhr=6&#38;psnwhr=6&#34; /&#62;&#60;img src = [...]<div class='yarpp-related-rss'>

Related posts:<ol>
<li><a href='http://danfolkes.com/2008/09/30/python-wunderground-todays-weather-to-email-sms-to-phone/' rel='bookmark' title='Python: Wunderground Todays Weather to Email SMS to Phone'>Python: Wunderground Todays Weather to Email SMS to Phone</a></li>
</ol>
</div>
]]></description>
			<content:encoded><![CDATA[<p>I wanted to make a good little weather app for myself for Richmond, VA.</p>
<p>I couldn&#8217;t find what I wanted, but I was able to write a little bookmarklet using Chrome and Firefox&#8217;s ability to have data:text urls.</p>
<p>Here is the URL:<br />
<a href='http://preview.tinyurl.com/bsava5x'>LINK</a></p>

<div class="wp_syntax"><table><tr><td class="code"><pre class="bash" style="font-family:monospace;">data:text<span style="color: #000000; font-weight: bold;">/</span>html,<span style="color: #000000; font-weight: bold;">&lt;</span>html<span style="color: #000000; font-weight: bold;">&gt;&lt;</span><span style="color: #c20cb9; font-weight: bold;">head</span><span style="color: #000000; font-weight: bold;">&gt;&lt;</span>style<span style="color: #000000; font-weight: bold;">&gt;</span>body,img <span style="color: #7a0874; font-weight: bold;">&#123;</span>white-space:nowrap;float:left;<span style="color: #7a0874; font-weight: bold;">&#125;</span><span style="color: #000000; font-weight: bold;">&lt;/</span>style<span style="color: #000000; font-weight: bold;">&gt;&lt;/</span><span style="color: #c20cb9; font-weight: bold;">head</span><span style="color: #000000; font-weight: bold;">&gt;&lt;</span>body<span style="color: #000000; font-weight: bold;">&gt;&lt;</span>img src = <span style="color: #ff0000;">&quot;http://forecast.weather.gov/wtf/meteograms/Plotter.php?lat=37.53819&amp;lon=-77.46955&amp;wfo=AKQ&amp;zcode=VAZ071&amp;gset=20&amp;gdiff=10&amp;unit=0&amp;tinfo=EY5&amp;ahour=0&amp;pcmd=101001100100000000000000000000000000000000000000000000000&amp;lg=en&amp;indu=1!1!1&amp;dd=0&amp;bw=0&amp;hrspan=48&amp;pqpfhr=6&amp;psnwhr=6&quot;</span> <span style="color: #000000; font-weight: bold;">/&gt;&lt;</span>img src = <span style="color: #ff0000;">&quot;http://forecast.weather.gov/wtf/meteograms/Plotter.php?lat=37.53819&amp;lon=-77.46955&amp;wfo=AKQ&amp;zcode=VAZ071&amp;gset=20&amp;gdiff=10&amp;unit=0&amp;tinfo=EY5&amp;ahour=48&amp;pcmd=101001100100000000000000000000000000000000000000000000000&amp;lg=en&amp;indu=1!1!1&amp;dd=0&amp;bw=0&amp;hrspan=48&amp;pqpfhr=6&amp;psnwhr=6&quot;</span> <span style="color: #000000; font-weight: bold;">/&gt;&lt;</span>img src = <span style="color: #ff0000;">&quot;http://forecast.weather.gov/wtf/meteograms/Plotter.php?lat=37.53819&amp;lon=-77.46955&amp;wfo=AKQ&amp;zcode=VAZ071&amp;gset=20&amp;gdiff=10&amp;unit=0&amp;tinfo=EY5&amp;ahour=96&amp;pcmd=101001100100000000000000000000000000000000000000000000000&amp;lg=en&amp;indu=1!1!1&amp;dd=0&amp;bw=0&amp;hrspan=48&amp;pqpfhr=6&amp;psnwhr=6&quot;</span> <span style="color: #000000; font-weight: bold;">/&gt;&lt;/</span>body<span style="color: #000000; font-weight: bold;">&gt;&lt;/</span>html<span style="color: #000000; font-weight: bold;">&gt;</span></pre></td></tr></table></div>

<p><span style="line-height: 1.714285714; font-size: 1rem;">Just put that in your URL and you will get a good Richmond Weather Graph.</span></p>
<p>The pictures are taken from:<br />
<a href="http://forecast.weather.gov/MapClick.php?lat=37.58036&amp;lon=-77.4874049&amp;unit=0&amp;lg=english&amp;FcstType=graphical">http://forecast.weather.gov/MapClick.php?lat=37.58036&amp;lon=-77.4874049&amp;unit=0&amp;lg=english&amp;FcstType=graphical</a></p>
<div class='yarpp-related-rss'>
<p>Related posts:<ol>
<li><a href='http://danfolkes.com/2008/09/30/python-wunderground-todays-weather-to-email-sms-to-phone/' rel='bookmark' title='Python: Wunderground Todays Weather to Email SMS to Phone'>Python: Wunderground Todays Weather to Email SMS to Phone</a></li>
</ol></p>
</div>
]]></content:encoded>
			<wfw:commentRss>http://danfolkes.com/2013/05/08/quick-weather-app-in-your-url/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Android &#8211; Large File Transfer &#8211; Samsung Galaxy S3 SGS</title>
		<link>http://danfolkes.com/2013/02/28/android-large-file-transfer-samsung-galaxy-s3-sgs/</link>
		<comments>http://danfolkes.com/2013/02/28/android-large-file-transfer-samsung-galaxy-s3-sgs/#comments</comments>
		<pubDate>Thu, 28 Feb 2013 19:47:05 +0000</pubDate>
		<dc:creator>dan</dc:creator>
				<category><![CDATA[Code]]></category>
		<category><![CDATA[Thoughts]]></category>

		<guid isPermaLink="false">http://danfolkes.com/?p=1661</guid>
		<description><![CDATA[This is one way transfer large files to android when other methods do not work: Turn on Developer Mode and Debugging Tools Install Android SDK on your computer Plug in phone and open the command prompt and type: More ADB info PATH-TO\android-sdk-windows\platform-tools\adb.exe push PATH-TO\FILE.zip /mnt/sdcard/ This usually takes a second.  I would first try transferring a small [...]<div class='yarpp-related-rss'>

Related posts:<ol>
<li><a href='http://danfolkes.com/2013/02/25/current-phone-setup-galaxy-s-iii-cyanogenmod/' rel='bookmark' title='Current Phone Setup &#8211; Galaxy S III &#8211; Cyanogenmod'>Current Phone Setup &#8211; Galaxy S III &#8211; Cyanogenmod</a></li>
<li><a href='http://danfolkes.com/2011/06/29/foxtophone-send-links-from-firefox-to-android-like-chrometophone/' rel='bookmark' title='FoxToPhone &#8211; Send Links from Firefox to Android &#8211; (Like ChromeToPhone)'>FoxToPhone &#8211; Send Links from Firefox to Android &#8211; (Like ChromeToPhone)</a></li>
<li><a href='http://danfolkes.com/2009/01/22/python-grab-email-from-gmail-and-insert-into-mysql-database/' rel='bookmark' title='Python: Grab Email from Gmail and Insert into MySql Database'>Python: Grab Email from Gmail and Insert into MySql Database</a></li>
</ol>
</div>
]]></description>
			<content:encoded><![CDATA[<p>This is one way transfer large files to android when other methods do not work:</p>
<ul>
<li>Turn on <a href="http://www.teamandroid.com/2012/11/02/how-to-enable-developer-options-in-android-42-jelly-bean/">Developer Mode and Debugging Tools</a></li>
<li><a href="http://developer.android.com/sdk/installing/index.html">Install Android SDK</a> on your computer</li>
<li>Plug in phone and open the command prompt and type:</li>
<li><span style="line-height: 1.714285714; font-size: 1rem;"><span style="line-height: 1.714285714; font-size: 1rem;"><a href="http://developer.android.com/tools/help/adb.html">More ADB info</a><br />
</span></span></p>

<div class="wp_syntax"><table><tr><td class="code"><pre class="bash" style="font-family:monospace;">PATH-TO\android-sdk-windows\platform-tools\adb.exe push PATH-TO\FILE.zip <span style="color: #000000; font-weight: bold;">/</span>mnt<span style="color: #000000; font-weight: bold;">/</span>sdcard<span style="color: #000000; font-weight: bold;">/</span></pre></td></tr></table></div>

</li>
<li><span style="font-size: 1rem; line-height: 1.714285714;">This usually takes a second.  I would first try </span>transferring<span style="font-size: 1rem; line-height: 1.714285714;"> a small file to make sure you have the correct path.</span></li>
</ul>
<blockquote style="margin-left: 40px; border: none; padding: 0px;"><p>Note: The &#8216;/mnt/sdcard&#8217; may be specific to my device.  If you can&#8217;t seem to find a writable folder do this:</p></blockquote>
<blockquote style="margin-left: 40px; border: none; padding: 0px;">

<div class="wp_syntax"><table><tr><td class="code"><pre class="bash" style="font-family:monospace;">PATH-TO\android-sdk-windows\platform-tools\adb.exe shell</pre></td></tr></table></div>

</blockquote>
<blockquote style="margin-left: 40px; border: none; padding: 0px;"><p>then, using <strong>ls</strong> and <strong>cd</strong> commands, you can move around and try and find the path to your writable directory.</p></blockquote>
<p>&nbsp;</p>
<p><span style="line-height: 1.714285714; font-size: 1rem;">Hope this helps someone!</span></p>
<div class='yarpp-related-rss'>
<p>Related posts:<ol>
<li><a href='http://danfolkes.com/2013/02/25/current-phone-setup-galaxy-s-iii-cyanogenmod/' rel='bookmark' title='Current Phone Setup &#8211; Galaxy S III &#8211; Cyanogenmod'>Current Phone Setup &#8211; Galaxy S III &#8211; Cyanogenmod</a></li>
<li><a href='http://danfolkes.com/2011/06/29/foxtophone-send-links-from-firefox-to-android-like-chrometophone/' rel='bookmark' title='FoxToPhone &#8211; Send Links from Firefox to Android &#8211; (Like ChromeToPhone)'>FoxToPhone &#8211; Send Links from Firefox to Android &#8211; (Like ChromeToPhone)</a></li>
<li><a href='http://danfolkes.com/2009/01/22/python-grab-email-from-gmail-and-insert-into-mysql-database/' rel='bookmark' title='Python: Grab Email from Gmail and Insert into MySql Database'>Python: Grab Email from Gmail and Insert into MySql Database</a></li>
</ol></p>
</div>
]]></content:encoded>
			<wfw:commentRss>http://danfolkes.com/2013/02/28/android-large-file-transfer-samsung-galaxy-s3-sgs/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Teaching Kids to Code &#8211; Processing.org</title>
		<link>http://danfolkes.com/2013/02/27/teaching-kids-to-code-processing-org/</link>
		<comments>http://danfolkes.com/2013/02/27/teaching-kids-to-code-processing-org/#comments</comments>
		<pubDate>Wed, 27 Feb 2013 18:21:20 +0000</pubDate>
		<dc:creator>dan</dc:creator>
				<category><![CDATA[Code]]></category>
		<category><![CDATA[Javascript]]></category>
		<category><![CDATA[jQuery]]></category>
		<category><![CDATA[Thoughts]]></category>

		<guid isPermaLink="false">http://danfolkes.com/?p=1649</guid>
		<description><![CDATA[My friend Eric is a technology teacher at a school in the Richmond area and I were discussing the importance of teaching kids to code.  The website code.org goes into it. I thought I should write up a quick tutorial on ways for kids (or grown ups) to code while: Having fun Creating Learning Sharing their [...]<div class='yarpp-related-rss'>

Related posts:<ol>
<li><a href='http://danfolkes.com/2010/04/20/jquery-example-documents-for-presentation/' rel='bookmark' title='JQuery &#8211; Example Documents for Presentation'>JQuery &#8211; Example Documents for Presentation</a></li>
<li><a href='http://danfolkes.com/2009/12/15/jquery-check-all-of-the-checkboxes/' rel='bookmark' title='jQuery: Check All of the Checkboxes'>jQuery: Check All of the Checkboxes</a></li>
<li><a href='http://danfolkes.com/2011/11/07/asp-net-update-panel-javascript-event-jquery-click/' rel='bookmark' title='ASP.Net Update Panel &#8211; Javascript Event &#8211; jQuery Click'>ASP.Net Update Panel &#8211; Javascript Event &#8211; jQuery Click</a></li>
</ol>
</div>
]]></description>
			<content:encoded><![CDATA[<p>My friend Eric is a technology teacher at a school in the Richmond area and I were discussing the importance of teaching kids to code.  The website code.org goes into it.</p>
<p>I thought I should write up a quick tutorial on ways for kids (or grown ups) to code while:</p>
<ul>
<li>Having fun</li>
<li>Creating</li>
<li>Learning</li>
<li>Sharing their work</li>
<li>Building off of each others work</li>
</ul>
<p>My tutorial utilizes two technologies:</p>
<p><strong><a title="http://jsfiddle.net/" href="http://jsfiddle.net/" target="_blank">jsfiddle</a> : </strong>This web platform allows you to program in javascript and see your results.  You can share and build off existing code.</p>
<p><strong><a title="http://processingjs.org/" href="http://processingjs.org/" target="_blank">Processingjs.org</a> : </strong>This javascript library allows you to cool stuff like: <a href="http://haptic-data.com/toxiclibsjs/examples/Circle3Points_pjs.html" target="_blank">this</a>, <a href="http://haptic-data.com/toxiclibsjs/examples/DraggableParticles_pjs.html" target="_blank">this</a>, or <a href="http://balldroppings.com/js/" target="_blank">this</a>.  It is a powerful library that has great <a href="http://processingjs.org/reference/" target="_blank">documentation</a>.</p>
<p>So, here are my basic first instructions:</p>
<div></div>
<div><strong>START:</strong></div>
<div>Go here: <a href="http://jsfiddle.net/n2yUg/21/" target="_blank">http://jsfiddle.net/n2yUg/21/</a></div>
<div></div>
<div><strong style="font-size: 1rem; line-height: 1;"><br />
EDITING:</strong></div>
<div>So, in this example, you can change the line of code:</div>

<div class="wp_syntax"><table><tr><td class="code"><pre class="javascript" style="font-family:monospace;">processing.<span style="color: #660066;">background</span><span style="color: #009900;">&#40;</span><span style="color: #CC0000;">224</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span></pre></td></tr></table></div>

<div></div>
<div>to be:</div>

<div class="wp_syntax"><table><tr><td class="code"><pre class="javascript" style="font-family:monospace;">processing.<span style="color: #660066;">background</span><span style="color: #009900;">&#40;</span><span style="color: #CC0000;">255</span><span style="color: #339933;">,</span><span style="color: #CC0000;">0</span><span style="color: #339933;">,</span><span style="color: #CC0000;">0</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span></pre></td></tr></table></div>

<div></div>
<div><strong style="font-size: 1rem; line-height: 1;"><br />
VIEWING:</strong></div>
<div>Hit RUN, and you will get a red background.</div>
<div>(<a href="http://processing.org/reference/background_.html" target="_blank">background function documentation</a>)</div>
<div></div>
<div><strong style="font-size: 1rem; line-height: 1;"><br />
SHARING:</strong></div>
<div>Then, you can use the SHARE button and you can see options to use Twitter or just send a link without any code:</div>
<div><a href="http://jsfiddle.net/n2yUg/22/embedded/result/" target="_blank">http://jsfiddle.net/n2yUg/22/embedded/result/</a></div>
<p>&nbsp;</p>
<p>So, I think you could learn a whole lot from these two things combined.</p>
<p>Hope this helps!</p>
<p>&nbsp;</p>
<div class='yarpp-related-rss'>
<p>Related posts:<ol>
<li><a href='http://danfolkes.com/2010/04/20/jquery-example-documents-for-presentation/' rel='bookmark' title='JQuery &#8211; Example Documents for Presentation'>JQuery &#8211; Example Documents for Presentation</a></li>
<li><a href='http://danfolkes.com/2009/12/15/jquery-check-all-of-the-checkboxes/' rel='bookmark' title='jQuery: Check All of the Checkboxes'>jQuery: Check All of the Checkboxes</a></li>
<li><a href='http://danfolkes.com/2011/11/07/asp-net-update-panel-javascript-event-jquery-click/' rel='bookmark' title='ASP.Net Update Panel &#8211; Javascript Event &#8211; jQuery Click'>ASP.Net Update Panel &#8211; Javascript Event &#8211; jQuery Click</a></li>
</ol></p>
</div>
]]></content:encoded>
			<wfw:commentRss>http://danfolkes.com/2013/02/27/teaching-kids-to-code-processing-org/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>MailChimp &#8211; Pass Email to Form</title>
		<link>http://danfolkes.com/2013/02/26/mailchimp-pass-email-to-form/</link>
		<comments>http://danfolkes.com/2013/02/26/mailchimp-pass-email-to-form/#comments</comments>
		<pubDate>Tue, 26 Feb 2013 16:37:23 +0000</pubDate>
		<dc:creator>dan</dc:creator>
				<category><![CDATA[Code]]></category>
		<category><![CDATA[Javascript]]></category>

		<guid isPermaLink="false">http://danfolkes.com/?p=1641</guid>
		<description><![CDATA[I wanted to use a basic email field and send the information to a mailchimp form.  I could not find the solution anywhere, so I decided to see if I could hack a solution. When you go to MailChimp &#62; For Your Website &#62; Signup Form Link Code You will get something like: http://eepurl.com/XXXX, which will [...]<div class='yarpp-related-rss'>

Related posts:<ol>
<li><a href='http://danfolkes.com/2011/05/25/facebook-website-integration-html/' rel='bookmark' title='Facebook Website Integration &#8211; HTML'>Facebook Website Integration &#8211; HTML</a></li>
<li><a href='http://danfolkes.com/2009/01/22/python-grab-email-from-gmail-and-insert-into-mysql-database/' rel='bookmark' title='Python: Grab Email from Gmail and Insert into MySql Database'>Python: Grab Email from Gmail and Insert into MySql Database</a></li>
<li><a href='http://danfolkes.com/2009/11/18/tikiwiki-tracker-email-subject-improvement-modification/' rel='bookmark' title='TikiWiki &#8211; Tracker Email Subject Improvement-Modification'>TikiWiki &#8211; Tracker Email Subject Improvement-Modification</a></li>
</ol>
</div>
]]></description>
			<content:encoded><![CDATA[<p><img src="http://danfolkes.com/wp-content/uploads/2013/02/mclogowhitebg.jpeg" alt="mail chimp logo" title="mail chimp logo" width="900" height="305" class="alignnone size-full wp-image-1643" /></p>
<p>I wanted to use a basic email field and send the information to a mailchimp form.  I could not find the solution anywhere, so I decided to see if I could hack a solution.</p>
<p>When you go to MailChimp &gt; For Your Website &gt; Signup Form Link Code<br />
You will get something like: http://eepurl.com/XXXX, which will take you to something like:</p>

<div class="wp_syntax"><table><tr><td class="code"><pre class="html" style="font-family:monospace;">http://toolstoday.us2.list-manage.com/subscribe?u=XXXXXXXXXXX&amp;amp;id=XXXXXXXXXXX</pre></td></tr></table></div>

<p>If you look at the source on this page, you will see that the form elements are called: MERGE0, MERGE1&#8230;</p>
<p>On my form, the email field is MERGE0, so on my website, I was able to create a javascript link that will automatically fill in email by using this link:</p>

<div class="wp_syntax"><table><tr><td class="code"><pre class="html" style="font-family:monospace;">http://XXXXXXXXXXX.us2.list-manage.com/subscribe?u=XXXXXXXXXXX&amp;amp;id=XXXXXXXXXXX&amp;amp;MERGE0=example@email.com</pre></td></tr></table></div>

<p>You can fill in more than one field by adding more merge fields in the url:</p>

<div class="wp_syntax"><table><tr><td class="code"><pre class="html" style="font-family:monospace;">http://XXXXXXXXXXX.us2.list-manage.com/subscribe?u=XXXXXXXXXXX&amp;amp;id=XXXXXXXXXXX&amp;amp;MERGE0=example@email.com;MERGE1=Daniel Folkes</pre></td></tr></table></div>

<p>Then, you can use this jquery to auto open a new window on enter key press:</p>

<div class="wp_syntax"><table><tr><td class="code"><pre class="javascript" style="font-family:monospace;">            $<span style="color: #009900;">&#40;</span><span style="color: #3366CC;">&quot;#ea&quot;</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">keypress</span><span style="color: #009900;">&#40;</span><span style="color: #000066; font-weight: bold;">function</span> <span style="color: #009900;">&#40;</span>e<span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
                <span style="color: #000066; font-weight: bold;">if</span> <span style="color: #009900;">&#40;</span>e.<span style="color: #660066;">which</span> <span style="color: #339933;">==</span> <span style="color: #CC0000;">13</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
                    e.<span style="color: #660066;">preventDefault</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
                    <span style="color: #006600; font-style: italic;">//dan@dans</span>
                    <span style="color: #000066; font-weight: bold;">var</span> url <span style="color: #339933;">=</span> <span style="color: #3366CC;">&quot;//XXXXXXXXXXX.us2.list-manage.com/subscribe?u=XXXXXXXXXXX&amp;id=XXXXXXXXXXX&quot;</span><span style="color: #339933;">;</span>
                    url <span style="color: #339933;">+=</span> <span style="color: #3366CC;">&quot;&amp;MERGE0=&quot;</span> <span style="color: #339933;">+</span> $<span style="color: #009900;">&#40;</span><span style="color: #3366CC;">&quot;#ea&quot;</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">val</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span> <span style="color: #006600; font-style: italic;">// ea is my email input text box.</span>
                    window.<span style="color: #660066;">open</span><span style="color: #009900;">&#40;</span>url<span style="color: #339933;">,</span> <span style="color: #3366CC;">&quot;mywindow&quot;</span><span style="color: #339933;">,</span> <span style="color: #3366CC;">&quot;status=1,toolbar=1,resizable=1,width=1000,height=600&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
                <span style="color: #009900;">&#125;</span>
             <span style="color: #009900;">&#125;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span></pre></td></tr></table></div>

<div class='yarpp-related-rss'>
<p>Related posts:<ol>
<li><a href='http://danfolkes.com/2011/05/25/facebook-website-integration-html/' rel='bookmark' title='Facebook Website Integration &#8211; HTML'>Facebook Website Integration &#8211; HTML</a></li>
<li><a href='http://danfolkes.com/2009/01/22/python-grab-email-from-gmail-and-insert-into-mysql-database/' rel='bookmark' title='Python: Grab Email from Gmail and Insert into MySql Database'>Python: Grab Email from Gmail and Insert into MySql Database</a></li>
<li><a href='http://danfolkes.com/2009/11/18/tikiwiki-tracker-email-subject-improvement-modification/' rel='bookmark' title='TikiWiki &#8211; Tracker Email Subject Improvement-Modification'>TikiWiki &#8211; Tracker Email Subject Improvement-Modification</a></li>
</ol></p>
</div>
]]></content:encoded>
			<wfw:commentRss>http://danfolkes.com/2013/02/26/mailchimp-pass-email-to-form/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Current Phone Setup &#8211; Galaxy S III &#8211; Cyanogenmod</title>
		<link>http://danfolkes.com/2013/02/25/current-phone-setup-galaxy-s-iii-cyanogenmod/</link>
		<comments>http://danfolkes.com/2013/02/25/current-phone-setup-galaxy-s-iii-cyanogenmod/#comments</comments>
		<pubDate>Mon, 25 Feb 2013 21:57:16 +0000</pubDate>
		<dc:creator>dan</dc:creator>
				<category><![CDATA[Thoughts]]></category>
		<category><![CDATA[Current Phone Setup]]></category>
		<category><![CDATA[Cyanogenmod]]></category>
		<category><![CDATA[Galaxy S III]]></category>
		<category><![CDATA[gs3]]></category>

		<guid isPermaLink="false">http://danfolkes.com/?p=1632</guid>
		<description><![CDATA[Android: Samsung Galaxy S III (SPH-L710) Rom: Cyanogenmod 10.12 &#8211; Android 4.2.1 Best Features: Being able to tether through USB and Wifi for free Using the volume keys to skip tracks Getting all the up-to-date features of android without worrying about Sprint releasing it for my phone Other new android features<div class='yarpp-related-rss'>

Related posts:<ol>
<li><a href='http://danfolkes.com/2008/02/06/friend-of-europa/' rel='bookmark' title='Friend of Europa'>Friend of Europa</a></li>
<li><a href='http://danfolkes.com/2008/08/11/python-cell-phone-number-pad-input/' rel='bookmark' title='Python &#8211; Cell Phone Number Pad Input'>Python &#8211; Cell Phone Number Pad Input</a></li>
<li><a href='http://danfolkes.com/2011/06/29/foxtophone-send-links-from-firefox-to-android-like-chrometophone/' rel='bookmark' title='FoxToPhone &#8211; Send Links from Firefox to Android &#8211; (Like ChromeToPhone)'>FoxToPhone &#8211; Send Links from Firefox to Android &#8211; (Like ChromeToPhone)</a></li>
</ol>
</div>
]]></description>
			<content:encoded><![CDATA[<p><img class="alignleft size-full wp-image-1633" title="cyanogenmod-101" src="http://danfolkes.com/wp-content/uploads/2013/02/cyanogenmod-101.jpg" alt="" width="214" height="371" />Android: Samsung Galaxy S III (SPH-L710)<br />
Rom: <a href="http://www.cyanogenmod.org/" target="_blank">Cyanogenmod 10.12</a> &#8211; Android 4.2.1<br />
Best Features:</p>
<ul>
<li><span style="line-height: 1.714285714; font-size: 1rem;">Being able to tether through USB and Wifi for free</span></li>
<li><span style="line-height: 1.714285714; font-size: 1rem;">Using the volume keys to skip tracks</span></li>
<li><span style="line-height: 1.714285714; font-size: 1rem;">Getting all the up-to-date features of android without worrying about Sprint releasing it for my phone</span></li>
<li><span style="line-height: 1.714285714; font-size: 1rem;">Other <a href="http://en.wikipedia.org/wiki/Android_version_history#Android_4.2_Jelly_Bean_.28API_level_17.29" target="_blank">new android features</a></span></li>
</ul>
<div style="clear: both;"></div>
<div class='yarpp-related-rss'>
<p>Related posts:<ol>
<li><a href='http://danfolkes.com/2008/02/06/friend-of-europa/' rel='bookmark' title='Friend of Europa'>Friend of Europa</a></li>
<li><a href='http://danfolkes.com/2008/08/11/python-cell-phone-number-pad-input/' rel='bookmark' title='Python &#8211; Cell Phone Number Pad Input'>Python &#8211; Cell Phone Number Pad Input</a></li>
<li><a href='http://danfolkes.com/2011/06/29/foxtophone-send-links-from-firefox-to-android-like-chrometophone/' rel='bookmark' title='FoxToPhone &#8211; Send Links from Firefox to Android &#8211; (Like ChromeToPhone)'>FoxToPhone &#8211; Send Links from Firefox to Android &#8211; (Like ChromeToPhone)</a></li>
</ol></p>
</div>
]]></content:encoded>
			<wfw:commentRss>http://danfolkes.com/2013/02/25/current-phone-setup-galaxy-s-iii-cyanogenmod/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Moderating Comments on a Freehostia Chocolate Account (Free)</title>
		<link>http://danfolkes.com/2013/02/13/moderating-comments-on-a-freehostia-chocolate-account-free/</link>
		<comments>http://danfolkes.com/2013/02/13/moderating-comments-on-a-freehostia-chocolate-account-free/#comments</comments>
		<pubDate>Wed, 13 Feb 2013 19:08:35 +0000</pubDate>
		<dc:creator>dan</dc:creator>
				<category><![CDATA[Code]]></category>
		<category><![CDATA[Javascript]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[a connection to akismet.com can not be established at this time]]></category>
		<category><![CDATA[access]]></category>
		<category><![CDATA[Akismet]]></category>
		<category><![CDATA[block]]></category>
		<category><![CDATA[captcha]]></category>
		<category><![CDATA[comments]]></category>
		<category><![CDATA[connections]]></category>
		<category><![CDATA[Disqus]]></category>
		<category><![CDATA[Freehostia]]></category>
		<category><![CDATA[Freehostia Free]]></category>
		<category><![CDATA[Install]]></category>
		<category><![CDATA[installing]]></category>
		<category><![CDATA[manually]]></category>
		<category><![CDATA[spam]]></category>
		<category><![CDATA[Unable to reach any Akismet servers.]]></category>
		<category><![CDATA[WordPress]]></category>

		<guid isPermaLink="false">http://danfolkes.com/?p=1622</guid>
		<description><![CDATA[The problem: Freehostia Free Accounts block outside connections.  This means that Akismet can&#8217;t access it&#8217;s servers and you can&#8217;t have spam checking.  So, all of your comments are spam spam spam! I tried to add a captcha, but they got around that.  I tried to add Disqus using the plugin, but that failed to install [...]<div class='yarpp-related-rss'>

Related posts:<ol>
<li><a href='http://danfolkes.com/2011/09/03/free-webcam-security-dorgem-winscp/' rel='bookmark' title='Free Webcam Security &#8211; Dorgem &#8211; WinSCP'>Free Webcam Security &#8211; Dorgem &#8211; WinSCP</a></li>
<li><a href='http://danfolkes.com/2009/12/01/youtube-comments-something-must-be-done/' rel='bookmark' title='YouTube Comments &#8211; Something must be done!'>YouTube Comments &#8211; Something must be done!</a></li>
<li><a href='http://danfolkes.com/2010/03/31/php-gmail-imap-connection-with-database-insert/' rel='bookmark' title='PHP Gmail Imap Connection with Database Insert'>PHP Gmail Imap Connection with Database Insert</a></li>
</ol>
</div>
]]></description>
			<content:encoded><![CDATA[<p>The problem: Freehostia Free Accounts block outside connections.  This means that Akismet can&#8217;t access it&#8217;s servers and you can&#8217;t have spam checking.  So, all of your comments are spam spam spam!</p>
<p>I tried to add a captcha, but they got around that.  I tried to add Disqus using the plugin, but that failed to install because of the account&#8217;s limitations.</p>
<p>But, I was able to add moderated comments to my freehostia site by manually installing Disqus.  This is very necessary because otherwise you get hit with a bunch of spammers.</p>
<p>Here is how you manually install Disqus on WordPress.</p>
<ol>
<li>Create <a href="https://disqus.com/admin/signup/">New Disqus Account </a></li>
<li>Go to your <a href="http://disqus.com/dashboard/">dashboard</a></li>
<li>Click on your site</li>
<li>Go to <strong>Settings</strong></li>
<li>And then click <strong>Install</strong></li>
<li>Select <strong>Universal Code</strong></li>
<li>Copy that code</li>
<li>In /wp-content/themes/THEMENAME/single.php Replace:

<div class="wp_syntax"><table><tr><td class="code"><pre class="php" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">&lt;?php</span> comments_template<span style="color: #009900;">&#40;</span> <span style="color: #0000ff;">''</span><span style="color: #339933;">,</span> <span style="color: #009900; font-weight: bold;">true</span> <span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span> <span style="color: #000000; font-weight: bold;">?&gt;</span></pre></td></tr></table></div>

<p>with:</p>

<div class="wp_syntax"><table><tr><td class="code"><pre class="php" style="font-family:monospace;"><span style="color: #b1b100;">echo</span> <span style="color: #0000ff;">'	
&nbsp;
YOUR COPIED CODE HERE.  
&nbsp;
    But you must remember to ESCAPE the 
    single quotes with backslashes example: \'
&nbsp;
	'</span><span style="color: #339933;">;</span></pre></td></tr></table></div>

</li>
<li>Save, Upload, then go to one of your posts. You should see Disqus loading at the bottom.</li>
<li>Remember to setup your Disqus the way you want it.  It&#8217;s a little restrictive out of the box. You can even add Akismet to Disqus in their admin interface. </li>
</ol>
<div class='yarpp-related-rss'>
<p>Related posts:<ol>
<li><a href='http://danfolkes.com/2011/09/03/free-webcam-security-dorgem-winscp/' rel='bookmark' title='Free Webcam Security &#8211; Dorgem &#8211; WinSCP'>Free Webcam Security &#8211; Dorgem &#8211; WinSCP</a></li>
<li><a href='http://danfolkes.com/2009/12/01/youtube-comments-something-must-be-done/' rel='bookmark' title='YouTube Comments &#8211; Something must be done!'>YouTube Comments &#8211; Something must be done!</a></li>
<li><a href='http://danfolkes.com/2010/03/31/php-gmail-imap-connection-with-database-insert/' rel='bookmark' title='PHP Gmail Imap Connection with Database Insert'>PHP Gmail Imap Connection with Database Insert</a></li>
</ol></p>
</div>
]]></content:encoded>
			<wfw:commentRss>http://danfolkes.com/2013/02/13/moderating-comments-on-a-freehostia-chocolate-account-free/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Run WordPress and Ruby on Rails using Apache</title>
		<link>http://danfolkes.com/2013/02/12/run-wordpress-and-ruby-on-rails-using-apache/</link>
		<comments>http://danfolkes.com/2013/02/12/run-wordpress-and-ruby-on-rails-using-apache/#comments</comments>
		<pubDate>Tue, 12 Feb 2013 21:41:21 +0000</pubDate>
		<dc:creator>dan</dc:creator>
				<category><![CDATA[Thoughts]]></category>

		<guid isPermaLink="false">http://danfolkes.com/?p=1615</guid>
		<description><![CDATA[Install a LAMP server with apache 2. Install Rails Install and Setup WordPress You should see wordpress here: http://example.com Then, add this to your apache config&#8217;s Virtualhost section: ProxyPass /fakerubypath http://127.0.0.1:3000 Now, start your rails server ./script/rails server You should now be able to see your ruby site on: http://example.com/fakerubypath I set mine up: wordpress and rails [...]<div class='yarpp-related-rss'>

Related posts:<ol>
<li><a href='http://danfolkes.com/2009/10/22/wordtwitt-is-the-best-wordpress-twitter-app/' rel='bookmark' title='WordTwitt is the best WordPress Twitter App'>WordTwitt is the best WordPress Twitter App</a></li>
<li><a href='http://danfolkes.com/2008/02/06/sitemeter/' rel='bookmark' title='sitemeter'>sitemeter</a></li>
<li><a href='http://danfolkes.com/2011/09/03/free-webcam-security-dorgem-winscp/' rel='bookmark' title='Free Webcam Security &#8211; Dorgem &#8211; WinSCP'>Free Webcam Security &#8211; Dorgem &#8211; WinSCP</a></li>
</ol>
</div>
]]></description>
			<content:encoded><![CDATA[<ol>
<li>Install a LAMP server with apache 2.</li>
<li>Install Rails</li>
<li>Install and Setup WordPress</li>
<li>You should see wordpress here: http://example.com</li>
<li>Then, add this to your apache config&#8217;s Virtualhost section:
<ol>
<li>

<div class="wp_syntax"><table><tr><td class="code"><pre class="ini" style="font-family:monospace;">ProxyPass /fakerubypath http://127.0.0.1:<span style="">3000</span></pre></td></tr></table></div>

</li>
</ol>
</li>
<li>Now, start your rails server
<ol>
<li>

<div class="wp_syntax"><table><tr><td class="code"><pre class="bash" style="font-family:monospace;">.<span style="color: #000000; font-weight: bold;">/</span>script<span style="color: #000000; font-weight: bold;">/</span>rails server</pre></td></tr></table></div>

</li>
</ol>
</li>
<li>You should now be able to see your ruby site on: http://example.com/fakerubypath</li>
</ol>
<p>I set mine up: <a href="http://lab.danfolkes.com">wordpress</a> and <a href="http://lab.danfolkes.com/demand">rails</a></p>
<p>&nbsp;</p>
<div class='yarpp-related-rss'>
<p>Related posts:<ol>
<li><a href='http://danfolkes.com/2009/10/22/wordtwitt-is-the-best-wordpress-twitter-app/' rel='bookmark' title='WordTwitt is the best WordPress Twitter App'>WordTwitt is the best WordPress Twitter App</a></li>
<li><a href='http://danfolkes.com/2008/02/06/sitemeter/' rel='bookmark' title='sitemeter'>sitemeter</a></li>
<li><a href='http://danfolkes.com/2011/09/03/free-webcam-security-dorgem-winscp/' rel='bookmark' title='Free Webcam Security &#8211; Dorgem &#8211; WinSCP'>Free Webcam Security &#8211; Dorgem &#8211; WinSCP</a></li>
</ol></p>
</div>
]]></content:encoded>
			<wfw:commentRss>http://danfolkes.com/2013/02/12/run-wordpress-and-ruby-on-rails-using-apache/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Short Domain Name Finder</title>
		<link>http://danfolkes.com/2012/10/12/short-domain-name-finder/</link>
		<comments>http://danfolkes.com/2012/10/12/short-domain-name-finder/#comments</comments>
		<pubDate>Fri, 12 Oct 2012 16:22:35 +0000</pubDate>
		<dc:creator>dan</dc:creator>
				<category><![CDATA[Javascript]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[Python]]></category>
		<category><![CDATA[check]]></category>
		<category><![CDATA[domain name]]></category>
		<category><![CDATA[domainr]]></category>
		<category><![CDATA[find short domain name]]></category>
		<category><![CDATA[find small urls]]></category>
		<category><![CDATA[short]]></category>
		<category><![CDATA[short domain]]></category>
		<category><![CDATA[short domain name]]></category>
		<category><![CDATA[small]]></category>
		<category><![CDATA[tiny]]></category>
		<category><![CDATA[tiny url]]></category>
		<category><![CDATA[whois]]></category>

		<guid isPermaLink="false">http://danfolkes.com/?p=1526</guid>
		<description><![CDATA[This is a short url finder I created. It checks to see if the domain is available remembers. Short Domain Name Finder There is a python script in the background that populates a mysql database which displays it with php.<div class='yarpp-related-rss'>

Related posts:<ol>
<li><a href='http://danfolkes.com/2012/02/03/web-service-using-jsonp-from-external-domain-php-jquery/' rel='bookmark' title='Web Service using JSONP from External Domain &#8211; PHP &#8211; JQuery'>Web Service using JSONP from External Domain &#8211; PHP &#8211; JQuery</a></li>
<li><a href='http://danfolkes.com/2009/01/22/python-grab-email-from-gmail-and-insert-into-mysql-database/' rel='bookmark' title='Python: Grab Email from Gmail and Insert into MySql Database'>Python: Grab Email from Gmail and Insert into MySql Database</a></li>
<li><a href='http://danfolkes.com/2009/05/06/ip-locator-webservice-php-ipmap-command-line/' rel='bookmark' title='IP Locator Webservice &#8211; PHP &#8211; Ipmap &#8211; Command Line'>IP Locator Webservice &#8211; PHP &#8211; Ipmap &#8211; Command Line</a></li>
</ol>
</div>
]]></description>
			<content:encoded><![CDATA[<p>This is a short url finder I created.<br />
It checks to see if the domain is available remembers.</p>
<p><a href='https://danfolkes.com/short-domain-names/'>Short Domain Name Finder</a></p>
<p>There is a python script in the background that populates a mysql database which displays it with php. </p>
<div class='yarpp-related-rss'>
<p>Related posts:<ol>
<li><a href='http://danfolkes.com/2012/02/03/web-service-using-jsonp-from-external-domain-php-jquery/' rel='bookmark' title='Web Service using JSONP from External Domain &#8211; PHP &#8211; JQuery'>Web Service using JSONP from External Domain &#8211; PHP &#8211; JQuery</a></li>
<li><a href='http://danfolkes.com/2009/01/22/python-grab-email-from-gmail-and-insert-into-mysql-database/' rel='bookmark' title='Python: Grab Email from Gmail and Insert into MySql Database'>Python: Grab Email from Gmail and Insert into MySql Database</a></li>
<li><a href='http://danfolkes.com/2009/05/06/ip-locator-webservice-php-ipmap-command-line/' rel='bookmark' title='IP Locator Webservice &#8211; PHP &#8211; Ipmap &#8211; Command Line'>IP Locator Webservice &#8211; PHP &#8211; Ipmap &#8211; Command Line</a></li>
</ol></p>
</div>
]]></content:encoded>
			<wfw:commentRss>http://danfolkes.com/2012/10/12/short-domain-name-finder/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Installing Diaspora on Ubuntu on VirtualBox</title>
		<link>http://danfolkes.com/2012/09/13/installing-diaspora-on-ubuntu-on-virtualbox/</link>
		<comments>http://danfolkes.com/2012/09/13/installing-diaspora-on-ubuntu-on-virtualbox/#comments</comments>
		<pubDate>Thu, 13 Sep 2012 20:12:13 +0000</pubDate>
		<dc:creator>dan</dc:creator>
				<category><![CDATA[Code]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[Software]]></category>
		<category><![CDATA[/script/server]]></category>
		<category><![CDATA[Apache]]></category>
		<category><![CDATA[Box]]></category>
		<category><![CDATA[bundle]]></category>
		<category><![CDATA[ca_file]]></category>
		<category><![CDATA[create]]></category>
		<category><![CDATA[db]]></category>
		<category><![CDATA[Diaspora]]></category>
		<category><![CDATA[diaspora.git]]></category>
		<category><![CDATA[exec]]></category>
		<category><![CDATA[headers]]></category>
		<category><![CDATA[image]]></category>
		<category><![CDATA[Install]]></category>
		<category><![CDATA[installing]]></category>
		<category><![CDATA[lamp]]></category>
		<category><![CDATA[mysql]]></category>
		<category><![CDATA[pod]]></category>
		<category><![CDATA[proxy proxy_balancer]]></category>
		<category><![CDATA[proxy_http]]></category>
		<category><![CDATA[rails_env]]></category>
		<category><![CDATA[rake]]></category>
		<category><![CDATA[rvm install]]></category>
		<category><![CDATA[script]]></category>
		<category><![CDATA[script server]]></category>
		<category><![CDATA[server]]></category>
		<category><![CDATA[ssh]]></category>
		<category><![CDATA[ssl]]></category>
		<category><![CDATA[SSLCertificateFile]]></category>
		<category><![CDATA[SSLCertificateKeyFile]]></category>
		<category><![CDATA[thin]]></category>
		<category><![CDATA[Ubuntu]]></category>
		<category><![CDATA[vdi]]></category>
		<category><![CDATA[Virtual]]></category>
		<category><![CDATA[Virtual Box]]></category>
		<category><![CDATA[VirtualBox]]></category>
		<category><![CDATA[VirtualHost]]></category>

		<guid isPermaLink="false">http://danfolkes.com/?p=1523</guid>
		<description><![CDATA[Installing Diaspora on Ubuntu on VirtualBox I wrote up a little howto on the Diaspora git hub: https://github.com/diaspora/diaspora/wiki/Installing-Diaspora-on-Ubuntu-on-VirtualBox<div class='yarpp-related-rss'>

Related posts:<ol>
<li><a href='http://danfolkes.com/2012/04/19/converting-a-magnet-link-into-a-torrent/' rel='bookmark' title='Converting a Magnet Link into a Torrent'>Converting a Magnet Link into a Torrent</a></li>
<li><a href='http://danfolkes.com/2011/01/26/ubuntu-samba-read-write-fstab-cifs-mount/' rel='bookmark' title='Ubuntu Samba &#8211; Read-Write-FSTAB-Cifs-Mount'>Ubuntu Samba &#8211; Read-Write-FSTAB-Cifs-Mount</a></li>
<li><a href='http://danfolkes.com/2009/03/03/started-using-git-scm-for-my-darkness-is-spreading/' rel='bookmark' title='Started Using Git SCM For my Darkness is Spreading'>Started Using Git SCM For my Darkness is Spreading</a></li>
</ol>
</div>
]]></description>
			<content:encoded><![CDATA[<p>Installing Diaspora on Ubuntu on VirtualBox</p>
<p>I wrote up a little howto on the Diaspora git hub:<br />
<a href="https://github.com/diaspora/diaspora/wiki/Installing-Diaspora-on-Ubuntu-on-VirtualBox">https://github.com/diaspora/diaspora/wiki/Installing-Diaspora-on-Ubuntu-on-VirtualBox</a></p>
<div class='yarpp-related-rss'>
<p>Related posts:<ol>
<li><a href='http://danfolkes.com/2012/04/19/converting-a-magnet-link-into-a-torrent/' rel='bookmark' title='Converting a Magnet Link into a Torrent'>Converting a Magnet Link into a Torrent</a></li>
<li><a href='http://danfolkes.com/2011/01/26/ubuntu-samba-read-write-fstab-cifs-mount/' rel='bookmark' title='Ubuntu Samba &#8211; Read-Write-FSTAB-Cifs-Mount'>Ubuntu Samba &#8211; Read-Write-FSTAB-Cifs-Mount</a></li>
<li><a href='http://danfolkes.com/2009/03/03/started-using-git-scm-for-my-darkness-is-spreading/' rel='bookmark' title='Started Using Git SCM For my Darkness is Spreading'>Started Using Git SCM For my Darkness is Spreading</a></li>
</ol></p>
</div>
]]></content:encoded>
			<wfw:commentRss>http://danfolkes.com/2012/09/13/installing-diaspora-on-ubuntu-on-virtualbox/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Sending Email with PHP, Gmail or Google Apps, Mail, and PEAR on Ubuntu</title>
		<link>http://danfolkes.com/2012/05/01/sending-email-with-php-gmail-or-google-apps-mail-and-pear-on-ubuntu/</link>
		<comments>http://danfolkes.com/2012/05/01/sending-email-with-php-gmail-or-google-apps-mail-and-pear-on-ubuntu/#comments</comments>
		<pubDate>Tue, 01 May 2012 16:40:42 +0000</pubDate>
		<dc:creator>dan</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[PHP]]></category>

		<guid isPermaLink="false">http://danfolkes.com/?p=1519</guid>
		<description><![CDATA[First Install Pear, Mail, Mail Mime, Net SMTP. Restart Apache: sudo apt-get install php-pear sudo pear install mail sudo pear install mail_mime sudo pear install Net_SMTP sudo /etc/init.d/apache2 restart Here is the PHP code I used to send an email: try &#123; require_once &#34;Mail.php&#34;; &#160; $from = &#34;from@example.com&#34;; $to = &#34;{$email}&#34;; $subject = &#34;Hi!&#34;; $body [...]<div class='yarpp-related-rss'>

Related posts:<ol>
<li><a href='http://danfolkes.com/2008/09/30/python-wunderground-todays-weather-to-email-sms-to-phone/' rel='bookmark' title='Python: Wunderground Todays Weather to Email SMS to Phone'>Python: Wunderground Todays Weather to Email SMS to Phone</a></li>
<li><a href='http://danfolkes.com/2010/03/31/php-gmail-imap-connection-with-database-insert/' rel='bookmark' title='PHP Gmail Imap Connection with Database Insert'>PHP Gmail Imap Connection with Database Insert</a></li>
<li><a href='http://danfolkes.com/2009/01/22/python-grab-email-from-gmail-and-insert-into-mysql-database/' rel='bookmark' title='Python: Grab Email from Gmail and Insert into MySql Database'>Python: Grab Email from Gmail and Insert into MySql Database</a></li>
</ol>
</div>
]]></description>
			<content:encoded><![CDATA[<p>First Install Pear, Mail, Mail Mime, Net SMTP.  Restart Apache:</p>

<div class="wp_syntax"><table><tr><td class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">sudo</span> <span style="color: #c20cb9; font-weight: bold;">apt-get install</span> php-pear
<span style="color: #c20cb9; font-weight: bold;">sudo</span> pear <span style="color: #c20cb9; font-weight: bold;">install</span> mail
<span style="color: #c20cb9; font-weight: bold;">sudo</span> pear <span style="color: #c20cb9; font-weight: bold;">install</span> mail_mime
<span style="color: #c20cb9; font-weight: bold;">sudo</span> pear <span style="color: #c20cb9; font-weight: bold;">install</span> Net_SMTP
<span style="color: #c20cb9; font-weight: bold;">sudo</span> <span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>init.d<span style="color: #000000; font-weight: bold;">/</span>apache2 restart</pre></td></tr></table></div>

<p>Here is the PHP code I used to send an email:</p>

<div class="wp_syntax"><table><tr><td class="code"><pre class="php" style="font-family:monospace;">try <span style="color: #009900;">&#123;</span>
	<span style="color: #b1b100;">require_once</span> <span style="color: #0000ff;">&quot;Mail.php&quot;</span><span style="color: #339933;">;</span>
&nbsp;
	<span style="color: #000088;">$from</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">&quot;from@example.com&quot;</span><span style="color: #339933;">;</span>
	<span style="color: #000088;">$to</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">&quot;<span style="color: #006699; font-weight: bold;">{$email}</span>&quot;</span><span style="color: #339933;">;</span>
	<span style="color: #000088;">$subject</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">&quot;Hi!&quot;</span><span style="color: #339933;">;</span>
	<span style="color: #000088;">$body</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">&quot;Hi,<span style="color: #000099; font-weight: bold;">\n</span><span style="color: #000099; font-weight: bold;">\n</span>How are you?&quot;</span><span style="color: #339933;">;</span>
&nbsp;
	<span style="color: #000088;">$host</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">&quot;ssl://smtp.gmail.com&quot;</span><span style="color: #339933;">;</span>
	<span style="color: #000088;">$port</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">&quot;465&quot;</span><span style="color: #339933;">;</span>
	<span style="color: #000088;">$username</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">&quot;USERNAME@gmail.com&quot;</span><span style="color: #339933;">;</span> <span style="color: #666666; font-style: italic;">//This can also be a Google Apps account</span>
	<span style="color: #000088;">$password</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">&quot;PASSWORD&quot;</span><span style="color: #339933;">;</span>
&nbsp;
	<span style="color: #000088;">$headers</span> <span style="color: #339933;">=</span> <span style="color: #990000;">array</span> <span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'From'</span> <span style="color: #339933;">=&gt;</span> <span style="color: #000088;">$from</span><span style="color: #339933;">,</span>
	  <span style="color: #0000ff;">'To'</span> <span style="color: #339933;">=&gt;</span> <span style="color: #000088;">$to</span><span style="color: #339933;">,</span>
	  <span style="color: #0000ff;">'Subject'</span> <span style="color: #339933;">=&gt;</span> <span style="color: #000088;">$subject</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #000088;">$smtp</span> <span style="color: #339933;">=</span> <span style="color: #990000;">Mail</span><span style="color: #339933;">::</span><span style="color: #004000;">factory</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'smtp'</span><span style="color: #339933;">,</span>
	  <span style="color: #990000;">array</span> <span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'host'</span> <span style="color: #339933;">=&gt;</span> <span style="color: #000088;">$host</span><span style="color: #339933;">,</span>
		<span style="color: #0000ff;">'port'</span> <span style="color: #339933;">=&gt;</span> <span style="color: #000088;">$port</span><span style="color: #339933;">,</span>
		<span style="color: #0000ff;">'auth'</span> <span style="color: #339933;">=&gt;</span> <span style="color: #009900; font-weight: bold;">true</span><span style="color: #339933;">,</span>
		<span style="color: #0000ff;">'username'</span> <span style="color: #339933;">=&gt;</span> <span style="color: #000088;">$username</span><span style="color: #339933;">,</span>
		<span style="color: #0000ff;">'password'</span> <span style="color: #339933;">=&gt;</span> <span style="color: #000088;">$password</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
	<span style="color: #000088;">$mail</span> <span style="color: #339933;">=</span> <span style="color: #000088;">$smtp</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">send</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$to</span><span style="color: #339933;">,</span> <span style="color: #000088;">$headers</span><span style="color: #339933;">,</span> <span style="color: #000088;">$body</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
	<span style="color: #b1b100;">if</span> <span style="color: #009900;">&#40;</span>PEAR<span style="color: #339933;">::</span><span style="color: #004000;">isError</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$mail</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
	  <span style="color: #b1b100;">echo</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;&lt;p&gt;&quot;</span> <span style="color: #339933;">.</span> <span style="color: #000088;">$mail</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">getMessage</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #339933;">.</span> <span style="color: #0000ff;">&quot;&lt;/p&gt;&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	 <span style="color: #009900;">&#125;</span> <span style="color: #b1b100;">else</span> <span style="color: #009900;">&#123;</span>
	  <span style="color: #b1b100;">echo</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;&lt;p&gt;Message successfully sent!&lt;/p&gt;&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	 <span style="color: #009900;">&#125;</span>
<span style="color: #009900;">&#125;</span> catch <span style="color: #009900;">&#40;</span>Exception <span style="color: #000088;">$e</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
	<span style="color: #b1b100;">echo</span> <span style="color: #0000ff;">'Caught exception: '</span><span style="color: #339933;">,</span>  <span style="color: #000088;">$e</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">getMessage</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">&quot;<span style="color: #000099; font-weight: bold;">\n</span>&quot;</span><span style="color: #339933;">;</span>
<span style="color: #009900;">&#125;</span></pre></td></tr></table></div>

<div class='yarpp-related-rss'>
<p>Related posts:<ol>
<li><a href='http://danfolkes.com/2008/09/30/python-wunderground-todays-weather-to-email-sms-to-phone/' rel='bookmark' title='Python: Wunderground Todays Weather to Email SMS to Phone'>Python: Wunderground Todays Weather to Email SMS to Phone</a></li>
<li><a href='http://danfolkes.com/2010/03/31/php-gmail-imap-connection-with-database-insert/' rel='bookmark' title='PHP Gmail Imap Connection with Database Insert'>PHP Gmail Imap Connection with Database Insert</a></li>
<li><a href='http://danfolkes.com/2009/01/22/python-grab-email-from-gmail-and-insert-into-mysql-database/' rel='bookmark' title='Python: Grab Email from Gmail and Insert into MySql Database'>Python: Grab Email from Gmail and Insert into MySql Database</a></li>
</ol></p>
</div>
]]></content:encoded>
			<wfw:commentRss>http://danfolkes.com/2012/05/01/sending-email-with-php-gmail-or-google-apps-mail-and-pear-on-ubuntu/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Converting a Magnet Link into a Torrent</title>
		<link>http://danfolkes.com/2012/04/19/converting-a-magnet-link-into-a-torrent/</link>
		<comments>http://danfolkes.com/2012/04/19/converting-a-magnet-link-into-a-torrent/#comments</comments>
		<pubDate>Thu, 19 Apr 2012 14:57:20 +0000</pubDate>
		<dc:creator>dan</dc:creator>
				<category><![CDATA[Code]]></category>
		<category><![CDATA[Python]]></category>
		<category><![CDATA[add_magnet_uri]]></category>
		<category><![CDATA[apt-get install python-libtorrent]]></category>
		<category><![CDATA[bt]]></category>
		<category><![CDATA[convert magnet]]></category>
		<category><![CDATA[create torrent]]></category>
		<category><![CDATA[create_torrent]]></category>
		<category><![CDATA[file_storage]]></category>
		<category><![CDATA[get_torrent_info]]></category>
		<category><![CDATA[import libtorrent as lt]]></category>
		<category><![CDATA[install libtorrent-python]]></category>
		<category><![CDATA[install python-libtorrent]]></category>
		<category><![CDATA[Library]]></category>
		<category><![CDATA[libtorrent]]></category>
		<category><![CDATA[libtorrent-python]]></category>
		<category><![CDATA[magnet]]></category>
		<category><![CDATA[magnet link]]></category>
		<category><![CDATA[Magnet2Torrent]]></category>
		<category><![CDATA[Magnet2Torrent.py]]></category>
		<category><![CDATA[magnetlink]]></category>
		<category><![CDATA[pirate bay]]></category>
		<category><![CDATA[python-libtorrent]]></category>
		<category><![CDATA[rtorrent]]></category>
		<category><![CDATA[start_dht]]></category>
		<category><![CDATA[sudo apt-get install python-libtorrent]]></category>
		<category><![CDATA[Ubuntu]]></category>

		<guid isPermaLink="false">http://danfolkes.com/?p=1501</guid>
		<description><![CDATA[UPDATE &#8211; 2012-04-30 &#8211; User Faless on GitHub has added a good bit of functionality. Check it out. &#8211; For some reason, my version of the rtorrent client on ubuntu does not open magnet files. So, I wanted to see if there was a way to create torrent files from magnet files. I couldn&#8217;t find [...]<div class='yarpp-related-rss'>

Related posts:<ol>
<li><a href='http://danfolkes.com/2008/02/06/torrent-search/' rel='bookmark' title='Python Torrent Search and Download (TPB)'>Python Torrent Search and Download (TPB)</a></li>
<li><a href='http://danfolkes.com/2008/08/11/python-cell-phone-number-pad-input/' rel='bookmark' title='Python &#8211; Cell Phone Number Pad Input'>Python &#8211; Cell Phone Number Pad Input</a></li>
<li><a href='http://danfolkes.com/2009/01/22/python-grab-email-from-gmail-and-insert-into-mysql-database/' rel='bookmark' title='Python: Grab Email from Gmail and Insert into MySql Database'>Python: Grab Email from Gmail and Insert into MySql Database</a></li>
</ol>
</div>
]]></description>
			<content:encoded><![CDATA[<p><strong>UPDATE &#8211; 2012-04-30 &#8211; </strong> User <a href="https://github.com/Faless">Faless</a> on GitHub has added a good bit of functionality. <a href="https://github.com/danfolkes/Magnet2Torrent">Check it out</a>.<br />
&#8211;</p>
<p>For some reason, my version of the rtorrent client on ubuntu does not open magnet files.  So, I wanted to see if there was a way to create torrent files from magnet files.  I couldn&#8217;t find a good example, so I wrote my own.</p>
<p><strong>This will convert a magnet link into a .torrent file:</strong></p>
<p>First, make sure your system has Python and the Python Library:</p>

<div class="wp_syntax"><table><tr><td class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">sudo</span> <span style="color: #c20cb9; font-weight: bold;">apt-get install</span> python-libtorrent</pre></td></tr></table></div>

<p>Then, you can run the following code by calling this command:</p>

<div class="wp_syntax"><table><tr><td class="code"><pre class="bash" style="font-family:monospace;">python Magnet2Torrent.py</pre></td></tr></table></div>

<p>File Magnet2Torrent.py:</p>

<div class="wp_syntax"><table><tr><td class="code"><pre class="python" style="font-family:monospace;"><span style="color: #483d8b;">'''
Created on Apr 19, 2012
@author: dan
'''</span>
&nbsp;
<span style="color: #ff7700;font-weight:bold;">if</span> __name__ <span style="color: #66cc66;">==</span> <span style="color: #483d8b;">'__main__'</span>:
    <span style="color: #ff7700;font-weight:bold;">import</span> libtorrent <span style="color: #ff7700;font-weight:bold;">as</span> lt
    <span style="color: #ff7700;font-weight:bold;">import</span> <span style="color: #dc143c;">time</span>
&nbsp;
    TorrentFilePath <span style="color: #66cc66;">=</span> <span style="color: #483d8b;">&quot;/home/dan/torrentfiles/&quot;</span> + <span style="color: #008000;">str</span><span style="color: black;">&#40;</span><span style="color: #dc143c;">time</span>.<span style="color: #dc143c;">time</span><span style="color: black;">&#40;</span><span style="color: black;">&#41;</span><span style="color: black;">&#41;</span> + <span style="color: #483d8b;">&quot;/&quot;</span>
    TorrentFilePath2 <span style="color: #66cc66;">=</span> <span style="color: #483d8b;">&quot;/home/dan/torrentfiles/&quot;</span> + <span style="color: #008000;">str</span><span style="color: black;">&#40;</span><span style="color: #dc143c;">time</span>.<span style="color: #dc143c;">time</span><span style="color: black;">&#40;</span><span style="color: black;">&#41;</span><span style="color: black;">&#41;</span> + <span style="color: #483d8b;">&quot;/&quot;</span> + <span style="color: #008000;">str</span><span style="color: black;">&#40;</span><span style="color: #dc143c;">time</span>.<span style="color: #dc143c;">time</span><span style="color: black;">&#40;</span><span style="color: black;">&#41;</span><span style="color: black;">&#41;</span> + <span style="color: #483d8b;">&quot;.torrent&quot;</span>
    ses <span style="color: #66cc66;">=</span> lt.<span style="color: black;">session</span><span style="color: black;">&#40;</span><span style="color: black;">&#41;</span>
    <span style="color: #808080; font-style: italic;">#ses.listen_on(6881, 6891)</span>
    params <span style="color: #66cc66;">=</span> <span style="color: black;">&#123;</span>
        <span style="color: #483d8b;">'save_path'</span>: TorrentFilePath<span style="color: #66cc66;">,</span>
        <span style="color: #483d8b;">'duplicate_is_error'</span>: <span style="color: #008000;">True</span><span style="color: black;">&#125;</span>
    link <span style="color: #66cc66;">=</span> <span style="color: #483d8b;">&quot;magnet:?xt=urn:btih:599e3fb0433505f27d35efbe398225869a2a89a9&amp;dn=ubuntu-10.04.4-server-i386.iso&amp;tr=udp%3A%2F%2Ftracker.openbittorrent.com%3A80&amp;tr=udp%3A%2F%2Ftracker.publicbt.com%3A80&amp;tr=udp%3A%2F%2Ftracker.ccc.de%3A80&quot;</span>
    handle <span style="color: #66cc66;">=</span> lt.<span style="color: black;">add_magnet_uri</span><span style="color: black;">&#40;</span>ses<span style="color: #66cc66;">,</span> link<span style="color: #66cc66;">,</span> params<span style="color: black;">&#41;</span>
<span style="color: #808080; font-style: italic;">#    ses.start_dht()</span>
    <span style="color: #ff7700;font-weight:bold;">print</span> <span style="color: #483d8b;">'saving torrent file here : '</span> + TorrentFilePath2 + <span style="color: #483d8b;">&quot; ...&quot;</span>
    <span style="color: #ff7700;font-weight:bold;">while</span> <span style="color: black;">&#40;</span><span style="color: #ff7700;font-weight:bold;">not</span> handle.<span style="color: black;">has_metadata</span><span style="color: black;">&#40;</span><span style="color: black;">&#41;</span><span style="color: black;">&#41;</span>:
        <span style="color: #dc143c;">time</span>.<span style="color: black;">sleep</span><span style="color: black;">&#40;</span><span style="color: #ff4500;">.1</span><span style="color: black;">&#41;</span>
&nbsp;
    torinfo <span style="color: #66cc66;">=</span> handle.<span style="color: black;">get_torrent_info</span><span style="color: black;">&#40;</span><span style="color: black;">&#41;</span>
&nbsp;
    fs <span style="color: #66cc66;">=</span> lt.<span style="color: black;">file_storage</span><span style="color: black;">&#40;</span><span style="color: black;">&#41;</span>
    <span style="color: #ff7700;font-weight:bold;">for</span> <span style="color: #008000;">file</span> <span style="color: #ff7700;font-weight:bold;">in</span> torinfo.<span style="color: black;">files</span><span style="color: black;">&#40;</span><span style="color: black;">&#41;</span>:
        fs.<span style="color: black;">add_file</span><span style="color: black;">&#40;</span><span style="color: #008000;">file</span><span style="color: black;">&#41;</span>
    torfile <span style="color: #66cc66;">=</span> lt.<span style="color: black;">create_torrent</span><span style="color: black;">&#40;</span>fs<span style="color: black;">&#41;</span>
    torfile.<span style="color: black;">set_comment</span><span style="color: black;">&#40;</span>torinfo.<span style="color: black;">comment</span><span style="color: black;">&#40;</span><span style="color: black;">&#41;</span><span style="color: black;">&#41;</span>
    torfile.<span style="color: black;">set_creator</span><span style="color: black;">&#40;</span>torinfo.<span style="color: black;">creator</span><span style="color: black;">&#40;</span><span style="color: black;">&#41;</span><span style="color: black;">&#41;</span>
&nbsp;
    f <span style="color: #66cc66;">=</span> <span style="color: #008000;">open</span><span style="color: black;">&#40;</span>TorrentFilePath2 + <span style="color: #483d8b;">&quot;torrentfile.torrent&quot;</span><span style="color: #66cc66;">,</span> <span style="color: #483d8b;">&quot;wb&quot;</span><span style="color: black;">&#41;</span>
    f.<span style="color: black;">write</span><span style="color: black;">&#40;</span>lt.<span style="color: black;">bencode</span><span style="color: black;">&#40;</span>torfile.<span style="color: black;">generate</span><span style="color: black;">&#40;</span><span style="color: black;">&#41;</span><span style="color: black;">&#41;</span><span style="color: black;">&#41;</span>
    f.<span style="color: black;">close</span><span style="color: black;">&#40;</span><span style="color: black;">&#41;</span>
    <span style="color: #ff7700;font-weight:bold;">print</span> <span style="color: #483d8b;">'saved and closing...'</span>
&nbsp;
<span style="color: #808080; font-style: italic;">#Uncomment to Download the Torrent:</span>
<span style="color: #808080; font-style: italic;">#    print 'starting torrent download...'</span>
&nbsp;
<span style="color: #808080; font-style: italic;">#    while (handle.status().state != lt.torrent_status.seeding):</span>
<span style="color: #808080; font-style: italic;">#        s = handle.status()</span>
<span style="color: #808080; font-style: italic;">#        time.sleep(55)</span>
<span style="color: #808080; font-style: italic;">#        print 'downloading...'</span></pre></td></tr></table></div>

<p>This will create a folder inside of &#8216;/home/dan/torrentfiles/&#8217; with a structure like:</p>
<pre lang='bash'>/home/dan/torrentfiles/545465456.12/545465456.12.torrent
<pre>
<p>I added this to GitHub if you want to Fork it.<br />
<a href="https://github.com/danfolkes/Magnet2Torrent">https://github.com/danfolkes/Magnet2Torrent</a></p>
<p>ENJOY!</p>
<div class='yarpp-related-rss'>
<p>Related posts:<ol>
<li><a href='http://danfolkes.com/2008/02/06/torrent-search/' rel='bookmark' title='Python Torrent Search and Download (TPB)'>Python Torrent Search and Download (TPB)</a></li>
<li><a href='http://danfolkes.com/2008/08/11/python-cell-phone-number-pad-input/' rel='bookmark' title='Python &#8211; Cell Phone Number Pad Input'>Python &#8211; Cell Phone Number Pad Input</a></li>
<li><a href='http://danfolkes.com/2009/01/22/python-grab-email-from-gmail-and-insert-into-mysql-database/' rel='bookmark' title='Python: Grab Email from Gmail and Insert into MySql Database'>Python: Grab Email from Gmail and Insert into MySql Database</a></li>
</ol></p>
</div>
]]></content:encoded>
			<wfw:commentRss>http://danfolkes.com/2012/04/19/converting-a-magnet-link-into-a-torrent/feed/</wfw:commentRss>
		<slash:comments>9</slash:comments>
		</item>
		<item>
		<title>How to Remove All Facebook Friends &#8211; Script</title>
		<link>http://danfolkes.com/2012/03/23/how-to-remove-all-facebook-friends-script/</link>
		<comments>http://danfolkes.com/2012/03/23/how-to-remove-all-facebook-friends-script/#comments</comments>
		<pubDate>Fri, 23 Mar 2012 14:57:47 +0000</pubDate>
		<dc:creator>dan</dc:creator>
				<category><![CDATA[Code]]></category>
		<category><![CDATA[Javascript]]></category>
		<category><![CDATA[Software]]></category>
		<category><![CDATA[automated]]></category>
		<category><![CDATA[delete all of my friends]]></category>
		<category><![CDATA[delete all of your friends]]></category>
		<category><![CDATA[facebook]]></category>
		<category><![CDATA[facebook friends]]></category>
		<category><![CDATA[Firefox]]></category>
		<category><![CDATA[HowTo]]></category>
		<category><![CDATA[Remove All]]></category>
		<category><![CDATA[Remove All Facebook Friends]]></category>
		<category><![CDATA[Remove All Friends]]></category>
		<category><![CDATA[script]]></category>
		<category><![CDATA[Selenium IDE]]></category>
		<category><![CDATA[unfriend friends]]></category>

		<guid isPermaLink="false">http://danfolkes.com/?p=1489</guid>
		<description><![CDATA[I made a script that will allow you to automatically remove all your Facebook friends at once. Here is what you are going to need: Firefox Selenium IDE (under Selenium IDE paragraph) You will have to restart Firefox after the plugin installs. Script File: Facebook &#8211; Remove All Friends Script for Selenium IDE.txt 1. Open [...]<div class='yarpp-related-rss'>

Related posts:<ol>
<li><a href='http://danfolkes.com/2011/05/25/facebook-website-integration-html/' rel='bookmark' title='Facebook Website Integration &#8211; HTML'>Facebook Website Integration &#8211; HTML</a></li>
<li><a href='http://danfolkes.com/2009/03/04/howto-setup-an-aggregated-rss-feed-for-your-friends-using-google-reader/' rel='bookmark' title='HOWTO: Setup an Aggregated RSS feed for your Friends using Google Reader'>HOWTO: Setup an Aggregated RSS feed for your Friends using Google Reader</a></li>
<li><a href='http://danfolkes.com/2009/02/16/hamachi-install-for-starcraft/' rel='bookmark' title='Hamachi Install for Starcraft'>Hamachi Install for Starcraft</a></li>
</ol>
</div>
]]></description>
			<content:encoded><![CDATA[<p>I made a script that will allow you to automatically remove all your Facebook friends at once.</p>
<p><strong>Here is what you are going to need:</strong></p>
<ul>
<li>Firefox</li>
<li><a href="http://seleniumhq.org/download/">Selenium IDE</a> (under Selenium IDE paragraph)</li>
<li>You will have to restart Firefox after the plugin installs.</li>
<li>Script File: <a href='http://danfolkes.com/wp-content/uploads/2012/03/Facebook-Remove-All-Friends-Script-for-Selenium-IDE.txt'>Facebook &#8211; Remove All Friends Script for Selenium IDE.txt</a></li>
</ul>
<p><strong>1. Open Firefox, Open Facebook and login!</strong></p>
<p><strong>2. Now, you must open the IDE</strong> by going: Firefox > Developer Tools > Selenium IDE (Ctrl + Alt + S on some computers)<br />
<img src="http://danfolkes.com/wp-content/uploads/2012/03/Open-Selenium-IDE-in-Firefox.jpg" alt="" title="Open-Selenium-IDE-in-Firefox" width="414" height="453" class="alignnone size-full wp-image-1494" /></p>
<p><strong>3. Load Script File :</strong><br />
In Selenium IDE, do a File > Open > [Select the script file from above]<br />
OK, the script is loaded and should look like this:<br />
<img src="http://danfolkes.com/wp-content/uploads/2012/03/Remove-All-Friends-From-Facebook.jpg" alt="" title="Remove-All-Friends-From-Facebook" width="528" height="423" class="alignnone size-full wp-image-1493" /></p>
<p><strong>4. Test the script</strong> before you start by clicking on the individual items and watching what Firefox does.  Start by clicking on the first few in order.  (open /friends/,click css=&#8230; , click=&#8230;Report,)</p>
<p><strong>5. If all that seems good, then run the test</strong> by doing : Actions > Play Current Test Case.</p>
<p><strong>6. Now you wait. Go get some coffee. </strong>You should now see your browser doing a bunch of automated things and wave goodbye to all your precious friends.</p>
<p><strong>Tips:</strong></p>
<ul>
<li>You can easily modify the script by looking through the <a href="http://seleniumhq.org/docs/">documentation</a>.</li>
<li>You can easily lengthen the script by going clicking on the [Source] tab and copy and pasting from OPEN friends to click OK</li>
<li>Or, you can add <a href="http://51elliot.blogspot.com/2008/02/selenium-ide-goto.html">flow control/loops</a></li>
<li>You can ask questions here: <a href="http://stackoverflow.com/questions/tagged/selenium">http://stackoverflow.com/questions/tagged/selenium</a></li>
<li>A warning message will not be sent to your friends, so feel free to delete as many friends as you want.</li>
</ul>
<div class='yarpp-related-rss'>
<p>Related posts:<ol>
<li><a href='http://danfolkes.com/2011/05/25/facebook-website-integration-html/' rel='bookmark' title='Facebook Website Integration &#8211; HTML'>Facebook Website Integration &#8211; HTML</a></li>
<li><a href='http://danfolkes.com/2009/03/04/howto-setup-an-aggregated-rss-feed-for-your-friends-using-google-reader/' rel='bookmark' title='HOWTO: Setup an Aggregated RSS feed for your Friends using Google Reader'>HOWTO: Setup an Aggregated RSS feed for your Friends using Google Reader</a></li>
<li><a href='http://danfolkes.com/2009/02/16/hamachi-install-for-starcraft/' rel='bookmark' title='Hamachi Install for Starcraft'>Hamachi Install for Starcraft</a></li>
</ol></p>
</div>
]]></content:encoded>
			<wfw:commentRss>http://danfolkes.com/2012/03/23/how-to-remove-all-facebook-friends-script/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Web Service using JSONP from External Domain &#8211; PHP &#8211; JQuery</title>
		<link>http://danfolkes.com/2012/02/03/web-service-using-jsonp-from-external-domain-php-jquery/</link>
		<comments>http://danfolkes.com/2012/02/03/web-service-using-jsonp-from-external-domain-php-jquery/#comments</comments>
		<pubDate>Fri, 03 Feb 2012 15:57:31 +0000</pubDate>
		<dc:creator>dan</dc:creator>
				<category><![CDATA[Code]]></category>
		<category><![CDATA[Javascript]]></category>
		<category><![CDATA[jQuery]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[?callback]]></category>
		<category><![CDATA[AJAX]]></category>
		<category><![CDATA[async]]></category>
		<category><![CDATA[available]]></category>
		<category><![CDATA[callbackName]]></category>
		<category><![CDATA[cross site]]></category>
		<category><![CDATA[cross site script]]></category>
		<category><![CDATA[dataType]]></category>
		<category><![CDATA[dataType: jsonp]]></category>
		<category><![CDATA[Domain]]></category>
		<category><![CDATA[External]]></category>
		<category><![CDATA[External Domain]]></category>
		<category><![CDATA[getJSON]]></category>
		<category><![CDATA[javascript]]></category>
		<category><![CDATA[jQuery.ajax]]></category>
		<category><![CDATA[JSON]]></category>
		<category><![CDATA[JSONP]]></category>
		<category><![CDATA[jsonpCallback]]></category>
		<category><![CDATA[onJSONPLoad]]></category>
		<category><![CDATA[script]]></category>
		<category><![CDATA[success]]></category>
		<category><![CDATA[Web Service]]></category>
		<category><![CDATA[Webservice]]></category>
		<category><![CDATA[XSS]]></category>

		<guid isPermaLink="false">http://danfolkes.com/?p=1482</guid>
		<description><![CDATA[You may want to look at this previous post where I setup a PHP Webservice that uses JSON PDO – Accessed by JQuery AJAX OK, so this code will use php to generate the JSON code that will get delivered over the internet to the JSONP (JSON Padding) client on an external domain. This allows [...]<div class='yarpp-related-rss'>

Related posts:<ol>
<li><a href='http://danfolkes.com/2012/01/06/php-webservice-that-uses-json-pdo-accessed-by-jquery-ajax/' rel='bookmark' title='PHP Webservice that uses JSON PDO &#8211; Accessed by JQuery AJAX'>PHP Webservice that uses JSON PDO &#8211; Accessed by JQuery AJAX</a></li>
<li><a href='http://danfolkes.com/2011/11/07/asp-net-update-panel-javascript-event-jquery-click/' rel='bookmark' title='ASP.Net Update Panel &#8211; Javascript Event &#8211; jQuery Click'>ASP.Net Update Panel &#8211; Javascript Event &#8211; jQuery Click</a></li>
<li><a href='http://danfolkes.com/2009/10/19/override-the-window-onload-javascript-function/' rel='bookmark' title='Override the window.onload javascript function'>Override the window.onload javascript function</a></li>
</ol>
</div>
]]></description>
			<content:encoded><![CDATA[<p>You may want to look at this previous post where I setup a <a href="/2012/01/06/php-webservice-that-uses-json-pdo-accessed-by-jquery-ajax/">PHP Webservice that uses JSON PDO – Accessed by JQuery AJAX</a></p>
<p>OK, so this code will use php to generate the JSON code that will get delivered over the internet to the JSONP (JSON Padding) client on an external domain.  This allows your webservice to be available too whoever wants to call it.</p>
<p>Here is the PHP Code: (Not all of it, but enough to get the idea)</p>

<div class="wp_syntax"><table><tr><td class="code"><pre class="php" style="font-family:monospace;"><span style="color: #666666; font-style: italic;">//http://SERVER_domain.com/webservice.php</span>
<span style="color: #000000; font-weight: bold;">private</span> <span style="color: #000000; font-weight: bold;">function</span> GetTriviaTag<span style="color: #009900;">&#40;</span><span style="color: #000088;">$row</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
	<span style="color: #000088;">$t</span> <span style="color: #339933;">=</span> <span style="color: #000000; font-weight: bold;">new</span> Tag<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #000088;">$t</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">id</span> <span style="color: #339933;">=</span> <span style="color: #000088;">$row</span><span style="color: #009900;">&#91;</span><span style="color: #0000ff;">'id'</span><span style="color: #009900;">&#93;</span><span style="color: #339933;">;</span>
	<span style="color: #000088;">$t</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">triviaid</span> <span style="color: #339933;">=</span> <span style="color: #000088;">$row</span><span style="color: #009900;">&#91;</span><span style="color: #0000ff;">'triviaid'</span><span style="color: #009900;">&#93;</span><span style="color: #339933;">;</span>
	<span style="color: #000088;">$t</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">tagid</span> <span style="color: #339933;">=</span> <span style="color: #000088;">$row</span><span style="color: #009900;">&#91;</span><span style="color: #0000ff;">'tagid'</span><span style="color: #009900;">&#93;</span><span style="color: #339933;">;</span>
	<span style="color: #b1b100;">return</span> <span style="color: #000088;">$t</span><span style="color: #339933;">;</span>
<span style="color: #009900;">&#125;</span>
<span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000000; font-weight: bold;">function</span> GetWhere<span style="color: #009900;">&#40;</span><span style="color: #000088;">$where</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
	<span style="color: #000088;">$retArray</span><span style="color: #339933;">;</span>
&nbsp;
	<span style="color: #000088;">$sql</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">&quot;SELECT * FROM trivia_tags WHERE <span style="color: #006699; font-weight: bold;">{$where}</span>&quot;</span><span style="color: #339933;">;</span>
	<span style="color: #b1b100;">foreach</span> <span style="color: #009900;">&#40;</span><span style="color: #000088;">$this</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">pdo</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">query</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$sql</span><span style="color: #009900;">&#41;</span> <span style="color: #b1b100;">as</span> <span style="color: #000088;">$row</span><span style="color: #009900;">&#41;</span>
	<span style="color: #009900;">&#123;</span>
		<span style="color: #000088;">$retArray</span><span style="color: #009900;">&#91;</span><span style="color: #009900;">&#93;</span> <span style="color: #339933;">=</span> <span style="color: #000088;">$this</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">GetTriviaTag</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$row</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #009900;">&#125;</span>
	<span style="color: #b1b100;">return</span> <span style="color: #000088;">$retArray</span><span style="color: #339933;">;</span>
<span style="color: #009900;">&#125;</span>
<span style="color: #000088;">$where</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">&quot; (1 = 1)&quot;</span><span style="color: #339933;">;</span>  <span style="color: #666666; font-style: italic;">// THIS WILL SELECT ALL</span>
<span style="color: #000088;">$tarray</span> <span style="color: #339933;">=</span> GetWhere<span style="color: #009900;">&#40;</span><span style="color: #000088;">$where</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
<span style="color: #666666; font-style: italic;">//OUTPUT JSON:</span>
<span style="color: #990000;">header</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'Content-type: application/json'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #b1b100;">echo</span> <span style="color: #000088;">$_GET</span><span style="color: #009900;">&#91;</span><span style="color: #0000ff;">'callback'</span><span style="color: #009900;">&#93;</span><span style="color: #339933;">;</span>  <span style="color: #666666; font-style: italic;">// &lt;-- THIS IS IMPORTANT FOR EXTERNAL DOMAIN ACCESS!!!</span>
<span style="color: #b1b100;">echo</span> <span style="color: #0000ff;">&quot;(&quot;</span> <span style="color: #339933;">.</span> <span style="color: #990000;">json_encode</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$tarray</span><span style="color: #009900;">&#41;</span> <span style="color: #339933;">.</span> <span style="color: #0000ff;">&quot;)&quot;</span><span style="color: #339933;">;</span></pre></td></tr></table></div>

<p>And now, to access it from javascript in an external domain (non &#8211; SERVER_domain.com ):</p>
<p>http://CLIENT_domain.com/Test.html:</p>

<div class="wp_syntax"><table><tr><td class="code"><pre class="php" style="font-family:monospace;"><span style="color: #339933;">&lt;</span>html<span style="color: #339933;">&gt;</span>
	<span style="color: #339933;">&lt;</span>head<span style="color: #339933;">&gt;</span>
		<span style="color: #339933;">&lt;</span>title<span style="color: #339933;">&gt;</span>Test<span style="color: #339933;">&lt;/</span>title<span style="color: #339933;">&gt;</span>
		<span style="color: #339933;">&lt;</span>script src<span style="color: #339933;">=</span><span style="color: #0000ff;">&quot;http://code.jquery.com/jquery-latest.js&quot;</span><span style="color: #339933;">&gt;</span><span style="color: #000000; font-weight: bold;">&lt;/script&gt;</span>
	<span style="color: #339933;">&lt;/</span>head<span style="color: #339933;">&gt;</span>
	<span style="color: #339933;">&lt;</span>body<span style="color: #339933;">&gt;</span>
		<span style="color: #339933;">&lt;</span>div id<span style="color: #339933;">=</span><span style="color: #0000ff;">&quot;triviaQuestions&quot;</span><span style="color: #339933;">&gt;</span> loading<span style="color: #339933;">...</span> <span style="color: #339933;">&lt;/</span>div<span style="color: #339933;">&gt;</span>
		<span style="color: #339933;">&lt;</span>script<span style="color: #339933;">&gt;</span>
			$<span style="color: #009900;">&#40;</span><span style="color: #000000; font-weight: bold;">function</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
				<span style="color: #666666; font-style: italic;">// THE 'callback=?' in this request is IMPORTANT FOR EXTERNAL DOMAIN ACCESS!!!</span>
				$<span style="color: #339933;">.</span>getJSON<span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'http://SERVER_domain.com/webservice.php&amp;callback=?'</span><span style="color: #339933;">,</span> <span style="color: #000000; font-weight: bold;">function</span><span style="color: #009900;">&#40;</span>data<span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
					<span style="color: #000000; font-weight: bold;">var</span> items <span style="color: #339933;">=</span> <span style="color: #009900;">&#91;</span><span style="color: #009900;">&#93;</span><span style="color: #339933;">;</span>
					<span style="color: #000000; font-weight: bold;">var</span> htmlResult <span style="color: #339933;">=</span> <span style="color: #0000ff;">&quot;&quot;</span><span style="color: #339933;">;</span>
					$<span style="color: #339933;">.</span><span style="color: #990000;">each</span><span style="color: #009900;">&#40;</span>data<span style="color: #339933;">,</span> <span style="color: #000000; font-weight: bold;">function</span><span style="color: #009900;">&#40;</span><span style="color: #990000;">key</span><span style="color: #339933;">,</span> val<span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
						htmlResult <span style="color: #339933;">+=</span> <span style="color: #0000ff;">&quot;&lt;br /&gt;Q: &quot;</span><span style="color: #339933;">+</span> val<span style="color: #339933;">.</span>id <span style="color: #339933;">+</span><span style="color: #0000ff;">&quot;, '&quot;</span><span style="color: #339933;">+</span> val<span style="color: #339933;">.</span>question <span style="color: #339933;">+</span><span style="color: #0000ff;">&quot;&quot;</span><span style="color: #339933;">;</span>
					<span style="color: #009900;">&#125;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
					$<span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'#triviaQuestions'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">.</span>html<span style="color: #009900;">&#40;</span>htmlResult<span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
				<span style="color: #009900;">&#125;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
			<span style="color: #009900;">&#125;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
		<span style="color: #000000; font-weight: bold;">&lt;/script&gt;</span>
	<span style="color: #339933;">&lt;/</span>body<span style="color: #339933;">&gt;</span>
<span style="color: #339933;">&lt;/</span>html<span style="color: #339933;">&gt;</span></pre></td></tr></table></div>

<div class='yarpp-related-rss'>
<p>Related posts:<ol>
<li><a href='http://danfolkes.com/2012/01/06/php-webservice-that-uses-json-pdo-accessed-by-jquery-ajax/' rel='bookmark' title='PHP Webservice that uses JSON PDO &#8211; Accessed by JQuery AJAX'>PHP Webservice that uses JSON PDO &#8211; Accessed by JQuery AJAX</a></li>
<li><a href='http://danfolkes.com/2011/11/07/asp-net-update-panel-javascript-event-jquery-click/' rel='bookmark' title='ASP.Net Update Panel &#8211; Javascript Event &#8211; jQuery Click'>ASP.Net Update Panel &#8211; Javascript Event &#8211; jQuery Click</a></li>
<li><a href='http://danfolkes.com/2009/10/19/override-the-window-onload-javascript-function/' rel='bookmark' title='Override the window.onload javascript function'>Override the window.onload javascript function</a></li>
</ol></p>
</div>
]]></content:encoded>
			<wfw:commentRss>http://danfolkes.com/2012/02/03/web-service-using-jsonp-from-external-domain-php-jquery/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>PHP Webservice that uses JSON PDO &#8211; Accessed by JQuery AJAX</title>
		<link>http://danfolkes.com/2012/01/06/php-webservice-that-uses-json-pdo-accessed-by-jquery-ajax/</link>
		<comments>http://danfolkes.com/2012/01/06/php-webservice-that-uses-json-pdo-accessed-by-jquery-ajax/#comments</comments>
		<pubDate>Fri, 06 Jan 2012 15:25:58 +0000</pubDate>
		<dc:creator>dan</dc:creator>
				<category><![CDATA[Javascript]]></category>
		<category><![CDATA[jQuery]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[application/json]]></category>
		<category><![CDATA[array]]></category>
		<category><![CDATA[Content-type]]></category>
		<category><![CDATA[Content-type: application/json]]></category>
		<category><![CDATA[get]]></category>
		<category><![CDATA[getJSON]]></category>
		<category><![CDATA[header]]></category>
		<category><![CDATA[javascript]]></category>
		<category><![CDATA[json_encode]]></category>
		<category><![CDATA[Request]]></category>
		<category><![CDATA[Response]]></category>

		<guid isPermaLink="false">http://danfolkes.com/?p=1470</guid>
		<description><![CDATA[You may want to look at this previous post where I setup a Web Service using JSONP from External Domain – PHP – JQuery The HTML that calls the Javascript: &#60;div id=&#34;taglist&#34;&#62;&#60;/div&#62; &#60;input name=&#34;searchTags&#34; id=&#34;searchTags&#34; type=&#34;text&#34; /&#62; &#60;input type=&#34;button&#34; name=&#34;searchtags&#34; onclick=&#34;getTags()&#34; value=&#34;search&#34;/&#62; &#60;div id=&#34;tagresult&#34;&#62; &#60;/div&#62; The JavaScript (JQuery) AJAX Request and Response Processing: function getTags&#40;&#41; [...]<div class='yarpp-related-rss'>

Related posts:<ol>
<li><a href='http://danfolkes.com/2012/02/03/web-service-using-jsonp-from-external-domain-php-jquery/' rel='bookmark' title='Web Service using JSONP from External Domain &#8211; PHP &#8211; JQuery'>Web Service using JSONP from External Domain &#8211; PHP &#8211; JQuery</a></li>
<li><a href='http://danfolkes.com/2011/02/11/jquery-ajax-extra-parameters-get-success/' rel='bookmark' title='jQuery &#8211; Ajax &#8211; Extra Parameters &#8211; GET, success'>jQuery &#8211; Ajax &#8211; Extra Parameters &#8211; GET, success</a></li>
<li><a href='http://danfolkes.com/2011/11/07/asp-net-update-panel-javascript-event-jquery-click/' rel='bookmark' title='ASP.Net Update Panel &#8211; Javascript Event &#8211; jQuery Click'>ASP.Net Update Panel &#8211; Javascript Event &#8211; jQuery Click</a></li>
</ol>
</div>
]]></description>
			<content:encoded><![CDATA[<p>You may want to look at this previous post where I setup a <a href="/2012/02/03/web-service-using-jsonp-from-external-domain-php-jquery/">Web Service using JSONP from External Domain – PHP – JQuery</a></p>
<p>The HTML that calls the Javascript:</p>

<div class="wp_syntax"><table><tr><td class="code"><pre class="html4strict" style="font-family:monospace;"><span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">div</span> <span style="color: #000066;">id</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;taglist&quot;</span>&gt;&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">div</span>&gt;</span>
<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">input</span> <span style="color: #000066;">name</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;searchTags&quot;</span> <span style="color: #000066;">id</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;searchTags&quot;</span> <span style="color: #000066;">type</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;text&quot;</span> <span style="color: #66cc66;">/</span>&gt;</span>
<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">input</span> <span style="color: #000066;">type</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;button&quot;</span> <span style="color: #000066;">name</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;searchtags&quot;</span> <span style="color: #000066;">onclick</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;getTags()&quot;</span> <span style="color: #000066;">value</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;search&quot;</span><span style="color: #66cc66;">/</span>&gt;</span>
<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">div</span> <span style="color: #000066;">id</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;tagresult&quot;</span>&gt;</span>
<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">div</span>&gt;</span></pre></td></tr></table></div>

<p><strong>The JavaScript </strong>(JQuery) AJAX Request and Response Processing:</p>

<div class="wp_syntax"><table><tr><td class="code"><pre class="javascript" style="font-family:monospace;"><span style="color: #000066; font-weight: bold;">function</span> getTags<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span>
	<span style="color: #009900;">&#123;</span>
		<span style="color: #000066; font-weight: bold;">var</span> q <span style="color: #339933;">=</span> $<span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'#searchTags'</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">val</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
		$.<span style="color: #660066;">getJSON</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'ws.php?type=tag&amp;wN=name&amp;wO=like&amp;wV='</span> <span style="color: #339933;">+</span> q<span style="color: #339933;">,</span> <span style="color: #000066; font-weight: bold;">function</span><span style="color: #009900;">&#40;</span>data<span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
			<span style="color: #000066; font-weight: bold;">var</span> items <span style="color: #339933;">=</span> <span style="color: #009900;">&#91;</span><span style="color: #009900;">&#93;</span><span style="color: #339933;">;</span>
			<span style="color: #000066; font-weight: bold;">var</span> htmlResult <span style="color: #339933;">=</span> <span style="color: #3366CC;">&quot;&quot;</span><span style="color: #339933;">;</span>
			$.<span style="color: #660066;">each</span><span style="color: #009900;">&#40;</span>data<span style="color: #339933;">,</span> <span style="color: #000066; font-weight: bold;">function</span><span style="color: #009900;">&#40;</span>key<span style="color: #339933;">,</span> val<span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
				<span style="color: #006600; font-style: italic;">//As you can see, you can access the JSON (at the bottom of the page) by doing val.PROPERTYNAME:</span>
				htmlResult <span style="color: #339933;">+=</span> <span style="color: #3366CC;">&quot;&lt;br /&gt;Add : &lt;a href=<span style="color: #000099; font-weight: bold;">\&quot;</span>#<span style="color: #000099; font-weight: bold;">\&quot;</span> onclick=<span style="color: #000099; font-weight: bold;">\&quot;</span>addTag(&quot;</span><span style="color: #339933;">+</span> val.<span style="color: #660066;">id</span> <span style="color: #339933;">+</span><span style="color: #3366CC;">&quot;, '&quot;</span><span style="color: #339933;">+</span> val.<span style="color: #660066;">getfullname</span> <span style="color: #339933;">+</span><span style="color: #3366CC;">&quot;'); return false;<span style="color: #000099; font-weight: bold;">\&quot;</span>&gt;&quot;</span><span style="color: #339933;">+</span> val.<span style="color: #660066;">getfullname</span> <span style="color: #339933;">+</span><span style="color: #3366CC;">&quot;&lt;/a&gt;&quot;</span><span style="color: #339933;">;</span>
			<span style="color: #009900;">&#125;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
			$<span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'#tagresult'</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">html</span><span style="color: #009900;">&#40;</span>htmlResult<span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
		<span style="color: #009900;">&#125;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #009900;">&#125;</span></pre></td></tr></table></div>

<p><strong>PHP Code</strong> that returns JSON in the PHP file called by the AJAX: (ws.php)</p>

<div class="wp_syntax"><table><tr><td class="code"><pre class="php" style="font-family:monospace;">	<span style="color: #000088;">$ta</span> <span style="color: #339933;">=</span> <span style="color: #000000; font-weight: bold;">new</span> TagAccess<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #000088;">$tarray</span> <span style="color: #339933;">=</span> <span style="color: #000088;">$ta</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">GetTagsWhere</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot; <span style="color: #006699; font-weight: bold;">{$whereName}</span> LIKE '%<span style="color: #006699; font-weight: bold;">{$whereVariable}</span>%'&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #990000;">header</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'Content-type: application/json'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #b1b100;">echo</span> <span style="color: #0000ff;">&quot;&quot;</span><span style="color: #339933;">,</span>  <span style="color: #990000;">json_encode</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$tarray</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">&quot;&quot;</span><span style="color: #339933;">;</span></pre></td></tr></table></div>

<p>The GetTagsWhere Helper Function:</p>

<div class="wp_syntax"><table><tr><td class="code"><pre class="php" style="font-family:monospace;">    <span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000000; font-weight: bold;">function</span> GetTagsWhere<span style="color: #009900;">&#40;</span><span style="color: #000088;">$where</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
    	<span style="color: #000088;">$retArray</span><span style="color: #339933;">;</span>
&nbsp;
    	<span style="color: #000088;">$sql</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">&quot;SELECT * FROM tags WHERE <span style="color: #006699; font-weight: bold;">{$where}</span>&quot;</span><span style="color: #339933;">;</span>
    	<span style="color: #666666; font-style: italic;">// THE PDO Object was created previously</span>
	<span style="color: #b1b100;">foreach</span> <span style="color: #009900;">&#40;</span><span style="color: #000088;">$this</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">pdo</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">query</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$sql</span><span style="color: #009900;">&#41;</span> <span style="color: #b1b100;">as</span> <span style="color: #000088;">$row</span><span style="color: #009900;">&#41;</span>
	<span style="color: #009900;">&#123;</span>
		<span style="color: #000088;">$retArray</span><span style="color: #009900;">&#91;</span><span style="color: #009900;">&#93;</span> <span style="color: #339933;">=</span> <span style="color: #000088;">$this</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">GetTag</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$row</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #009900;">&#125;</span>
	<span style="color: #b1b100;">return</span> <span style="color: #000088;">$retArray</span><span style="color: #339933;">;</span>
    <span style="color: #009900;">&#125;</span></pre></td></tr></table></div>

<p><strong>JSON</strong> Returned:</p>

<div class="wp_syntax"><table><tr><td class="code"><pre class="javascript" style="font-family:monospace;"><span style="color: #009900;">&#91;</span><span style="color: #009900;">&#123;</span><span style="color: #3366CC;">&quot;id&quot;</span><span style="color: #339933;">:</span><span style="color: #3366CC;">&quot;4&quot;</span><span style="color: #339933;">,</span><span style="color: #3366CC;">&quot;name&quot;</span><span style="color: #339933;">:</span><span style="color: #3366CC;">&quot;FICTION&quot;</span><span style="color: #339933;">,</span><span style="color: #3366CC;">&quot;parentid&quot;</span><span style="color: #339933;">:</span><span style="color: #3366CC;">&quot;3&quot;</span><span style="color: #339933;">,</span><span style="color: #3366CC;">&quot;getfullname&quot;</span><span style="color: #339933;">:</span><span style="color: #3366CC;">&quot;BOOKS &gt; FICTION&quot;</span><span style="color: #009900;">&#125;</span><span style="color: #339933;">,</span><span style="color: #009900;">&#123;</span><span style="color: #3366CC;">&quot;id&quot;</span><span style="color: #339933;">:</span><span style="color: #3366CC;">&quot;5&quot;</span><span style="color: #339933;">,</span><span style="color: #3366CC;">&quot;name&quot;</span><span style="color: #339933;">:</span><span style="color: #3366CC;">&quot;NON-FICTION&quot;</span><span style="color: #339933;">,</span><span style="color: #3366CC;">&quot;parentid&quot;</span><span style="color: #339933;">:</span><span style="color: #3366CC;">&quot;3&quot;</span><span style="color: #339933;">,</span><span style="color: #3366CC;">&quot;getfullname&quot;</span><span style="color: #339933;">:</span><span style="color: #3366CC;">&quot;BOOKS &gt; NON-FICTION&quot;</span><span style="color: #009900;">&#125;</span><span style="color: #009900;">&#93;</span></pre></td></tr></table></div>

<div class='yarpp-related-rss'>
<p>Related posts:<ol>
<li><a href='http://danfolkes.com/2012/02/03/web-service-using-jsonp-from-external-domain-php-jquery/' rel='bookmark' title='Web Service using JSONP from External Domain &#8211; PHP &#8211; JQuery'>Web Service using JSONP from External Domain &#8211; PHP &#8211; JQuery</a></li>
<li><a href='http://danfolkes.com/2011/02/11/jquery-ajax-extra-parameters-get-success/' rel='bookmark' title='jQuery &#8211; Ajax &#8211; Extra Parameters &#8211; GET, success'>jQuery &#8211; Ajax &#8211; Extra Parameters &#8211; GET, success</a></li>
<li><a href='http://danfolkes.com/2011/11/07/asp-net-update-panel-javascript-event-jquery-click/' rel='bookmark' title='ASP.Net Update Panel &#8211; Javascript Event &#8211; jQuery Click'>ASP.Net Update Panel &#8211; Javascript Event &#8211; jQuery Click</a></li>
</ol></p>
</div>
]]></content:encoded>
			<wfw:commentRss>http://danfolkes.com/2012/01/06/php-webservice-that-uses-json-pdo-accessed-by-jquery-ajax/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Fantastic Thrift Store &#8211; Hours</title>
		<link>http://danfolkes.com/2011/12/07/fantastic-thrift-hours/</link>
		<comments>http://danfolkes.com/2011/12/07/fantastic-thrift-hours/#comments</comments>
		<pubDate>Wed, 07 Dec 2011 19:14:56 +0000</pubDate>
		<dc:creator>dan</dc:creator>
				<category><![CDATA[Thoughts]]></category>
		<category><![CDATA[10am]]></category>
		<category><![CDATA[6pm]]></category>
		<category><![CDATA[CLOSED]]></category>
		<category><![CDATA[Fan Tastic Thrift Hours]]></category>
		<category><![CDATA[Fan-tastic]]></category>
		<category><![CDATA[Fan-tastic Thrift]]></category>
		<category><![CDATA[Fan-tastic Thrift Store]]></category>
		<category><![CDATA[Fantastic]]></category>
		<category><![CDATA[Fantastic Thrift Hours]]></category>
		<category><![CDATA[Fantastic Thrift Store]]></category>
		<category><![CDATA[Friday]]></category>
		<category><![CDATA[Monday]]></category>
		<category><![CDATA[Saturday]]></category>
		<category><![CDATA[Sunday]]></category>
		<category><![CDATA[Thursday]]></category>
		<category><![CDATA[Tuesday]]></category>
		<category><![CDATA[Wednesday]]></category>
		<category><![CDATA[Weekday]]></category>
		<category><![CDATA[Weekend]]></category>

		<guid isPermaLink="false">http://danfolkes.com/?p=1448</guid>
		<description><![CDATA[Fan-tastic Thrift Store Hours Monday: 10am &#8211; 6pm Tuesday: 10am &#8211; 6pm Wednesday: 10am &#8211; 6pm Thursday: 10am &#8211; 6pm Friday: 10am &#8211; 6pm Saturday: 10am &#8211; 6pm Sunday: CLOSED I thought I would call and post what they said since I I couldn&#8217;t find the store hours for Fantastic Thrift anywhere online.<div class='yarpp-related-rss'>

Related posts:<ol>
<li><a href='http://danfolkes.com/2009/07/08/good-talk-radio-schedule-richmond-va/' rel='bookmark' title='Good Talk Radio Schedule &#8211; Richmond, VA'>Good Talk Radio Schedule &#8211; Richmond, VA</a></li>
</ol>
</div>
]]></description>
			<content:encoded><![CDATA[<p><strong>Fan-tastic Thrift Store Hours</strong><br />
<strong>Monday:</strong> 10am &#8211; 6pm<br />
<strong>Tuesday:</strong> 10am &#8211; 6pm<br />
<strong>Wednesday:</strong> 10am &#8211; 6pm<br />
<strong>Thursday:</strong> 10am &#8211; 6pm<br />
<strong>Friday:</strong> 10am &#8211; 6pm<br />
<strong>Saturday:</strong> 10am &#8211; 6pm<br />
<strong>Sunday:</strong> <strong>CLOSED</strong></p>
<p>I thought I would call and post what they said since I I couldn&#8217;t find the store hours for Fantastic Thrift anywhere online. </p>
<div class='yarpp-related-rss'>
<p>Related posts:<ol>
<li><a href='http://danfolkes.com/2009/07/08/good-talk-radio-schedule-richmond-va/' rel='bookmark' title='Good Talk Radio Schedule &#8211; Richmond, VA'>Good Talk Radio Schedule &#8211; Richmond, VA</a></li>
</ol></p>
</div>
]]></content:encoded>
			<wfw:commentRss>http://danfolkes.com/2011/12/07/fantastic-thrift-hours/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>ASP.Net Update Panel &#8211; Javascript Event &#8211; jQuery Click</title>
		<link>http://danfolkes.com/2011/11/07/asp-net-update-panel-javascript-event-jquery-click/</link>
		<comments>http://danfolkes.com/2011/11/07/asp-net-update-panel-javascript-event-jquery-click/#comments</comments>
		<pubDate>Mon, 07 Nov 2011 19:38:47 +0000</pubDate>
		<dc:creator>dan</dc:creator>
				<category><![CDATA[.Net]]></category>
		<category><![CDATA[Code]]></category>
		<category><![CDATA[Javascript]]></category>
		<category><![CDATA[jQuery]]></category>
		<category><![CDATA[end]]></category>
		<category><![CDATA[end Request]]></category>
		<category><![CDATA[endRequest]]></category>
		<category><![CDATA[javascript]]></category>
		<category><![CDATA[Page Request Manager]]></category>
		<category><![CDATA[PageRequest Manager]]></category>
		<category><![CDATA[PageRequestManager]]></category>
		<category><![CDATA[Request]]></category>

		<guid isPermaLink="false">http://danfolkes.com/?p=1437</guid>
		<description><![CDATA[I needed to add a onclick event to a textbox in asp.net to change it to remove text from a textbox onClick when it is clicked. The normal code would look something like this: 1 &#60;asp:TextBox ID=&#34;txtStoreLocatorZip&#34; ValidationGroup=&#34;CustomerServiceEmail&#34; runat=&#34;server&#34; Text=&#34;Enter Zip&#34; CssClass=&#34;txtStoreLocatorZip_CssClass&#34; /&#62; 1 2 3 4 5 6 7 8 9 &#60;script&#62; if &#40;$&#40;'.txtStoreLocatorZip_CssClass'&#41;.val&#40;&#41; [...]<div class='yarpp-related-rss'>

Related posts:<ol>
<li><a href='http://danfolkes.com/2012/01/06/php-webservice-that-uses-json-pdo-accessed-by-jquery-ajax/' rel='bookmark' title='PHP Webservice that uses JSON PDO &#8211; Accessed by JQuery AJAX'>PHP Webservice that uses JSON PDO &#8211; Accessed by JQuery AJAX</a></li>
<li><a href='http://danfolkes.com/2009/10/19/override-the-window-onload-javascript-function/' rel='bookmark' title='Override the window.onload javascript function'>Override the window.onload javascript function</a></li>
<li><a href='http://danfolkes.com/2012/02/03/web-service-using-jsonp-from-external-domain-php-jquery/' rel='bookmark' title='Web Service using JSONP from External Domain &#8211; PHP &#8211; JQuery'>Web Service using JSONP from External Domain &#8211; PHP &#8211; JQuery</a></li>
</ol>
</div>
]]></description>
			<content:encoded><![CDATA[<p>I needed to add a onclick event to a textbox in asp.net to change it to remove text from a textbox onClick when it is clicked.<br />
The normal code would look something like this:</p>

<div class="wp_syntax"><table><tr><td class="line_numbers"><pre>1
</pre></td><td class="code"><pre class="asp" style="font-family:monospace;"><span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>TextBox  ID<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;txtStoreLocatorZip&quot;</span> ValidationGroup<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;CustomerServiceEmail&quot;</span> runat<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;server&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Enter Zip&quot;</span> CssClass<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;txtStoreLocatorZip_CssClass&quot;</span> <span style="color: #006600; font-weight: bold;">/&gt;</span></pre></td></tr></table></div>


<div class="wp_syntax"><table><tr><td class="line_numbers"><pre>1
2
3
4
5
6
7
8
9
</pre></td><td class="code"><pre class="javascript" style="font-family:monospace;"><span style="color: #339933;">&lt;</span>script<span style="color: #339933;">&gt;</span>
        <span style="color: #000066; font-weight: bold;">if</span> <span style="color: #009900;">&#40;</span>$<span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'.txtStoreLocatorZip_CssClass'</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">val</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #339933;">==</span> <span style="color: #3366CC;">'Enter Zip'</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
            $<span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'.txtStoreLocatorZip_CssClass'</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">click</span><span style="color: #009900;">&#40;</span><span style="color: #000066; font-weight: bold;">function</span> <span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
                <span style="color: #000066; font-weight: bold;">if</span> <span style="color: #009900;">&#40;</span>$<span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'.txtStoreLocatorZip_CssClass'</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">val</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #339933;">==</span> <span style="color: #3366CC;">'Enter Zip'</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
                    $<span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'.txtStoreLocatorZip_CssClass'</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">val</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">''</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
                <span style="color: #009900;">&#125;</span>
            <span style="color: #009900;">&#125;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
        <span style="color: #009900;">&#125;</span>
<span style="color: #339933;">&lt;/</span>script<span style="color: #339933;">&gt;</span></pre></td></tr></table></div>

<p>But, this won&#8217;t quite work because my textbox is in a UpdatePanel&#8217;s ContentTemplate and the javascript is not read on postback.</p>
<p>So, This is what I ended up doing (a simplified version):</p>

<div class="wp_syntax"><table><tr><td class="line_numbers"><pre>1
2
3
4
5
</pre></td><td class="code"><pre class="asp" style="font-family:monospace;"><span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>UpdatePanel ID<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;UpdatePanel2&quot;</span> runat<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;server&quot;</span> UpdateMode<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Conditional&quot;</span><span style="color: #006600; font-weight: bold;">&gt;</span>
	<span style="color: #006600; font-weight: bold;">&lt;</span>ContentTemplate<span style="color: #006600; font-weight: bold;">&gt;</span>
		<span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>TextBox  ID<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;txtStoreLocatorZip&quot;</span> ValidationGroup<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;CustomerServiceEmail&quot;</span> runat<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;server&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Enter Zip&quot;</span> CssClass<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;txtStoreLocatorZip_CssClass&quot;</span> <span style="color: #006600; font-weight: bold;">/&gt;</span>
	<span style="color: #006600; font-weight: bold;">&lt;/</span>ContentTemplate<span style="color: #006600; font-weight: bold;">&gt;</span>
<span style="color: #006600; font-weight: bold;">&lt;/</span>asp<span style="color: #006600; font-weight: bold;">:</span>UpdatePanel<span style="color: #006600; font-weight: bold;">&gt;</span></pre></td></tr></table></div>


<div class="wp_syntax"><table><tr><td class="line_numbers"><pre>1
2
3
4
5
6
7
8
9
10
11
12
</pre></td><td class="code"><pre class="javascript" style="font-family:monospace;"><span style="color: #339933;">&lt;</span>script<span style="color: #339933;">&gt;</span>
	Sys.<span style="color: #660066;">WebForms</span>.<span style="color: #660066;">PageRequestManager</span>.<span style="color: #660066;">getInstance</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">add_endRequest</span><span style="color: #009900;">&#40;</span>endRequestHandler<span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #000066; font-weight: bold;">function</span> endRequestHandler<span style="color: #009900;">&#40;</span>sender<span style="color: #339933;">,</span> args<span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
		<span style="color: #000066; font-weight: bold;">if</span> <span style="color: #009900;">&#40;</span>$<span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'.txtStoreLocatorZip_CssClass'</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">val</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #339933;">==</span> <span style="color: #3366CC;">'Enter Zip'</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
			$<span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'.txtStoreLocatorZip_CssClass'</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">click</span><span style="color: #009900;">&#40;</span><span style="color: #000066; font-weight: bold;">function</span> <span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
				<span style="color: #000066; font-weight: bold;">if</span> <span style="color: #009900;">&#40;</span>$<span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'.txtStoreLocatorZip_CssClass'</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">val</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #339933;">==</span> <span style="color: #3366CC;">'Enter Zip'</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
					$<span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'.txtStoreLocatorZip_CssClass'</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">val</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">''</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
				<span style="color: #009900;">&#125;</span>
			<span style="color: #009900;">&#125;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
		<span style="color: #009900;">&#125;</span>
	<span style="color: #009900;">&#125;</span>
<span style="color: #339933;">&lt;/</span>script<span style="color: #339933;">&gt;</span></pre></td></tr></table></div>

<p>This will add an endRequest handler to the end of the partial page postback so that you can call a nice little function at the end of it.</p>
<p>Hope this helps some people!</p>
<div class='yarpp-related-rss'>
<p>Related posts:<ol>
<li><a href='http://danfolkes.com/2012/01/06/php-webservice-that-uses-json-pdo-accessed-by-jquery-ajax/' rel='bookmark' title='PHP Webservice that uses JSON PDO &#8211; Accessed by JQuery AJAX'>PHP Webservice that uses JSON PDO &#8211; Accessed by JQuery AJAX</a></li>
<li><a href='http://danfolkes.com/2009/10/19/override-the-window-onload-javascript-function/' rel='bookmark' title='Override the window.onload javascript function'>Override the window.onload javascript function</a></li>
<li><a href='http://danfolkes.com/2012/02/03/web-service-using-jsonp-from-external-domain-php-jquery/' rel='bookmark' title='Web Service using JSONP from External Domain &#8211; PHP &#8211; JQuery'>Web Service using JSONP from External Domain &#8211; PHP &#8211; JQuery</a></li>
</ol></p>
</div>
]]></content:encoded>
			<wfw:commentRss>http://danfolkes.com/2011/11/07/asp-net-update-panel-javascript-event-jquery-click/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Roasted Winter Squash Recipe</title>
		<link>http://danfolkes.com/2011/10/12/roasted-winter-squash/</link>
		<comments>http://danfolkes.com/2011/10/12/roasted-winter-squash/#comments</comments>
		<pubDate>Wed, 12 Oct 2011 15:53:09 +0000</pubDate>
		<dc:creator>dan</dc:creator>
				<category><![CDATA[Thoughts]]></category>
		<category><![CDATA[Recipe]]></category>
		<category><![CDATA[Roasted Pumpkin]]></category>
		<category><![CDATA[Roasted Pumpkin Recipe]]></category>
		<category><![CDATA[Roasted Winter Squash]]></category>
		<category><![CDATA[Roasted Winter Squash Recipe]]></category>
		<category><![CDATA[Spicy]]></category>
		<category><![CDATA[squash seeds]]></category>

		<guid isPermaLink="false">http://danfolkes.com/?p=1422</guid>
		<description><![CDATA[Recipe: Winter Squash, or really anything gourd-like. The spread on top contains: Some of the squash seeds Sage Something spicy, i used jalapeno, but you can use anything with kick, or don&#8217;t. Cinnamon Salt Black Pepper A little oil (olive) Instruction: Cut and place squash on cooking sheet, cut/grind up the remaining ingredients, add oil. [...]<div class='yarpp-related-rss'>

Related posts:<ol>
<li><a href='http://danfolkes.com/2009/10/19/yum-toasted-garlic-turkey-motzarella-squash-sandw-with-asparagus/' rel='bookmark' title='yum! toasted garlic turkey motzarella squash sandw with asparagus!'>yum! toasted garlic turkey motzarella squash sandw with asparagus!</a></li>
</ol>
</div>
]]></description>
			<content:encoded><![CDATA[<div class="wp-caption alignnone" style="width: 206px"><img title="Roasted Winter Squash" src="https://lh6.googleusercontent.com/-D2imtaf4NVo/TpUb3LPcIQI/AAAAAAAAA6Y/Kg-G8tHGZYY/h147/IMG_20111012_004403.jpg" alt="Roasted Winter Squash" width="196" height="147" /><p class="wp-caption-text">Roasted Winter Squash</p></div>
<p>Recipe:</p>
<ul>
<li>Winter Squash, or really anything gourd-like.</li>
</ul>
<p><strong>The spread on top contains:</strong></p>
<ul>
<li>Some of the squash seeds</li>
<li>Sage</li>
<li>Something spicy, i used jalapeno, but you can use anything with kick, or don&#8217;t.</li>
<li>Cinnamon</li>
<li>Salt</li>
<li>Black Pepper</li>
<li>A little oil (olive)</li>
</ul>
<p>Instruction:<br />
Cut and place squash on cooking sheet, cut/grind up the remaining ingredients, add oil. rub on top.<br />
Cover with tin-foil to prevent burning.<br />
Cook for ~20 min.<br />
Uncover and cook till golden brown/not burnt. (~10)</p>
<p>Bonus tip: throw in the rest of the seeds to cook them too.  They are a good snack.</p>
<div class='yarpp-related-rss'>
<p>Related posts:<ol>
<li><a href='http://danfolkes.com/2009/10/19/yum-toasted-garlic-turkey-motzarella-squash-sandw-with-asparagus/' rel='bookmark' title='yum! toasted garlic turkey motzarella squash sandw with asparagus!'>yum! toasted garlic turkey motzarella squash sandw with asparagus!</a></li>
</ol></p>
</div>
]]></content:encoded>
			<wfw:commentRss>http://danfolkes.com/2011/10/12/roasted-winter-squash/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Birds!</title>
		<link>http://danfolkes.com/2011/10/05/birds/</link>
		<comments>http://danfolkes.com/2011/10/05/birds/#comments</comments>
		<pubDate>Wed, 05 Oct 2011 20:21:25 +0000</pubDate>
		<dc:creator>dan</dc:creator>
				<category><![CDATA[Photos]]></category>
		<category><![CDATA[birds]]></category>
		<category><![CDATA[line]]></category>
		<category><![CDATA[pole]]></category>
		<category><![CDATA[power]]></category>
		<category><![CDATA[power line]]></category>
		<category><![CDATA[powerline]]></category>

		<guid isPermaLink="false">http://danfolkes.com/?p=1415</guid>
		<description><![CDATA[Google Plus Page<div class='yarpp-related-rss'>

Related posts:<ol>
<li><a href='http://danfolkes.com/2009/01/04/dis-darkness-is-spreading-version-081218/' rel='bookmark' title='DiS &#8211; Darkness is Spreading Version 08.1218'>DiS &#8211; Darkness is Spreading Version 08.1218</a></li>
<li><a href='http://danfolkes.com/2010/03/04/photo-challenge-stereoscopic/' rel='bookmark' title='Photo Challenge: Stereoscopic'>Photo Challenge: Stereoscopic</a></li>
<li><a href='http://danfolkes.com/2009/01/05/corelaborate-document-elaboration-on-the-core-formats/' rel='bookmark' title='CoreLaborate &#8211; Document Elaboration on the Core Formats'>CoreLaborate &#8211; Document Elaboration on the Core Formats</a></li>
</ol>
</div>
]]></description>
			<content:encoded><![CDATA[<div class="wp-caption alignnone" style="width: 412px"><a href="https://plus.google.com/110320235871943413247/posts/KTRNNWmeWet#110320235871943413247/posts/KTRNNWmeWet"><img class=" " title="Birds!" src="https://lh5.googleusercontent.com/-WpVxKfWJvww/ToJZIe7x42I/AAAAAAAAA2A/UeGdDCYv8rA/w402/IMAG0325.jpg" alt="Many Birds on a power line" width="402" height="240" /></a><p class="wp-caption-text">Birds</p></div>
<p><a href="https://plus.google.com/110320235871943413247/posts/KTRNNWmeWet#110320235871943413247/posts/KTRNNWmeWet">Google Plus Page</a></p>
<div class='yarpp-related-rss'>
<p>Related posts:<ol>
<li><a href='http://danfolkes.com/2009/01/04/dis-darkness-is-spreading-version-081218/' rel='bookmark' title='DiS &#8211; Darkness is Spreading Version 08.1218'>DiS &#8211; Darkness is Spreading Version 08.1218</a></li>
<li><a href='http://danfolkes.com/2010/03/04/photo-challenge-stereoscopic/' rel='bookmark' title='Photo Challenge: Stereoscopic'>Photo Challenge: Stereoscopic</a></li>
<li><a href='http://danfolkes.com/2009/01/05/corelaborate-document-elaboration-on-the-core-formats/' rel='bookmark' title='CoreLaborate &#8211; Document Elaboration on the Core Formats'>CoreLaborate &#8211; Document Elaboration on the Core Formats</a></li>
</ol></p>
</div>
]]></content:encoded>
			<wfw:commentRss>http://danfolkes.com/2011/10/05/birds/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Asp.Net &#8211; Adding Parameters to CommandType.Text</title>
		<link>http://danfolkes.com/2011/09/21/asp-net-adding-parameters-to-commandtype-text/</link>
		<comments>http://danfolkes.com/2011/09/21/asp-net-adding-parameters-to-commandtype-text/#comments</comments>
		<pubDate>Wed, 21 Sep 2011 21:35:05 +0000</pubDate>
		<dc:creator>dan</dc:creator>
				<category><![CDATA[.Net]]></category>
		<category><![CDATA[AddWithValue]]></category>
		<category><![CDATA[CommandType.Text]]></category>
		<category><![CDATA[Parameters]]></category>
		<category><![CDATA[Parameters.AddWithValue]]></category>
		<category><![CDATA[SELECT]]></category>
		<category><![CDATA[SQL]]></category>
		<category><![CDATA[where]]></category>

		<guid isPermaLink="false">http://danfolkes.com/?p=1411</guid>
		<description><![CDATA[This is how you add parameters to a standard CommandType.Text SQL call. This should prevent sql injection attacks. Using conSQL = New SqlConnection(&#34;CONNECTION STRING TO DATABASE&#34;) Try str = &#34;SELECT * FROM TableName where customerid = @CustomerID and CartType = @CartType&#34; cmdSQL = New SqlCommand(str, conSQL) cmdSQL.CommandType = CommandType.Text cmdSQL.Parameters.AddWithValue(&#34;@CustomerID&#34;, CustomerID) cmdSQL.Parameters.AddWithValue(&#34;@CartType&#34;, cartType) cartcount = [...]<div class='yarpp-related-rss'>

Related posts:<ol>
<li><a href='http://danfolkes.com/2011/08/01/asp-net-vb-listview-itemcommand-datakeys-commandname-sql/' rel='bookmark' title='Asp.Net VB &#8211; Listview &#8211; ItemCommand &#8211; DataKeys &#8211; CommandName &#8211; SQL'>Asp.Net VB &#8211; Listview &#8211; ItemCommand &#8211; DataKeys &#8211; CommandName &#8211; SQL</a></li>
<li><a href='http://danfolkes.com/2012/05/01/sending-email-with-php-gmail-or-google-apps-mail-and-pear-on-ubuntu/' rel='bookmark' title='Sending Email with PHP, Gmail or Google Apps, Mail, and PEAR on Ubuntu'>Sending Email with PHP, Gmail or Google Apps, Mail, and PEAR on Ubuntu</a></li>
<li><a href='http://danfolkes.com/2011/07/18/aspdotnetstorefront-adding-topic-to-xml-packages-or-aspx-pages/' rel='bookmark' title='ASPDotNetStoreFront: Adding Topic to XML Packages or .aspx Pages'>ASPDotNetStoreFront: Adding Topic to XML Packages or .aspx Pages</a></li>
</ol>
</div>
]]></description>
			<content:encoded><![CDATA[<p>This is how you add parameters to a standard CommandType.Text SQL call.</p>
<p>This should prevent sql injection attacks.</p>

<div class="wp_syntax"><table><tr><td class="code"><pre class="vb" style="font-family:monospace;">        Using conSQL = <span style="color: #E56717; font-weight: bold;">New</span> SqlConnection(<span style="color: #800000;">&quot;CONNECTION STRING TO DATABASE&quot;</span>)
            Try
                str = <span style="color: #800000;">&quot;SELECT * FROM TableName where customerid = @CustomerID and CartType = @CartType&quot;</span>
                cmdSQL = <span style="color: #E56717; font-weight: bold;">New</span> SqlCommand(str, conSQL)
                cmdSQL.CommandType = CommandType.Text
                cmdSQL.Parameters.AddWithValue(<span style="color: #800000;">&quot;@CustomerID&quot;</span>, CustomerID)
                cmdSQL.Parameters.AddWithValue(<span style="color: #800000;">&quot;@CartType&quot;</span>, cartType)
                cartcount = cmdSQL.ExecuteScalar()
            Catch ex <span style="color: #151B8D; font-weight: bold;">As</span> Exception
                cartcount = 0
            <span style="color: #8D38C9; font-weight: bold;">End</span> Try
        <span style="color: #8D38C9; font-weight: bold;">End</span> Using</pre></td></tr></table></div>

<div class='yarpp-related-rss'>
<p>Related posts:<ol>
<li><a href='http://danfolkes.com/2011/08/01/asp-net-vb-listview-itemcommand-datakeys-commandname-sql/' rel='bookmark' title='Asp.Net VB &#8211; Listview &#8211; ItemCommand &#8211; DataKeys &#8211; CommandName &#8211; SQL'>Asp.Net VB &#8211; Listview &#8211; ItemCommand &#8211; DataKeys &#8211; CommandName &#8211; SQL</a></li>
<li><a href='http://danfolkes.com/2012/05/01/sending-email-with-php-gmail-or-google-apps-mail-and-pear-on-ubuntu/' rel='bookmark' title='Sending Email with PHP, Gmail or Google Apps, Mail, and PEAR on Ubuntu'>Sending Email with PHP, Gmail or Google Apps, Mail, and PEAR on Ubuntu</a></li>
<li><a href='http://danfolkes.com/2011/07/18/aspdotnetstorefront-adding-topic-to-xml-packages-or-aspx-pages/' rel='bookmark' title='ASPDotNetStoreFront: Adding Topic to XML Packages or .aspx Pages'>ASPDotNetStoreFront: Adding Topic to XML Packages or .aspx Pages</a></li>
</ol></p>
</div>
]]></content:encoded>
			<wfw:commentRss>http://danfolkes.com/2011/09/21/asp-net-adding-parameters-to-commandtype-text/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Free Webcam Security &#8211; Dorgem &#8211; WinSCP</title>
		<link>http://danfolkes.com/2011/09/03/free-webcam-security-dorgem-winscp/</link>
		<comments>http://danfolkes.com/2011/09/03/free-webcam-security-dorgem-winscp/#comments</comments>
		<pubDate>Sat, 03 Sep 2011 14:59:38 +0000</pubDate>
		<dc:creator>dan</dc:creator>
				<category><![CDATA[Software]]></category>
		<category><![CDATA[Thoughts]]></category>
		<category><![CDATA[Capture Now]]></category>
		<category><![CDATA[Command]]></category>
		<category><![CDATA[default]]></category>
		<category><![CDATA[dorgem and winscp]]></category>
		<category><![CDATA[Download Dorgem]]></category>
		<category><![CDATA[Download WinSCP]]></category>
		<category><![CDATA[free home security]]></category>
		<category><![CDATA[free web cam home security]]></category>
		<category><![CDATA[free web cam security]]></category>
		<category><![CDATA[free webcam home security]]></category>
		<category><![CDATA[free webcam security]]></category>
		<category><![CDATA[home security]]></category>
		<category><![CDATA[Store Settings]]></category>
		<category><![CDATA[Web Server]]></category>
		<category><![CDATA[webcam]]></category>
		<category><![CDATA[webcam web server]]></category>

		<guid isPermaLink="false">http://danfolkes.com/?p=1403</guid>
		<description><![CDATA[This is how you setup a free home security webcam using dorgem and winscp.exe. First Download: Download WinSCP and install it.http://winscp.net/ Download Dorgem and install it. http://dorgem.sourceforge.net/ Next Configure Dorgem: Most people are going to want to use the &#8220;Web Server&#8221; option. This will setup a webserver with your webcam on it&#8230;. Pretty straight forward. [...]<div class='yarpp-related-rss'>

Related posts:<ol>
<li><a href='http://danfolkes.com/2008/11/05/wiki-based-directory-of-online-free-tv-shows/' rel='bookmark' title='Wiki Based Directory of Online Free TV Shows'>Wiki Based Directory of Online Free TV Shows</a></li>
<li><a href='http://danfolkes.com/2008/04/07/sshscpsftp-i-love-them-all/' rel='bookmark' title='SSH/SCP/SFTP I love them all.'>SSH/SCP/SFTP I love them all.</a></li>
<li><a href='http://danfolkes.com/2009/02/16/hamachi-install-for-starcraft/' rel='bookmark' title='Hamachi Install for Starcraft'>Hamachi Install for Starcraft</a></li>
</ol>
</div>
]]></description>
			<content:encoded><![CDATA[<p><img src="http://danfolkes.com/wp-content/uploads/2011/09/Dorgem_WinSCP-628x348.jpg" alt="" title="Dorgem_WinSCP" width="628" height="348" class="alignnone size-medium wp-image-1404" /></p>
<p><strong>This is how you setup a free home security webcam using dorgem and winscp.exe.</strong></p>
<p><strong>First Download:</strong></p>
<ul>
<li>Download WinSCP and install it.<a href="http://winscp.net/">http://winscp.net/</a></li>
<li>Download Dorgem and install it. <a href="http://dorgem.sourceforge.net/">http://dorgem.sourceforge.net/</a></li>
</ul>
<p><strong>Next Configure Dorgem:</strong><br />
Most people are going to want to use the &#8220;Web Server&#8221; option.  This will setup a webserver with your webcam on it&#8230;.  Pretty straight forward.</p>
<p>But, when I was looking this up, I couldn&#8217;t find anywhere that tells you how to use WinSCP. So here I go:</p>
<p><strong>First Configure WinSCP</strong></p>
<ul>
<li>Open WinSCP</li>
<li>New</li>
<li>Type in all the correct info in session</li>
<li>Make sure you set a default folder under Environment->Directories->Remote Directory</li>
<li>Save&#8230; and remember the name of the session</li>
<li>Connect and make sure you set it to remember passwords and everything</li>
</ul>
<p><strong>Second Configure Dorgem:</strong></p>
<ul>
<li>Open Dorgem</li>
<li>Preview the source</li>
<li>Click &#8220;Store Settings&#8221;
<ul>
<li>Add</li>
<li>External Program</li>
<li>Name it something to remember</li>
<li>Check Enable</li>
<li>Command: &#8220;C:\Program Files (x86)\WinSCP\winscp.exe&#8221; name_of@winscp_session.com /upload %s /defaults</li>
<li>OK</li>
</ul>
</li>
<li>Click &#8220;Capture Now&#8221; to test it out.</li>
<li>You should now see a tmp file on the WinSCP server.</li>
<li>If you dont, then you might want to try changing the path to WinSCP in the command or double check the name of the stored WinSCP session in the command. </li>
<li>Then, you can enable motion detection under &#8220;options&#8221; on the main screen</li>
</ul>
<p><strong>Hope this helps some people!</strong></p>
<div class='yarpp-related-rss'>
<p>Related posts:<ol>
<li><a href='http://danfolkes.com/2008/11/05/wiki-based-directory-of-online-free-tv-shows/' rel='bookmark' title='Wiki Based Directory of Online Free TV Shows'>Wiki Based Directory of Online Free TV Shows</a></li>
<li><a href='http://danfolkes.com/2008/04/07/sshscpsftp-i-love-them-all/' rel='bookmark' title='SSH/SCP/SFTP I love them all.'>SSH/SCP/SFTP I love them all.</a></li>
<li><a href='http://danfolkes.com/2009/02/16/hamachi-install-for-starcraft/' rel='bookmark' title='Hamachi Install for Starcraft'>Hamachi Install for Starcraft</a></li>
</ol></p>
</div>
]]></content:encoded>
			<wfw:commentRss>http://danfolkes.com/2011/09/03/free-webcam-security-dorgem-winscp/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Asp DropDownList &#8211; States &#8211; ListItem Example</title>
		<link>http://danfolkes.com/2011/08/09/asp-dropdownlist-states-listitem-example/</link>
		<comments>http://danfolkes.com/2011/08/09/asp-dropdownlist-states-listitem-example/#comments</comments>
		<pubDate>Tue, 09 Aug 2011 19:18:17 +0000</pubDate>
		<dc:creator>dan</dc:creator>
				<category><![CDATA[.Net]]></category>
		<category><![CDATA[AL]]></category>
		<category><![CDATA[Alabama]]></category>
		<category><![CDATA[Asp]]></category>
		<category><![CDATA[asp:DropDownList]]></category>
		<category><![CDATA[asp:ListItem]]></category>
		<category><![CDATA[Drop Down List]]></category>
		<category><![CDATA[DropDown]]></category>
		<category><![CDATA[DropDownList]]></category>
		<category><![CDATA[Example]]></category>
		<category><![CDATA[Item]]></category>
		<category><![CDATA[List]]></category>
		<category><![CDATA[List Item]]></category>
		<category><![CDATA[ListItem]]></category>
		<category><![CDATA[States]]></category>
		<category><![CDATA[United States]]></category>
		<category><![CDATA[US States]]></category>

		<guid isPermaLink="false">http://danfolkes.com/?p=1392</guid>
		<description><![CDATA[Compiled List of US State Drop Downs for Asp.Net Forms: Hope this helps! &#60;asp:DropDownList ID=&#34;ddlState&#34; runat=&#34;server&#34;&#62; &#60;asp:ListItem Value=&#34;&#34; Selected=&#34;True&#34;&#62;Select a State&#60;/asp:ListItem&#62; &#60;asp:ListItem value=&#34;AL&#34;&#62;Alabama&#60;/asp:ListItem&#62; &#60;asp:ListItem value=&#34;AK&#34;&#62;Alaska&#60;/asp:ListItem&#62; &#60;asp:ListItem value=&#34;AZ&#34;&#62;Arizona&#60;/asp:ListItem&#62; &#60;asp:ListItem value=&#34;AR&#34;&#62;Arkansas&#60;/asp:ListItem&#62; &#60;asp:ListItem value=&#34;CA&#34;&#62;California&#60;/asp:ListItem&#62; &#60;asp:ListItem value=&#34;CO&#34;&#62;Colorado&#60;/asp:ListItem&#62; &#60;asp:ListItem value=&#34;CT&#34;&#62;Connecticut&#60;/asp:ListItem&#62; &#60;asp:ListItem value=&#34;DC&#34;&#62;D.C.&#60;/asp:ListItem&#62; &#60;asp:ListItem value=&#34;DE&#34;&#62;Delaware&#60;/asp:ListItem&#62; &#60;asp:ListItem value=&#34;FL&#34;&#62;Florida&#60;/asp:ListItem&#62; &#60;asp:ListItem value=&#34;GA&#34;&#62;Georgia&#60;/asp:ListItem&#62; &#60;asp:ListItem value=&#34;HI&#34;&#62;Hawaii&#60;/asp:ListItem&#62; &#60;asp:ListItem value=&#34;ID&#34;&#62;Idaho&#60;/asp:ListItem&#62; &#60;asp:ListItem value=&#34;IL&#34;&#62;Illinois&#60;/asp:ListItem&#62; &#60;asp:ListItem value=&#34;IN&#34;&#62;Indiana&#60;/asp:ListItem&#62; &#60;asp:ListItem value=&#34;IA&#34;&#62;Iowa&#60;/asp:ListItem&#62; &#60;asp:ListItem value=&#34;KS&#34;&#62;Kansas&#60;/asp:ListItem&#62; [...]<div class='yarpp-related-rss yarpp-related-none'>

No related posts.
</div>
]]></description>
			<content:encoded><![CDATA[<p><img src="http://danfolkes.com/wp-content/uploads/2011/08/Asp-DropDownList-States-ListItem-Example.jpg" alt="Asp DropDownList - States - ListItem Example" title="Asp DropDownList - States - ListItem Example" width="355" height="377" class="alignnone size-full wp-image-1397" /><br />
<strong>Compiled List of US State Drop Downs for Asp.Net Forms:</strong></p>
<p>Hope this helps!</p>

<div class="wp_syntax"><table><tr><td class="code"><pre class="asp" style="font-family:monospace;"><span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>DropDownList ID<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;ddlState&quot;</span> runat<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;server&quot;</span><span style="color: #006600; font-weight: bold;">&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;&quot;</span> Selected<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;True&quot;</span><span style="color: #006600; font-weight: bold;">&gt;</span><span style="color: #990099; font-weight: bold;">Select</span> a State<span style="color: #006600; font-weight: bold;">&lt;/</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem<span style="color: #006600; font-weight: bold;">&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;AL&quot;</span><span style="color: #006600; font-weight: bold;">&gt;</span>Alabama<span style="color: #006600; font-weight: bold;">&lt;/</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem<span style="color: #006600; font-weight: bold;">&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;AK&quot;</span><span style="color: #006600; font-weight: bold;">&gt;</span>Alaska<span style="color: #006600; font-weight: bold;">&lt;/</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem<span style="color: #006600; font-weight: bold;">&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;AZ&quot;</span><span style="color: #006600; font-weight: bold;">&gt;</span>Arizona<span style="color: #006600; font-weight: bold;">&lt;/</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem<span style="color: #006600; font-weight: bold;">&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;AR&quot;</span><span style="color: #006600; font-weight: bold;">&gt;</span>Arkansas<span style="color: #006600; font-weight: bold;">&lt;/</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem<span style="color: #006600; font-weight: bold;">&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;CA&quot;</span><span style="color: #006600; font-weight: bold;">&gt;</span>California<span style="color: #006600; font-weight: bold;">&lt;/</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem<span style="color: #006600; font-weight: bold;">&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;CO&quot;</span><span style="color: #006600; font-weight: bold;">&gt;</span>Colorado<span style="color: #006600; font-weight: bold;">&lt;/</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem<span style="color: #006600; font-weight: bold;">&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;CT&quot;</span><span style="color: #006600; font-weight: bold;">&gt;</span>Connecticut<span style="color: #006600; font-weight: bold;">&lt;/</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem<span style="color: #006600; font-weight: bold;">&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;DC&quot;</span><span style="color: #006600; font-weight: bold;">&gt;</span>D.<span style="color: #9900cc;">C</span>.<span style="color: #006600; font-weight: bold;">&lt;/</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem<span style="color: #006600; font-weight: bold;">&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;DE&quot;</span><span style="color: #006600; font-weight: bold;">&gt;</span>Delaware<span style="color: #006600; font-weight: bold;">&lt;/</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem<span style="color: #006600; font-weight: bold;">&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;FL&quot;</span><span style="color: #006600; font-weight: bold;">&gt;</span>Florida<span style="color: #006600; font-weight: bold;">&lt;/</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem<span style="color: #006600; font-weight: bold;">&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;GA&quot;</span><span style="color: #006600; font-weight: bold;">&gt;</span>Georgia<span style="color: #006600; font-weight: bold;">&lt;/</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem<span style="color: #006600; font-weight: bold;">&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;HI&quot;</span><span style="color: #006600; font-weight: bold;">&gt;</span>Hawaii<span style="color: #006600; font-weight: bold;">&lt;/</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem<span style="color: #006600; font-weight: bold;">&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;ID&quot;</span><span style="color: #006600; font-weight: bold;">&gt;</span>Idaho<span style="color: #006600; font-weight: bold;">&lt;/</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem<span style="color: #006600; font-weight: bold;">&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;IL&quot;</span><span style="color: #006600; font-weight: bold;">&gt;</span>Illinois<span style="color: #006600; font-weight: bold;">&lt;/</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem<span style="color: #006600; font-weight: bold;">&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;IN&quot;</span><span style="color: #006600; font-weight: bold;">&gt;</span>Indiana<span style="color: #006600; font-weight: bold;">&lt;/</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem<span style="color: #006600; font-weight: bold;">&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;IA&quot;</span><span style="color: #006600; font-weight: bold;">&gt;</span>Iowa<span style="color: #006600; font-weight: bold;">&lt;/</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem<span style="color: #006600; font-weight: bold;">&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;KS&quot;</span><span style="color: #006600; font-weight: bold;">&gt;</span>Kansas<span style="color: #006600; font-weight: bold;">&lt;/</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem<span style="color: #006600; font-weight: bold;">&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;KY&quot;</span><span style="color: #006600; font-weight: bold;">&gt;</span>Kentucky<span style="color: #006600; font-weight: bold;">&lt;/</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem<span style="color: #006600; font-weight: bold;">&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;LA&quot;</span><span style="color: #006600; font-weight: bold;">&gt;</span>Louisiana<span style="color: #006600; font-weight: bold;">&lt;/</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem<span style="color: #006600; font-weight: bold;">&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;ME&quot;</span><span style="color: #006600; font-weight: bold;">&gt;</span>Maine<span style="color: #006600; font-weight: bold;">&lt;/</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem<span style="color: #006600; font-weight: bold;">&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;MD&quot;</span><span style="color: #006600; font-weight: bold;">&gt;</span>Maryland<span style="color: #006600; font-weight: bold;">&lt;/</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem<span style="color: #006600; font-weight: bold;">&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;MA&quot;</span><span style="color: #006600; font-weight: bold;">&gt;</span>Massachusetts<span style="color: #006600; font-weight: bold;">&lt;/</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem<span style="color: #006600; font-weight: bold;">&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;MI&quot;</span><span style="color: #006600; font-weight: bold;">&gt;</span>Michigan<span style="color: #006600; font-weight: bold;">&lt;/</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem<span style="color: #006600; font-weight: bold;">&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;MN&quot;</span><span style="color: #006600; font-weight: bold;">&gt;</span>Minnesota<span style="color: #006600; font-weight: bold;">&lt;/</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem<span style="color: #006600; font-weight: bold;">&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;MS&quot;</span><span style="color: #006600; font-weight: bold;">&gt;</span>Mississippi<span style="color: #006600; font-weight: bold;">&lt;/</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem<span style="color: #006600; font-weight: bold;">&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;MO&quot;</span><span style="color: #006600; font-weight: bold;">&gt;</span>Missouri<span style="color: #006600; font-weight: bold;">&lt;/</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem<span style="color: #006600; font-weight: bold;">&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;MT&quot;</span><span style="color: #006600; font-weight: bold;">&gt;</span>Montana<span style="color: #006600; font-weight: bold;">&lt;/</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem<span style="color: #006600; font-weight: bold;">&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;NE&quot;</span><span style="color: #006600; font-weight: bold;">&gt;</span>Nebraska<span style="color: #006600; font-weight: bold;">&lt;/</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem<span style="color: #006600; font-weight: bold;">&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;NV&quot;</span><span style="color: #006600; font-weight: bold;">&gt;</span>Nevada<span style="color: #006600; font-weight: bold;">&lt;/</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem<span style="color: #006600; font-weight: bold;">&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;NH&quot;</span><span style="color: #006600; font-weight: bold;">&gt;</span><span style="color: #0000ff; font-weight: bold;">New</span> Hampshire<span style="color: #006600; font-weight: bold;">&lt;/</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem<span style="color: #006600; font-weight: bold;">&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;NJ&quot;</span><span style="color: #006600; font-weight: bold;">&gt;</span><span style="color: #0000ff; font-weight: bold;">New</span> Jersey<span style="color: #006600; font-weight: bold;">&lt;/</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem<span style="color: #006600; font-weight: bold;">&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;NM&quot;</span><span style="color: #006600; font-weight: bold;">&gt;</span><span style="color: #0000ff; font-weight: bold;">New</span> Mexico<span style="color: #006600; font-weight: bold;">&lt;/</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem<span style="color: #006600; font-weight: bold;">&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;NY&quot;</span><span style="color: #006600; font-weight: bold;">&gt;</span><span style="color: #0000ff; font-weight: bold;">New</span> York<span style="color: #006600; font-weight: bold;">&lt;/</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem<span style="color: #006600; font-weight: bold;">&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;NC&quot;</span><span style="color: #006600; font-weight: bold;">&gt;</span>North Carolina<span style="color: #006600; font-weight: bold;">&lt;/</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem<span style="color: #006600; font-weight: bold;">&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;ND&quot;</span><span style="color: #006600; font-weight: bold;">&gt;</span>North Dakota<span style="color: #006600; font-weight: bold;">&lt;/</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem<span style="color: #006600; font-weight: bold;">&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;OH&quot;</span><span style="color: #006600; font-weight: bold;">&gt;</span>Ohio<span style="color: #006600; font-weight: bold;">&lt;/</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem<span style="color: #006600; font-weight: bold;">&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;OK&quot;</span><span style="color: #006600; font-weight: bold;">&gt;</span>Oklahoma<span style="color: #006600; font-weight: bold;">&lt;/</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem<span style="color: #006600; font-weight: bold;">&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;OR&quot;</span><span style="color: #006600; font-weight: bold;">&gt;</span>Oregon<span style="color: #006600; font-weight: bold;">&lt;/</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem<span style="color: #006600; font-weight: bold;">&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;PA&quot;</span><span style="color: #006600; font-weight: bold;">&gt;</span>Pennsylvania<span style="color: #006600; font-weight: bold;">&lt;/</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem<span style="color: #006600; font-weight: bold;">&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;RI&quot;</span><span style="color: #006600; font-weight: bold;">&gt;</span>Rhode Island<span style="color: #006600; font-weight: bold;">&lt;/</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem<span style="color: #006600; font-weight: bold;">&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;SC&quot;</span><span style="color: #006600; font-weight: bold;">&gt;</span>South Carolina<span style="color: #006600; font-weight: bold;">&lt;/</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem<span style="color: #006600; font-weight: bold;">&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;SD&quot;</span><span style="color: #006600; font-weight: bold;">&gt;</span>South Dakota<span style="color: #006600; font-weight: bold;">&lt;/</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem<span style="color: #006600; font-weight: bold;">&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;TN&quot;</span><span style="color: #006600; font-weight: bold;">&gt;</span>Tennessee<span style="color: #006600; font-weight: bold;">&lt;/</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem<span style="color: #006600; font-weight: bold;">&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;TX&quot;</span><span style="color: #006600; font-weight: bold;">&gt;</span>Texas<span style="color: #006600; font-weight: bold;">&lt;/</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem<span style="color: #006600; font-weight: bold;">&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;UT&quot;</span><span style="color: #006600; font-weight: bold;">&gt;</span>Utah<span style="color: #006600; font-weight: bold;">&lt;/</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem<span style="color: #006600; font-weight: bold;">&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;VT&quot;</span><span style="color: #006600; font-weight: bold;">&gt;</span>Vermont<span style="color: #006600; font-weight: bold;">&lt;/</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem<span style="color: #006600; font-weight: bold;">&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;VA&quot;</span><span style="color: #006600; font-weight: bold;">&gt;</span>Virginia<span style="color: #006600; font-weight: bold;">&lt;/</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem<span style="color: #006600; font-weight: bold;">&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;WA&quot;</span><span style="color: #006600; font-weight: bold;">&gt;</span>Washington<span style="color: #006600; font-weight: bold;">&lt;/</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem<span style="color: #006600; font-weight: bold;">&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;WV&quot;</span><span style="color: #006600; font-weight: bold;">&gt;</span>West Virginia<span style="color: #006600; font-weight: bold;">&lt;/</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem<span style="color: #006600; font-weight: bold;">&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;WI&quot;</span><span style="color: #006600; font-weight: bold;">&gt;</span>Wisconsin<span style="color: #006600; font-weight: bold;">&lt;/</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem<span style="color: #006600; font-weight: bold;">&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;WY&quot;</span><span style="color: #006600; font-weight: bold;">&gt;</span>Wyoming<span style="color: #006600; font-weight: bold;">&lt;/</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem<span style="color: #006600; font-weight: bold;">&gt;</span>
<span style="color: #006600; font-weight: bold;">&lt;/</span>asp<span style="color: #006600; font-weight: bold;">:</span>DropDownList<span style="color: #006600; font-weight: bold;">&gt;</span></pre></td></tr></table></div>

<p>More State Drop Downs After the fold:<br />
<span id="more-1392"></span><br />
<strong>Using the Text Property:</strong></p>

<div class="wp_syntax"><table><tr><td class="code"><pre class="asp" style="font-family:monospace;"><span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>DropDownList ID<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;ddlState&quot;</span> runat<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;server&quot;</span><span style="color: #006600; font-weight: bold;">&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;&quot;</span> Selected<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;True&quot;</span><span style="color: #006600; font-weight: bold;">&gt;</span><span style="color: #990099; font-weight: bold;">Select</span> a State<span style="color: #006600; font-weight: bold;">&lt;/</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem<span style="color: #006600; font-weight: bold;">&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;AL&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Alabama&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;AK&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Alaska&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;AZ&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Arizona&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;AR&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Arkansas&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;CA&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;California&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;CO&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Colorado&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;CT&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Connecticut&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;DC&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;D.C.&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;DE&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Delaware&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;FL&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Florida&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;GA&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Georgia&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;HI&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Hawaii&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;ID&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Idaho&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;IL&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Illinois&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;IN&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Indiana&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;IA&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Iowa&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;KS&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Kansas&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;KY&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Kentucky&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;LA&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Louisiana&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;ME&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Maine&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;MD&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Maryland&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;MA&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Massachusetts&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;MI&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Michigan&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;MN&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Minnesota&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;MS&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Mississippi&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;MO&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Missouri&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;MT&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Montana&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;NE&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Nebraska&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;NV&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Nevada&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;NH&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;New Hampshire&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;NJ&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;New Jersey&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;NM&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;New Mexico&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;NY&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;New York&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;NC&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;North Carolina&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;ND&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;North Dakota&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;OH&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Ohio&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;OK&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Oklahoma&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;OR&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Oregon&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;PA&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Pennsylvania&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;RI&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Rhode Island&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;SC&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;South Carolina&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;SD&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;South Dakota&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;TN&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Tennessee&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;TX&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Texas&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;UT&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Utah&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;VT&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Vermont&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;VA&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Virginia&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;WA&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Washington&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;WV&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;West Virginia&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;WI&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Wisconsin&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;WY&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Wyoming&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
<span style="color: #006600; font-weight: bold;">&lt;/</span>asp<span style="color: #006600; font-weight: bold;">:</span>DropDownList<span style="color: #006600; font-weight: bold;">&gt;</span></pre></td></tr></table></div>

<p><strong>Using the Text Property Reversed:</strong></p>

<div class="wp_syntax"><table><tr><td class="code"><pre class="asp" style="font-family:monospace;"><span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>DropDownList ID<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;ddlState&quot;</span> runat<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;server&quot;</span><span style="color: #006600; font-weight: bold;">&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;&quot;</span> Selected<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;True&quot;</span><span style="color: #006600; font-weight: bold;">&gt;</span><span style="color: #990099; font-weight: bold;">Select</span> a State<span style="color: #006600; font-weight: bold;">&lt;/</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem<span style="color: #006600; font-weight: bold;">&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Alabama&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;AL&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Alaska&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;AK&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Arizona&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;AZ&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Arkansas&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;AR&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;California&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;CA&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Colorado&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;CO&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Connecticut&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;CT&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;D.C.&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;DC&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Delaware&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;DE&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Florida&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;FL&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Georgia&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;GA&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Hawaii&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;HI&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Idaho&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;ID&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Illinois&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;IL&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Indiana&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;IN&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Iowa&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;IA&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Kansas&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;KS&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Kentucky&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;KY&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Louisiana&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;LA&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Maine&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;ME&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Maryland&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;MD&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Massachusetts&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;MA&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Michigan&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;MI&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Minnesota&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;MN&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Mississippi&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;MS&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Missouri&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;MO&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Montana&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;MT&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Nebraska&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;NE&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Nevada&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;NV&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;New Hampshire&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;NH&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;New Jersey&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;NJ&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;New Mexico&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;NM&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;New York&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;NY&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;North Carolina&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;NC&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;North Dakota&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;ND&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Ohio&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;OH&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Oklahoma&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;OK&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Oregon&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;OR&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Pennsylvania&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;PA&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Rhode Island&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;RI&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;South Carolina&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;SC&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;South Dakota&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;SD&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Tennessee&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;TN&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Texas&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;TX&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Utah&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;UT&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Vermont&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;VT&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Virginia&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;VA&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Washington&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;WA&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;West Virginia&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;WV&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Wisconsin&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;WI&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Wyoming&quot;</span> Text<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;WY&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
<span style="color: #006600; font-weight: bold;">&lt;/</span>asp<span style="color: #006600; font-weight: bold;">:</span>DropDownList<span style="color: #006600; font-weight: bold;">&gt;</span></pre></td></tr></table></div>

<p><strong>States with just Long Names:</strong></p>

<div class="wp_syntax"><table><tr><td class="code"><pre class="asp" style="font-family:monospace;"><span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>DropDownList ID<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;ddlState&quot;</span> runat<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;server&quot;</span><span style="color: #006600; font-weight: bold;">&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Alabama&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Alaska&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Arizona&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Arkansas&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;California&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Colorado&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Connecticut&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;D.C.&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Delaware&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Florida&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Georgia&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Hawaii&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Idaho&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Illinois&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Indiana&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Iowa&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Kansas&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Kentucky&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Louisiana&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Maine&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Maryland&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Massachusetts&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Michigan&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Minnesota&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Mississippi&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Missouri&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Montana&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Nebraska&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Nevada&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;New Hampshire&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;New Jersey&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;New Mexico&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;New York&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;North Carolina&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;North Dakota&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Ohio&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Oklahoma&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Oregon&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Pennsylvania&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Rhode Island&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;South Carolina&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;South Dakota&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Tennessee&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Texas&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Utah&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Vermont&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Virginia&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Washington&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;West Virginia&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Wisconsin&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;Wyoming&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
<span style="color: #006600; font-weight: bold;">&lt;/</span>asp<span style="color: #006600; font-weight: bold;">:</span>DropDownList<span style="color: #006600; font-weight: bold;">&gt;</span></pre></td></tr></table></div>

<p><strong>States with just Short Names:</strong></p>

<div class="wp_syntax"><table><tr><td class="code"><pre class="asp" style="font-family:monospace;"><span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>DropDownList ID<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;ddlState&quot;</span> runat<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;server&quot;</span><span style="color: #006600; font-weight: bold;">&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;AL&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;AK&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;AZ&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;AR&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;CA&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;CO&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;CT&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;DC&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;DE&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;FL&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;GA&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;HI&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;ID&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;IL&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;IN&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;IA&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;KS&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;KY&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;LA&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;ME&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;MD&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;MA&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;MI&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;MN&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;MS&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;MO&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;MT&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;NE&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;NV&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;NH&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;NJ&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;NM&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;NY&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;NC&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;ND&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;OH&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;OK&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;OR&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;PA&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;RI&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;SC&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;SD&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;TN&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;TX&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;UT&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;VT&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;VA&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;WA&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;WV&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;WI&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
    <span style="color: #006600; font-weight: bold;">&lt;</span>asp<span style="color: #006600; font-weight: bold;">:</span>ListItem Value<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;WY&quot;</span><span style="color: #006600; font-weight: bold;">/&gt;</span>
<span style="color: #006600; font-weight: bold;">&lt;/</span>asp<span style="color: #006600; font-weight: bold;">:</span>DropDownList<span style="color: #006600; font-weight: bold;">&gt;</span></pre></td></tr></table></div>

<div class='yarpp-related-rss yarpp-related-none'>
<p>No related posts.</p>
</div>
]]></content:encoded>
			<wfw:commentRss>http://danfolkes.com/2011/08/09/asp-dropdownlist-states-listitem-example/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Asp.Net VB &#8211; Listview &#8211; ItemCommand &#8211; DataKeys &#8211; CommandName &#8211; SQL</title>
		<link>http://danfolkes.com/2011/08/01/asp-net-vb-listview-itemcommand-datakeys-commandname-sql/</link>
		<comments>http://danfolkes.com/2011/08/01/asp-net-vb-listview-itemcommand-datakeys-commandname-sql/#comments</comments>
		<pubDate>Mon, 01 Aug 2011 16:56:59 +0000</pubDate>
		<dc:creator>dan</dc:creator>
				<category><![CDATA[.Net]]></category>
		<category><![CDATA[Asp]]></category>
		<category><![CDATA[Asp.Net]]></category>
		<category><![CDATA[CommandName]]></category>
		<category><![CDATA[ConnectionString]]></category>
		<category><![CDATA[DataBind]]></category>
		<category><![CDATA[dataItem.DataItemIndex]]></category>
		<category><![CDATA[DataKeys]]></category>
		<category><![CDATA[e.CommandName]]></category>
		<category><![CDATA[e.Item]]></category>
		<category><![CDATA[e.Item.FindControl]]></category>
		<category><![CDATA[e.Item.ItemType]]></category>
		<category><![CDATA[FindControl]]></category>
		<category><![CDATA[ItemCommand]]></category>
		<category><![CDATA[ItemDataBound]]></category>
		<category><![CDATA[Listview]]></category>
		<category><![CDATA[ListViewItemEventArgs]]></category>
		<category><![CDATA[Parameters]]></category>
		<category><![CDATA[Parameters.Add]]></category>
		<category><![CDATA[SelectCommand]]></category>
		<category><![CDATA[SelectParameters]]></category>
		<category><![CDATA[SQL]]></category>
		<category><![CDATA[SqlDataSource]]></category>
		<category><![CDATA[VB]]></category>
		<category><![CDATA[WebControls]]></category>

		<guid isPermaLink="false">http://danfolkes.com/?p=1384</guid>
		<description><![CDATA[Here is a basic Listview that has an ItemCommand and ItemDataBound: Frontend Code: &#60;asp:ListView ID=&#34;lvAddresses&#34; runat=&#34;server&#34; DataKeyNames=&#34;AddressID,BillingAddressID,ShippingAddressID&#34;&#62; &#60;LayoutTemplate&#62; &#60;asp:PlaceHolder ID=&#34;itemPlaceholder&#34; runat=&#34;server&#34;&#62;&#60;/asp:PlaceHolder&#62; &#60;/LayoutTemplate&#62; &#60;ItemTemplate&#62; &#60;table class=&#34;noborder address_book&#34; cellpadding=&#34;0&#34; cellspacing=&#34;0&#34;&#62;&#60;tbody&#62; &#60;tr&#62; &#60;td colspan=&#34;2&#34;&#62; &#60;%#DataBinder.Eval(Container.DataItem, &#34;FirstName&#34;)%&#62; &#60;%#DataBinder.Eval(Container.DataItem, &#34;LastName&#34;)%&#62;&#60;br&#62; &#60;%#DataBinder.Eval(Container.DataItem, &#34;Address1&#34;)%&#62;&#60;br&#62; &#60;%#DataBinder.Eval(Container.DataItem, &#34;City&#34;)%&#62;, &#60;%#DataBinder.Eval(Container.DataItem, &#34;State&#34;)%&#62;, &#60;%#DataBinder.Eval(Container.DataItem, &#34;Zip&#34;)%&#62;&#60;br&#62; &#60;%#DataBinder.Eval(Container.DataItem, &#34;Phone&#34;)%&#62;&#60;br&#62; &#60;span class=&#34;caption&#34;&#62;&#60;asp:LinkButton ID=&#34;lnkMakeDefault_Billing&#34; CommandName=&#34;MakeDefault_Billing&#34; runat=&#34;server&#34;&#62;Click to make Default Billing Address&#60;/asp:LinkButton&#62;&#60;/span&#62; [...]<div class='yarpp-related-rss'>

Related posts:<ol>
<li><a href='http://danfolkes.com/2011/09/21/asp-net-adding-parameters-to-commandtype-text/' rel='bookmark' title='Asp.Net &#8211; Adding Parameters to CommandType.Text'>Asp.Net &#8211; Adding Parameters to CommandType.Text</a></li>
</ol>
</div>
]]></description>
			<content:encoded><![CDATA[<p><img src="http://danfolkes.com/wp-content/uploads/2011/08/Asp.Net-VB-Listview-ItemCommand-DataKeys-CommandName-SQL.jpg" alt="Asp.Net VB - Listview - ItemCommand - DataKeys - CommandName - SQL" title="Asp.Net VB - Listview - ItemCommand - DataKeys - CommandName - SQL" width="221" height="190" class="alignnone size-full wp-image-1388" /></p>
<p><strong>Here is a basic Listview that has an ItemCommand and ItemDataBound:</strong></p>
<p>Frontend Code:</p>

<div class="wp_syntax"><table><tr><td class="code"><pre class="vb" style="font-family:monospace;">&lt;asp:ListView ID=<span style="color: #800000;">&quot;lvAddresses&quot;</span> runat=<span style="color: #800000;">&quot;server&quot;</span> DataKeyNames=<span style="color: #800000;">&quot;AddressID,BillingAddressID,ShippingAddressID&quot;</span>&gt;
        &lt;LayoutTemplate&gt;
            &lt;asp:PlaceHolder ID=<span style="color: #800000;">&quot;itemPlaceholder&quot;</span> runat=<span style="color: #800000;">&quot;server&quot;</span>&gt;&lt;/asp:PlaceHolder&gt;
        &lt;/LayoutTemplate&gt;
        &lt;ItemTemplate&gt;
            &lt;table class=<span style="color: #800000;">&quot;noborder address_book&quot;</span> cellpadding=<span style="color: #800000;">&quot;0&quot;</span> cellspacing=<span style="color: #800000;">&quot;0&quot;</span>&gt;&lt;tbody&gt;
                &lt;tr&gt;
                    &lt;td colspan=<span style="color: #800000;">&quot;2&quot;</span>&gt;
                        &lt;%#DataBinder.Eval(Container.DataItem, <span style="color: #800000;">&quot;FirstName&quot;</span>)%&gt; &lt;%#DataBinder.Eval(Container.DataItem, <span style="color: #800000;">&quot;LastName&quot;</span>)%&gt;&lt;br&gt;
                        &lt;%#DataBinder.Eval(Container.DataItem, <span style="color: #800000;">&quot;Address1&quot;</span>)%&gt;&lt;br&gt;
                        &lt;%#DataBinder.Eval(Container.DataItem, <span style="color: #800000;">&quot;City&quot;</span>)%&gt;, &lt;%#DataBinder.Eval(Container.DataItem, <span style="color: #800000;">&quot;State&quot;</span>)%&gt;, &lt;%#DataBinder.Eval(Container.DataItem, <span style="color: #800000;">&quot;Zip&quot;</span>)%&gt;&lt;br&gt;
                        &lt;%#DataBinder.Eval(Container.DataItem, <span style="color: #800000;">&quot;Phone&quot;</span>)%&gt;&lt;br&gt;
                        &lt;span class=<span style="color: #800000;">&quot;caption&quot;</span>&gt;&lt;asp:LinkButton ID=<span style="color: #800000;">&quot;lnkMakeDefault_Billing&quot;</span> CommandName=<span style="color: #800000;">&quot;MakeDefault_Billing&quot;</span> runat=<span style="color: #800000;">&quot;server&quot;</span>&gt;Click <span style="color: #8D38C9; font-weight: bold;">to</span> make Default Billing Address&lt;/asp:LinkButton&gt;&lt;/span&gt;
                        &lt;span class=<span style="color: #800000;">&quot;caption&quot;</span>&gt;&lt;asp:Literal ID=<span style="color: #800000;">&quot;litMakeDefault_Billing&quot;</span> runat=<span style="color: #800000;">&quot;server&quot;</span> Text=<span style="color: #800000;">&quot;Default Billing Address&quot;</span>&gt;&lt;/asp:Literal&gt;&lt;/span&gt;
                        &lt;br /&gt;
                        &lt;span class=<span style="color: #800000;">&quot;caption&quot;</span>&gt;&lt;asp:LinkButton ID=<span style="color: #800000;">&quot;lnkMakeDefault_Shipping&quot;</span> CommandName=<span style="color: #800000;">&quot;MakeDefault_Shipping&quot;</span> runat=<span style="color: #800000;">&quot;server&quot;</span>&gt;Click <span style="color: #8D38C9; font-weight: bold;">to</span> make Default Shipping Address&lt;/asp:LinkButton&gt;&lt;/span&gt;
                        &lt;span class=<span style="color: #800000;">&quot;caption&quot;</span>&gt;&lt;asp:Literal ID=<span style="color: #800000;">&quot;litMakeDefault_Shipping&quot;</span> runat=<span style="color: #800000;">&quot;server&quot;</span> Text=<span style="color: #800000;">&quot;Default Shipping Address&quot;</span>&gt;&lt;/asp:Literal&gt;&lt;/span&gt;
                    &lt;/td&gt;
                &lt;/tr&gt;
                &lt;tr&gt;
                    &lt;td&gt;
                        &lt;asp:Button ID=<span style="color: #800000;">&quot;Button1&quot;</span> runat=<span style="color: #800000;">&quot;server&quot;</span> Text=<span style="color: #800000;">&quot;EDIT&quot;</span> CommandName=<span style="color: #800000;">&quot;EDITAddress&quot;</span>/&gt;
                    &lt;/td&gt;
                    &lt;td&gt;
                        &lt;asp:Button ID=<span style="color: #800000;">&quot;btnREMOVE&quot;</span> runat=<span style="color: #800000;">&quot;server&quot;</span> Text=<span style="color: #800000;">&quot;REMOVE&quot;</span> CommandName=<span style="color: #800000;">&quot;REMOVEAddress&quot;</span>/&gt;
                    &lt;/td&gt;
                &lt;/tr&gt;
            &lt;/tbody&gt;&lt;/table&gt;
&nbsp;
        &lt;/ItemTemplate&gt;
    &lt;/asp:ListView&gt;</pre></td></tr></table></div>

<p>Backend Code:</p>

<div class="wp_syntax"><table><tr><td class="code"><pre class="vb" style="font-family:monospace;">Protected <span style="color: #E56717; font-weight: bold;">Sub</span> Page_PreRender(<span style="color: #151B8D; font-weight: bold;">ByVal</span> sender <span style="color: #151B8D; font-weight: bold;">As</span> <span style="color: #F660AB; font-weight: bold;">Object</span>, <span style="color: #151B8D; font-weight: bold;">ByVal</span> e <span style="color: #151B8D; font-weight: bold;">As</span> System.EventArgs) Handles Me.PreRender
&nbsp;
        FindIt()
&nbsp;
    <span style="color: #8D38C9; font-weight: bold;">End</span> <span style="color: #E56717; font-weight: bold;">Sub</span>
    <span style="color: #E56717; font-weight: bold;">Private</span> <span style="color: #E56717; font-weight: bold;">Sub</span> FindIt()
&nbsp;
        lblAddresses.Text = <span style="color: #800000;">&quot;&quot;</span>
&nbsp;
        <span style="color: #151B8D; font-weight: bold;">Dim</span> sqlDataConnection <span style="color: #151B8D; font-weight: bold;">As</span> System.Data.SqlClient.SqlConnection = CDataAccess.OpenDatabase
        <span style="color: #151B8D; font-weight: bold;">Dim</span> conStr <span style="color: #151B8D; font-weight: bold;">As</span> <span style="color: #F660AB; font-weight: bold;">String</span> = sqlDataConnection.ConnectionString
        sqlDataConnection.<span style="color: #8D38C9; font-weight: bold;">Close</span>()
&nbsp;
        <span style="color: #151B8D; font-weight: bold;">Dim</span> selectCommand <span style="color: #151B8D; font-weight: bold;">As</span> <span style="color: #F660AB; font-weight: bold;">String</span> = <span style="color: #800000;">&quot;SELECT Address.*, Customer.BillingAddressID, Customer.ShippingAddressID&quot;</span>
        selectCommand &amp;= <span style="color: #800000;">&quot; FROM Address INNER JOIN Customer ON Address.CustomerID = Customer.CustomerID&quot;</span>
        selectCommand &amp;= <span style="color: #800000;">&quot; WHERE Address.CustomerID = @CustomerID AND Address.Deleted = 0&quot;</span>
&nbsp;
        <span style="color: #151B8D; font-weight: bold;">Dim</span> sds <span style="color: #151B8D; font-weight: bold;">As</span> <span style="color: #E56717; font-weight: bold;">New</span> SqlDataSource()
        sds.ConnectionString = conStr
        sds.SelectParameters.Clear()
&nbsp;
        sds.SelectParameters.Add(<span style="color: #800000;">&quot;CustomerID&quot;</span>, 12345)
        sds.SelectCommand = selectCommand
&nbsp;
        lvAddresses.DataSource = sds
        lvAddresses.DataBind()
    <span style="color: #8D38C9; font-weight: bold;">End</span> <span style="color: #E56717; font-weight: bold;">Sub</span>
&nbsp;
    Protected <span style="color: #E56717; font-weight: bold;">Sub</span> lvAddresses_ItemCommand(<span style="color: #151B8D; font-weight: bold;">ByVal</span> sender <span style="color: #151B8D; font-weight: bold;">As</span> <span style="color: #F660AB; font-weight: bold;">Object</span>, <span style="color: #151B8D; font-weight: bold;">ByVal</span> e <span style="color: #151B8D; font-weight: bold;">As</span> System.Web.UI.WebControls.ListViewCommandEventArgs) Handles lvAddresses.ItemCommand
        <span style="color: #151B8D; font-weight: bold;">Dim</span> dataItem <span style="color: #151B8D; font-weight: bold;">As</span> ListViewDataItem = e.Item
        <span style="color: #151B8D; font-weight: bold;">Dim</span> currentDataKey <span style="color: #151B8D; font-weight: bold;">As</span> DataKey = lvAddresses.DataKeys(dataItem.DataItemIndex)
        <span style="color: #151B8D; font-weight: bold;">Dim</span> AddressID <span style="color: #151B8D; font-weight: bold;">As</span> <span style="color: #F660AB; font-weight: bold;">Integer</span> = currentDataKey(<span style="color: #800000;">&quot;AddressID&quot;</span>)
        <span style="color: #151B8D; font-weight: bold;">Dim</span> BillingAddressID <span style="color: #151B8D; font-weight: bold;">As</span> <span style="color: #F660AB; font-weight: bold;">Integer</span> = currentDataKey(<span style="color: #800000;">&quot;BillingAddressID&quot;</span>)
        <span style="color: #151B8D; font-weight: bold;">Dim</span> ShippingAddressID <span style="color: #151B8D; font-weight: bold;">As</span> <span style="color: #F660AB; font-weight: bold;">Integer</span> = currentDataKey(<span style="color: #800000;">&quot;ShippingAddressID&quot;</span>)
&nbsp;
        <span style="color: #008000;">'MakeDefault_Billing
</span>        <span style="color: #008000;">'MakeDefault_Shipping
</span>        <span style="color: #008000;">'EDITAddress
</span>        <span style="color: #008000;">'REMOVEAddress
</span>        <span style="color: #8D38C9; font-weight: bold;">If</span> <span style="color: #F660AB; font-weight: bold;">String</span>.Equals(e.CommandName, <span style="color: #800000;">&quot;MakeDefault_Billing&quot;</span>) <span style="color: #8D38C9; font-weight: bold;">Then</span>
            MakeDefault(AddressID, <span style="color: #00C2FF; font-weight: bold;">True</span>)
        <span style="color: #8D38C9; font-weight: bold;">ElseIf</span> <span style="color: #F660AB; font-weight: bold;">String</span>.Equals(e.CommandName, <span style="color: #800000;">&quot;MakeDefault_Shipping&quot;</span>) <span style="color: #8D38C9; font-weight: bold;">Then</span>
            MakeDefault(AddressID, <span style="color: #00C2FF; font-weight: bold;">False</span>)
        <span style="color: #8D38C9; font-weight: bold;">ElseIf</span> <span style="color: #F660AB; font-weight: bold;">String</span>.Equals(e.CommandName, <span style="color: #800000;">&quot;EDITAddress&quot;</span>) <span style="color: #8D38C9; font-weight: bold;">Then</span>
            EditAddress(AddressID)
        <span style="color: #8D38C9; font-weight: bold;">ElseIf</span> <span style="color: #F660AB; font-weight: bold;">String</span>.Equals(e.CommandName, <span style="color: #800000;">&quot;REMOVEAddress&quot;</span>) <span style="color: #8D38C9; font-weight: bold;">Then</span>
            RemoveAddress(AddressID)
        <span style="color: #8D38C9; font-weight: bold;">End</span> <span style="color: #8D38C9; font-weight: bold;">If</span>
    <span style="color: #8D38C9; font-weight: bold;">End</span> <span style="color: #E56717; font-weight: bold;">Sub</span>
&nbsp;
    Protected <span style="color: #E56717; font-weight: bold;">Sub</span> lvAddresses_ItemDataBound(<span style="color: #151B8D; font-weight: bold;">ByVal</span> sender <span style="color: #151B8D; font-weight: bold;">As</span> <span style="color: #F660AB; font-weight: bold;">Object</span>, <span style="color: #151B8D; font-weight: bold;">ByVal</span> e <span style="color: #151B8D; font-weight: bold;">As</span> System.Web.UI.WebControls.ListViewItemEventArgs) Handles lvAddresses.ItemDataBound
        <span style="color: #151B8D; font-weight: bold;">Dim</span> dataItem <span style="color: #151B8D; font-weight: bold;">As</span> ListViewDataItem = e.Item
&nbsp;
        <span style="color: #8D38C9; font-weight: bold;">If</span> e.Item.ItemType = ListViewItemType.DataItem <span style="color: #8D38C9; font-weight: bold;">Then</span>
            <span style="color: #151B8D; font-weight: bold;">Dim</span> currentDataKey <span style="color: #151B8D; font-weight: bold;">As</span> DataKey = lvAddresses.DataKeys(dataItem.DataItemIndex)
            <span style="color: #151B8D; font-weight: bold;">Dim</span> AddressID <span style="color: #151B8D; font-weight: bold;">As</span> <span style="color: #F660AB; font-weight: bold;">Integer</span> = currentDataKey(<span style="color: #800000;">&quot;AddressID&quot;</span>)
            <span style="color: #151B8D; font-weight: bold;">Dim</span> BillingAddressID <span style="color: #151B8D; font-weight: bold;">As</span> <span style="color: #F660AB; font-weight: bold;">Integer</span> = currentDataKey(<span style="color: #800000;">&quot;BillingAddressID&quot;</span>)
            <span style="color: #151B8D; font-weight: bold;">Dim</span> ShippingAddressID <span style="color: #151B8D; font-weight: bold;">As</span> <span style="color: #F660AB; font-weight: bold;">Integer</span> = currentDataKey(<span style="color: #800000;">&quot;ShippingAddressID&quot;</span>)
            lit = e.Item.FindControl(<span style="color: #800000;">&quot;litMakeDefault_Billing&quot;</span>)
            <span style="color: #151B8D; font-weight: bold;">Dim</span> lit2 <span style="color: #151B8D; font-weight: bold;">As</span> Literal = e.Item.FindControl(<span style="color: #800000;">&quot;litMakeDefault_Shipping&quot;</span>)
            lnk = e.Item.FindControl(<span style="color: #800000;">&quot;lnkMakeDefault_Billing&quot;</span>)
            <span style="color: #151B8D; font-weight: bold;">Dim</span> lnk2 <span style="color: #151B8D; font-weight: bold;">As</span> LinkButton = e.Item.FindControl(<span style="color: #800000;">&quot;lnkMakeDefault_Shipping&quot;</span>)
&nbsp;
            lit.Visible = <span style="color: #8D38C9; font-weight: bold;">Not</span> lnk.Visible
        <span style="color: #8D38C9; font-weight: bold;">End</span> <span style="color: #8D38C9; font-weight: bold;">If</span>
&nbsp;
    <span style="color: #8D38C9; font-weight: bold;">End</span> <span style="color: #E56717; font-weight: bold;">Sub</span></pre></td></tr></table></div>

<div class='yarpp-related-rss'>
<p>Related posts:<ol>
<li><a href='http://danfolkes.com/2011/09/21/asp-net-adding-parameters-to-commandtype-text/' rel='bookmark' title='Asp.Net &#8211; Adding Parameters to CommandType.Text'>Asp.Net &#8211; Adding Parameters to CommandType.Text</a></li>
</ol></p>
</div>
]]></content:encoded>
			<wfw:commentRss>http://danfolkes.com/2011/08/01/asp-net-vb-listview-itemcommand-datakeys-commandname-sql/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Micaela&#8217;s Family</title>
		<link>http://danfolkes.com/2011/07/19/llll/</link>
		<comments>http://danfolkes.com/2011/07/19/llll/#comments</comments>
		<pubDate>Tue, 19 Jul 2011 21:28:22 +0000</pubDate>
		<dc:creator>dan</dc:creator>
				<category><![CDATA[Thoughts]]></category>

		<guid isPermaLink="false">http://danfolkes.com/?p=1377</guid>
		<description><![CDATA[<div class='yarpp-related-rss yarpp-related-none'>

No related posts.
</div>
]]></description>
			<content:encoded><![CDATA[<div class='yarpp-related-rss yarpp-related-none'>

No related posts.
</div>
]]></content:encoded>
			<wfw:commentRss>http://danfolkes.com/2011/07/19/llll/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>ASPDotNetStoreFront: Adding Topic to XML Packages or .aspx Pages</title>
		<link>http://danfolkes.com/2011/07/18/aspdotnetstorefront-adding-topic-to-xml-packages-or-aspx-pages/</link>
		<comments>http://danfolkes.com/2011/07/18/aspdotnetstorefront-adding-topic-to-xml-packages-or-aspx-pages/#comments</comments>
		<pubDate>Mon, 18 Jul 2011 19:07:22 +0000</pubDate>
		<dc:creator>dan</dc:creator>
				<category><![CDATA[.Net]]></category>
		<category><![CDATA[Code]]></category>
		<category><![CDATA[add]]></category>
		<category><![CDATA[ASP Dot Net Store Front]]></category>
		<category><![CDATA[aspdnsf]]></category>
		<category><![CDATA[aspdnsf:Topic]]></category>
		<category><![CDATA[AspDotNetStorefront]]></category>
		<category><![CDATA[c#]]></category>
		<category><![CDATA[DotNetStoreFront]]></category>
		<category><![CDATA[Store Front]]></category>
		<category><![CDATA[StoreFront]]></category>
		<category><![CDATA[Topic]]></category>
		<category><![CDATA[Topics]]></category>
		<category><![CDATA[VB]]></category>
		<category><![CDATA[Xml Package]]></category>
		<category><![CDATA[XMLPackage]]></category>
		<category><![CDATA[XMLPackages]]></category>

		<guid isPermaLink="false">http://danfolkes.com/?p=1369</guid>
		<description><![CDATA[This is how you add a DotNetStoreFront&#8217;s Topic into a XMLPackage: &#60;xsl:value-of select=&#34;aspdnsf:Topic('TOPIC_NAME')&#34; disable-output-escaping=&#34;yes&#34;/&#62; Now, if you want to add it to a .aspx or .ascx page on dnsf: &#60;aspdnsf:Topic runat=&#34;server&#34; ID=&#34;Topic1&#34; TopicName=&#34;TOPIC_NAME&#34; /&#62;<div class='yarpp-related-rss'>

Related posts:<ol>
<li><a href='http://danfolkes.com/2009/02/23/aspdotnetstorefront-changing-max-file-upload-size/' rel='bookmark' title='AspDotNetStorefront &#8211; Changing Max File Upload Size'>AspDotNetStorefront &#8211; Changing Max File Upload Size</a></li>
<li><a href='http://danfolkes.com/2010/06/15/quick-n-easy-forms-authentication-web-conf/' rel='bookmark' title='Quick n Easy &#8211; Forms Authentication &#8211; Web.conf'>Quick n Easy &#8211; Forms Authentication &#8211; Web.conf</a></li>
<li><a href='http://danfolkes.com/2008/09/30/python-wunderground-todays-weather-to-email-sms-to-phone/' rel='bookmark' title='Python: Wunderground Todays Weather to Email SMS to Phone'>Python: Wunderground Todays Weather to Email SMS to Phone</a></li>
</ol>
</div>
]]></description>
			<content:encoded><![CDATA[<p><strong>This is how you add a DotNetStoreFront&#8217;s Topic into a XMLPackage:</strong></p>

<div class="wp_syntax"><table><tr><td class="code"><pre class="vb" style="font-family:monospace;">&lt;xsl:value-of <span style="color: #8D38C9; font-weight: bold;">select</span>=<span style="color: #800000;">&quot;aspdnsf:Topic('TOPIC_NAME')&quot;</span> disable-output-escaping=<span style="color: #800000;">&quot;yes&quot;</span>/&gt;</pre></td></tr></table></div>

<p><strong>Now, if you want to add it to a .aspx or .ascx page on dnsf:</strong></p>

<div class="wp_syntax"><table><tr><td class="code"><pre class="vb" style="font-family:monospace;">&lt;aspdnsf:Topic runat=<span style="color: #800000;">&quot;server&quot;</span> ID=<span style="color: #800000;">&quot;Topic1&quot;</span> TopicName=<span style="color: #800000;">&quot;TOPIC_NAME&quot;</span> /&gt;</pre></td></tr></table></div>

<div class='yarpp-related-rss'>
<p>Related posts:<ol>
<li><a href='http://danfolkes.com/2009/02/23/aspdotnetstorefront-changing-max-file-upload-size/' rel='bookmark' title='AspDotNetStorefront &#8211; Changing Max File Upload Size'>AspDotNetStorefront &#8211; Changing Max File Upload Size</a></li>
<li><a href='http://danfolkes.com/2010/06/15/quick-n-easy-forms-authentication-web-conf/' rel='bookmark' title='Quick n Easy &#8211; Forms Authentication &#8211; Web.conf'>Quick n Easy &#8211; Forms Authentication &#8211; Web.conf</a></li>
<li><a href='http://danfolkes.com/2008/09/30/python-wunderground-todays-weather-to-email-sms-to-phone/' rel='bookmark' title='Python: Wunderground Todays Weather to Email SMS to Phone'>Python: Wunderground Todays Weather to Email SMS to Phone</a></li>
</ol></p>
</div>
]]></content:encoded>
			<wfw:commentRss>http://danfolkes.com/2011/07/18/aspdotnetstorefront-adding-topic-to-xml-packages-or-aspx-pages/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Me and Micaela at the Beach</title>
		<link>http://danfolkes.com/2011/07/07/me-and-micaela-at-the-beach/</link>
		<comments>http://danfolkes.com/2011/07/07/me-and-micaela-at-the-beach/#comments</comments>
		<pubDate>Thu, 07 Jul 2011 06:03:01 +0000</pubDate>
		<dc:creator>dan</dc:creator>
				<category><![CDATA[Photos]]></category>
		<category><![CDATA[Thoughts]]></category>

		<guid isPermaLink="false">http://danfolkes.com/2011/07/07/me-and-micaela-at-the-beach/</guid>
		<description><![CDATA[Me and Micaela at the Beach, originally uploaded by danfolkes. yeah.. we cool<div class='yarpp-related-rss'>

Related posts:<ol>
<li><a href='http://danfolkes.com/2011/07/19/llll/' rel='bookmark' title='Micaela&#8217;s Family'>Micaela&#8217;s Family</a></li>
</ol>
</div>
]]></description>
			<content:encoded><![CDATA[<div style="text-align: left; padding: 3px;">
<a href="http://www.flickr.com/photos/dfolkes/5913300420/" title="photo sharing"><img src="http://farm6.static.flickr.com/5278/5913300420_862e467962.jpg" style="border: solid 2px #000000;" alt="" /></a><br />
<br />
<span style="font-size: 0.8em; margin-top: 0px;"><a href="http://www.flickr.com/photos/dfolkes/5913300420/">Me and Micaela at the Beach</a>, originally uploaded by <a href="http://www.flickr.com/photos/dfolkes/">danfolkes</a>.</span>
</div>
<p>
yeah.. we cool</p>
<div class='yarpp-related-rss'>
<p>Related posts:<ol>
<li><a href='http://danfolkes.com/2011/07/19/llll/' rel='bookmark' title='Micaela&#8217;s Family'>Micaela&#8217;s Family</a></li>
</ol></p>
</div>
]]></content:encoded>
			<wfw:commentRss>http://danfolkes.com/2011/07/07/me-and-micaela-at-the-beach/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Simple PHP Pseudo Proxy</title>
		<link>http://danfolkes.com/2011/07/06/simple-php-pseudo-proxy/</link>
		<comments>http://danfolkes.com/2011/07/06/simple-php-pseudo-proxy/#comments</comments>
		<pubDate>Wed, 06 Jul 2011 11:51:56 +0000</pubDate>
		<dc:creator>dan</dc:creator>
				<category><![CDATA[PHP]]></category>
		<category><![CDATA[cache]]></category>
		<category><![CDATA[fopen]]></category>
		<category><![CDATA[PHP Proxy]]></category>
		<category><![CDATA[Proxy]]></category>
		<category><![CDATA[Simple PHP Proxy]]></category>
		<category><![CDATA[stream_get_contents]]></category>

		<guid isPermaLink="false">http://danfolkes.com/?p=1363</guid>
		<description><![CDATA[This is the code for a simple php pseudo proxy. If you are blocked by a firewall and google cache isn&#8217;t working for some reason. You can use a url with this php file in it: &#60;?php $filename = $_GET&#91;&#34;url&#34;&#93;; if &#40;isset&#40;$filename&#41;&#41; &#123; $handle = fopen&#40;$filename, &#34;rb&#34;&#41;; $contents = stream_get_contents&#40;$handle&#41;; print $contents; fclose&#40;$handle&#41;; &#125; else [...]<div class='yarpp-related-rss yarpp-related-none'>

No related posts.
</div>
]]></description>
			<content:encoded><![CDATA[<p><img src="http://danfolkes.com/wp-content/uploads/2011/07/php_simple_fake_proxy.jpg" alt="php proxy simple pseudo" title="php_simple_fake_proxy" width="335" height="74" class="alignnone size-full wp-image-1364" /></p>
<p>This is the code for a simple php pseudo proxy.  If you are blocked by a firewall and google cache isn&#8217;t working for some reason.  You can use a url with this php file in it:</p>

<div class="wp_syntax"><table><tr><td class="code"><pre class="php" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">&lt;?php</span>
<span style="color: #000088;">$filename</span> <span style="color: #339933;">=</span> <span style="color: #000088;">$_GET</span><span style="color: #009900;">&#91;</span><span style="color: #0000ff;">&quot;url&quot;</span><span style="color: #009900;">&#93;</span><span style="color: #339933;">;</span>
<span style="color: #b1b100;">if</span> <span style="color: #009900;">&#40;</span><span style="color: #990000;">isset</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$filename</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span>
<span style="color: #009900;">&#123;</span>
        <span style="color: #000088;">$handle</span> <span style="color: #339933;">=</span> <span style="color: #990000;">fopen</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$filename</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">&quot;rb&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
        <span style="color: #000088;">$contents</span> <span style="color: #339933;">=</span> <span style="color: #990000;">stream_get_contents</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$handle</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
        <span style="color: #b1b100;">print</span> <span style="color: #000088;">$contents</span><span style="color: #339933;">;</span>
        <span style="color: #990000;">fclose</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$handle</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #009900;">&#125;</span>
<span style="color: #b1b100;">else</span>
<span style="color: #009900;">&#123;</span>
        <span style="color: #b1b100;">echo</span> <span style="color: #0000ff;">&quot;url&quot;</span><span style="color: #339933;">;</span>
<span style="color: #000000; font-weight: bold;">?&gt;</span>
&lt;form method=&quot;GET&quot;&gt;
&lt;input type=&quot;text&quot; name=&quot;url&quot; /&gt;&lt;input type=&quot;submit&quot;/&gt;
&lt;/form&gt;
<span style="color: #000000; font-weight: bold;">&lt;?php</span>
<span style="color: #009900;">&#125;</span>
<span style="color: #000000; font-weight: bold;">?&gt;</span></pre></td></tr></table></div>

<p>Then you can go to where the url is hosted and try something like this:</p>

<div class="wp_syntax"><table><tr><td class="code"><pre class="html" style="font-family:monospace;">index.php?url=http%3A%2F%2Fwww.last.fm%2Fuser%2Fdanfolkes%2Fcharts%3Frangetype%3D6month%26subtype%3Dartists</pre></td></tr></table></div>

<div class='yarpp-related-rss yarpp-related-none'>
<p>No related posts.</p>
</div>
]]></content:encoded>
			<wfw:commentRss>http://danfolkes.com/2011/07/06/simple-php-pseudo-proxy/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>FoxToPhone &#8211; Send Links from Firefox to Android &#8211; (Like ChromeToPhone)</title>
		<link>http://danfolkes.com/2011/06/29/foxtophone-send-links-from-firefox-to-android-like-chrometophone/</link>
		<comments>http://danfolkes.com/2011/06/29/foxtophone-send-links-from-firefox-to-android-like-chrometophone/#comments</comments>
		<pubDate>Wed, 29 Jun 2011 12:41:47 +0000</pubDate>
		<dc:creator>dan</dc:creator>
				<category><![CDATA[Software]]></category>

		<guid isPermaLink="false">http://danfolkes.com/?p=1357</guid>
		<description><![CDATA[Just found out about FoxToPhone. It gives you a little button in Firefox that allows you to send it to be opened by your browser on your Android phone. The integration is seamless and it works like a charm. Useful Links: Firefox Plugin: FoxToPhone Android App: Google Chrome to Phone<div class='yarpp-related-rss'>

Related posts:<ol>
<li><a href='http://danfolkes.com/2008/11/20/whitehart-minimal-firefox-theme-great/' rel='bookmark' title='Whitehart &#8211; Minimal Firefox Theme, Great'>Whitehart &#8211; Minimal Firefox Theme, Great</a></li>
<li><a href='http://danfolkes.com/2012/03/23/how-to-remove-all-facebook-friends-script/' rel='bookmark' title='How to Remove All Facebook Friends &#8211; Script'>How to Remove All Facebook Friends &#8211; Script</a></li>
</ol>
</div>
]]></description>
			<content:encoded><![CDATA[<p><img src="http://danfolkes.com/wp-content/uploads/2011/06/FoxToPhone-ChromeToPhone-logo.jpg" alt="" title="FoxToPhone-ChromeToPhone-logo" width="377" height="90" class="alignnone size-full wp-image-1358" /><br />
Just found out about <a href="http://www.foxtophone.com/">FoxToPhone</a>.</p>
<p>It gives you a little button in Firefox that allows you to send it to be opened by your browser on your Android phone.<br />
<img src="http://danfolkes.com/wp-content/uploads/2011/06/FoxToPhone-ChromeToPhone-little-button.jpg" alt="" title="FoxToPhone-ChromeToPhone-little-button" width="312" height="80" class="alignnone size-full wp-image-1360" /></p>
<p>The integration is seamless and it works like a charm.<br />
Useful Links:</p>
<ul>
<li>Firefox Plugin: <a href="https://addons.mozilla.org/en-US/firefox/addon/foxtophone/">FoxToPhone</a></li>
<li>Android App: <a href="https://market.android.com/details?id=com.google.android.apps.chrometophone&#038;hl=en">Google Chrome to Phone</a></li>
</ul>
<div class='yarpp-related-rss'>
<p>Related posts:<ol>
<li><a href='http://danfolkes.com/2008/11/20/whitehart-minimal-firefox-theme-great/' rel='bookmark' title='Whitehart &#8211; Minimal Firefox Theme, Great'>Whitehart &#8211; Minimal Firefox Theme, Great</a></li>
<li><a href='http://danfolkes.com/2012/03/23/how-to-remove-all-facebook-friends-script/' rel='bookmark' title='How to Remove All Facebook Friends &#8211; Script'>How to Remove All Facebook Friends &#8211; Script</a></li>
</ol></p>
</div>
]]></content:encoded>
			<wfw:commentRss>http://danfolkes.com/2011/06/29/foxtophone-send-links-from-firefox-to-android-like-chrometophone/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Small After Lunch Motorcycle Ride</title>
		<link>http://danfolkes.com/2011/06/07/small-after-lunch-motorcycle-ride/</link>
		<comments>http://danfolkes.com/2011/06/07/small-after-lunch-motorcycle-ride/#comments</comments>
		<pubDate>Tue, 07 Jun 2011 19:39:56 +0000</pubDate>
		<dc:creator>dan</dc:creator>
				<category><![CDATA[Thoughts]]></category>

		<guid isPermaLink="false">http://danfolkes.com/?p=1335</guid>
		<description><![CDATA[Google Maps Link This was a fun little motorcycle ride after my lunch break today. Bon Air, VA curves hills train tracks not a ton of traffic paved<div class='yarpp-related-rss'>

Related posts:<ol>
<li><a href='http://danfolkes.com/2000/05/06/colbert-report-persian-gulf-secret-code/' rel='bookmark' title='Colbert Report &#8211; Persian Gulf &#8211; Secret Code'>Colbert Report &#8211; Persian Gulf &#8211; Secret Code</a></li>
<li><a href='http://danfolkes.com/2008/02/06/sitemeter/' rel='bookmark' title='sitemeter'>sitemeter</a></li>
</ol>
</div>
]]></description>
			<content:encoded><![CDATA[<p><a href="http://danfolkes.com/2011/06/07/small-after-lunch-motorcycle-ride/bon-air-motorcycle-after-lunch-ride/" rel="attachment wp-att-1336"><img src="http://danfolkes.com/wp-content/uploads/2011/06/Bon-Air-Motorcycle-After-Lunch-Ride.jpg" alt="" title="Bon Air Motorcycle After Lunch Ride" width="451" height="428" class="alignnone size-full wp-image-1336" /></a></p>
<p><a href="http://maps.google.com/maps?f=d&#038;source=s_d&#038;saddr=Western+Rd&#038;daddr=37.5192962,-77.5733165+to:Western+Rd&#038;hl=en&#038;geocode=Feu6PAId13hg-w%3BFcB_PAIdPFNg-ylDaxCCOm2xiTGkKAnspphRBA%3BFee6PAIdw3hg-w&#038;mra=dme&#038;mrsp=0&#038;sz=15&#038;via=1&#038;sll=37.526235,-77.565837&#038;sspn=0.022021,0.045447&#038;ie=UTF8&#038;ll=37.526609,-77.565064&#038;spn=0.022021,0.045447&#038;z=15">Google Maps Link</a></p>
<p>This was a fun little motorcycle ride after my lunch break today.<br />
Bon Air, VA</p>
<ul>
<li>curves</li>
<li>hills</li>
<li>train tracks</li>
<li>not a ton of traffic</li>
<li>paved</li>
</ul>
<div class='yarpp-related-rss'>
<p>Related posts:<ol>
<li><a href='http://danfolkes.com/2000/05/06/colbert-report-persian-gulf-secret-code/' rel='bookmark' title='Colbert Report &#8211; Persian Gulf &#8211; Secret Code'>Colbert Report &#8211; Persian Gulf &#8211; Secret Code</a></li>
<li><a href='http://danfolkes.com/2008/02/06/sitemeter/' rel='bookmark' title='sitemeter'>sitemeter</a></li>
</ol></p>
</div>
]]></content:encoded>
			<wfw:commentRss>http://danfolkes.com/2011/06/07/small-after-lunch-motorcycle-ride/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Facebook Website Integration &#8211; HTML</title>
		<link>http://danfolkes.com/2011/05/25/facebook-website-integration-html/</link>
		<comments>http://danfolkes.com/2011/05/25/facebook-website-integration-html/#comments</comments>
		<pubDate>Wed, 25 May 2011 15:40:03 +0000</pubDate>
		<dc:creator>dan</dc:creator>
				<category><![CDATA[Code]]></category>
		<category><![CDATA[Javascript]]></category>
		<category><![CDATA[jQuery]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[a website]]></category>
		<category><![CDATA[css]]></category>
		<category><![CDATA[facebook]]></category>
		<category><![CDATA[facebook app]]></category>
		<category><![CDATA[feed]]></category>
		<category><![CDATA[Feedburner]]></category>
		<category><![CDATA[HTML]]></category>
		<category><![CDATA[integrate]]></category>
		<category><![CDATA[integrate Facebook]]></category>
		<category><![CDATA[rss feed]]></category>
		<category><![CDATA[website]]></category>

		<guid isPermaLink="false">http://danfolkes.com/?p=1310</guid>
		<description><![CDATA[To integrate Facebook on to a website without the use of a facebook app you need these things: Facebook Page RSS Feed (can be tricky) Feedburner Account (free,easy) (here) Once you have both of those things you can do this in feedburner: Add a new feed (your facebook url) Go to the publicize tab Go [...]<div class='yarpp-related-rss'>

Related posts:<ol>
<li><a href='http://danfolkes.com/2009/03/04/howto-setup-an-aggregated-rss-feed-for-your-friends-using-google-reader/' rel='bookmark' title='HOWTO: Setup an Aggregated RSS feed for your Friends using Google Reader'>HOWTO: Setup an Aggregated RSS feed for your Friends using Google Reader</a></li>
<li><a href='http://danfolkes.com/2012/03/23/how-to-remove-all-facebook-friends-script/' rel='bookmark' title='How to Remove All Facebook Friends &#8211; Script'>How to Remove All Facebook Friends &#8211; Script</a></li>
<li><a href='http://danfolkes.com/2008/03/17/facebot-my-facebook-robot/' rel='bookmark' title='Facebot &#8211; My Facebook Robot'>Facebot &#8211; My Facebook Robot</a></li>
</ol>
</div>
]]></description>
			<content:encoded><![CDATA[<p><a href="http://danfolkes.com/2011/05/25/facebook-website-integration-html/facebook-website-integration-%e2%80%93-html-3/" rel="attachment wp-att-1321"><img src="http://danfolkes.com/wp-content/uploads/2011/05/Facebook-Website-Integration-–-HTML2.jpg" alt="" title="Facebook-Website-Integration-–-HTML" width="400" height="252" class="alignnone size-full wp-image-1321" /></a><br />
To integrate Facebook on to a website without the use of a facebook app you need these things:</p>
<ul>
<li>Facebook Page RSS Feed (<a href="http://www.google.com/search?q=find+your+facebook+rss+feed&#038;ie=utf-8&#038;oe=utf-8&#038;aq=t">can be tricky)</a></li>
<li>Feedburner Account (free,easy) (<a href="http://feedburner.google.com/">here</a>)</li>
</ul>
<p>Once you have both of those things you can do this in feedburner:</p>
<ul>
<li>Add a new feed (your facebook url)</li>
<li>Go to the publicize tab</li>
<li>Go to BuzzBoost</li>
<li>Sroll down and fill out the form, you will be given html code.</li>
<li>

<div class="wp_syntax"><table><tr><td class="code"><pre class="html" style="font-family:monospace;">&lt;script src=&quot;http://feeds.feedburner.com/DanielFolkessFacebookStatusUpdates?format=sigpro&quot; type=&quot;text/javascript&quot; &gt;&lt;/script&gt;
&lt;noscript&gt;&lt;p&gt;Subscribe to RSS headline updates from: 
&lt;a href=&quot;http://feeds.feedburner.com/DanielFolkessFacebookStatusUpdates&quot;&gt;&lt;/a&gt;
&lt;br/&gt;Powered by FeedBurner&lt;/p&gt; 
&lt;/noscript&gt;</pre></td></tr></table></div>

</li>
<li>Preview:<script src="http://feeds.feedburner.com/DanielFolkessFacebookStatusUpdates?format=sigpro" type="text/javascript" ></script><noscript>
<p>Subscribe to RSS headline updates from: <a href="http://feeds.feedburner.com/DanielFolkessFacebookStatusUpdates"></a><br/>Powered by FeedBurner</p>
<p> </noscript></li>
</ul>
<p>And that&#8217;s it!<br />
You can now style it up a little bit with some CSS and stuff.</p>
<div class='yarpp-related-rss'>
<p>Related posts:<ol>
<li><a href='http://danfolkes.com/2009/03/04/howto-setup-an-aggregated-rss-feed-for-your-friends-using-google-reader/' rel='bookmark' title='HOWTO: Setup an Aggregated RSS feed for your Friends using Google Reader'>HOWTO: Setup an Aggregated RSS feed for your Friends using Google Reader</a></li>
<li><a href='http://danfolkes.com/2012/03/23/how-to-remove-all-facebook-friends-script/' rel='bookmark' title='How to Remove All Facebook Friends &#8211; Script'>How to Remove All Facebook Friends &#8211; Script</a></li>
<li><a href='http://danfolkes.com/2008/03/17/facebot-my-facebook-robot/' rel='bookmark' title='Facebot &#8211; My Facebook Robot'>Facebot &#8211; My Facebook Robot</a></li>
</ol></p>
</div>
]]></content:encoded>
			<wfw:commentRss>http://danfolkes.com/2011/05/25/facebook-website-integration-html/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Java &#8211; Singleton / Global &#8211; Data Access &#8211; SQLite</title>
		<link>http://danfolkes.com/2011/05/20/java-singleton-global-data-access-sqlite/</link>
		<comments>http://danfolkes.com/2011/05/20/java-singleton-global-data-access-sqlite/#comments</comments>
		<pubDate>Fri, 20 May 2011 16:21:10 +0000</pubDate>
		<dc:creator>dan</dc:creator>
				<category><![CDATA[Code]]></category>
		<category><![CDATA[DataAccess]]></category>
		<category><![CDATA[Global]]></category>
		<category><![CDATA[java]]></category>
		<category><![CDATA[JAVA Global]]></category>
		<category><![CDATA[Java Singleton]]></category>
		<category><![CDATA[Singleton]]></category>
		<category><![CDATA[SingletonHolder.INSTANCE]]></category>
		<category><![CDATA[SQLite]]></category>
		<category><![CDATA[sqlite4java]]></category>

		<guid isPermaLink="false">http://danfolkes.com/?p=1071</guid>
		<description><![CDATA[This will make a Java global object: import java.io.File; import java.io.IOException; &#160; import com.almworks.sqlite4java.SQLite; import com.almworks.sqlite4java.SQLiteConnection; import com.almworks.sqlite4java.SQLiteException; import com.almworks.sqlite4java.SQLiteJob; import com.almworks.sqlite4java.SQLiteQueue; import com.almworks.sqlite4java.SQLiteStatement; &#160; public final class DataAccess &#123; // Singleton Stuff private static class SingletonHolder &#123; public static final DataAccess INSTANCE = new DataAccess&#40;&#41;; &#125; public static DataAccess getInstance&#40;&#41; &#123; return SingletonHolder.INSTANCE; &#125; [...]<div class='yarpp-related-rss'>

Related posts:<ol>
<li><a href='http://danfolkes.com/2008/08/11/python-cell-phone-number-pad-input/' rel='bookmark' title='Python &#8211; Cell Phone Number Pad Input'>Python &#8211; Cell Phone Number Pad Input</a></li>
<li><a href='http://danfolkes.com/2009/01/22/python-grab-email-from-gmail-and-insert-into-mysql-database/' rel='bookmark' title='Python: Grab Email from Gmail and Insert into MySql Database'>Python: Grab Email from Gmail and Insert into MySql Database</a></li>
<li><a href='http://danfolkes.com/2009/10/19/override-the-window-onload-javascript-function/' rel='bookmark' title='Override the window.onload javascript function'>Override the window.onload javascript function</a></li>
</ol>
</div>
]]></description>
			<content:encoded><![CDATA[<p>This will make a Java global object:</p>

<div class="wp_syntax"><table><tr><td class="code"><pre class="java" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">import</span> <span style="color: #006699;">java.io.File</span><span style="color: #339933;">;</span>
<span style="color: #000000; font-weight: bold;">import</span> <span style="color: #006699;">java.io.IOException</span><span style="color: #339933;">;</span>
&nbsp;
<span style="color: #000000; font-weight: bold;">import</span> <span style="color: #006699;">com.almworks.sqlite4java.SQLite</span><span style="color: #339933;">;</span>
<span style="color: #000000; font-weight: bold;">import</span> <span style="color: #006699;">com.almworks.sqlite4java.SQLiteConnection</span><span style="color: #339933;">;</span>
<span style="color: #000000; font-weight: bold;">import</span> <span style="color: #006699;">com.almworks.sqlite4java.SQLiteException</span><span style="color: #339933;">;</span>
<span style="color: #000000; font-weight: bold;">import</span> <span style="color: #006699;">com.almworks.sqlite4java.SQLiteJob</span><span style="color: #339933;">;</span>
<span style="color: #000000; font-weight: bold;">import</span> <span style="color: #006699;">com.almworks.sqlite4java.SQLiteQueue</span><span style="color: #339933;">;</span>
<span style="color: #000000; font-weight: bold;">import</span> <span style="color: #006699;">com.almworks.sqlite4java.SQLiteStatement</span><span style="color: #339933;">;</span>
&nbsp;
<span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000000; font-weight: bold;">final</span> <span style="color: #000000; font-weight: bold;">class</span> DataAccess <span style="color: #009900;">&#123;</span>
	<span style="color: #666666; font-style: italic;">// Singleton Stuff</span>
	<span style="color: #000000; font-weight: bold;">private</span> <span style="color: #000000; font-weight: bold;">static</span> <span style="color: #000000; font-weight: bold;">class</span> SingletonHolder <span style="color: #009900;">&#123;</span> 
	     <span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000000; font-weight: bold;">static</span> <span style="color: #000000; font-weight: bold;">final</span> DataAccess INSTANCE <span style="color: #339933;">=</span> <span style="color: #000000; font-weight: bold;">new</span> DataAccess<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #009900;">&#125;</span>
	<span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000000; font-weight: bold;">static</span> DataAccess getInstance<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
	     <span style="color: #000000; font-weight: bold;">return</span> SingletonHolder.<span style="color: #006633;">INSTANCE</span><span style="color: #339933;">;</span>
	<span style="color: #009900;">&#125;</span>
	<span style="color: #666666; font-style: italic;">// End Singleton Stuff</span>
&nbsp;
&nbsp;
	<span style="color: #000000; font-weight: bold;">private</span> <span style="color: #003399;">String</span> HomePath <span style="color: #339933;">=</span> <span style="color: #0000ff;">&quot;&quot;</span><span style="color: #339933;">;</span>
	<span style="color: #000000; font-weight: bold;">private</span> <span style="color: #003399;">File</span> DBFile<span style="color: #339933;">;</span>
	<span style="color: #000000; font-weight: bold;">private</span> <span style="color: #000000; font-weight: bold;">static</span> SQLiteQueue queue<span style="color: #339933;">;</span>
	<span style="color: #000000; font-weight: bold;">private</span> <span style="color: #000066; font-weight: bold;">boolean</span> initalized <span style="color: #339933;">=</span> <span style="color: #000066; font-weight: bold;">false</span><span style="color: #339933;">;</span>
&nbsp;
	<span style="color: #000000; font-weight: bold;">private</span> DataAccess<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span>
	<span style="color: #009900;">&#123;</span>
		<span style="color: #000000; font-weight: bold;">if</span> <span style="color: #009900;">&#40;</span><span style="color: #339933;">!</span>initalized<span style="color: #009900;">&#41;</span>
		<span style="color: #009900;">&#123;</span>
			initDB<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
			initalized <span style="color: #339933;">=</span> <span style="color: #000066; font-weight: bold;">true</span><span style="color: #339933;">;</span>
		<span style="color: #009900;">&#125;</span>
	<span style="color: #009900;">&#125;</span>
&nbsp;
	<span style="color: #000000; font-weight: bold;">private</span> <span style="color: #000066; font-weight: bold;">void</span> initDB<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span>
	<span style="color: #009900;">&#123;</span>
		DBFile <span style="color: #339933;">=</span> locateDBFile<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
		DeleteDatabaseContents<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #009900;">&#125;</span>
	<span style="color: #000000; font-weight: bold;">private</span> <span style="color: #003399;">File</span> locateDBFile<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span>
	<span style="color: #009900;">&#123;</span>
		<span style="color: #003399;">File</span> f <span style="color: #339933;">=</span> <span style="color: #000066; font-weight: bold;">null</span><span style="color: #339933;">;</span>
		<span style="color: #000000; font-weight: bold;">try</span><span style="color: #009900;">&#123;</span>
			HomePath <span style="color: #339933;">=</span> <span style="color: #003399;">System</span>.<span style="color: #006633;">getProperty</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;user.home&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
    	    <span style="color: #003399;">System</span>.<span style="color: #006633;">out</span>.<span style="color: #006633;">println</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;HomePath: &quot;</span> <span style="color: #339933;">+</span> HomePath<span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
    	    f <span style="color: #339933;">=</span> <span style="color: #000000; font-weight: bold;">new</span> <span style="color: #003399;">File</span><span style="color: #009900;">&#40;</span>HomePath <span style="color: #339933;">+</span> <span style="color: #0000ff;">&quot;/database.sqlite&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
    	    <span style="color: #000000; font-weight: bold;">if</span> <span style="color: #009900;">&#40;</span>f.<span style="color: #006633;">canRead</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span>
    	    	<span style="color: #000000; font-weight: bold;">return</span> f<span style="color: #339933;">;</span>
    	    <span style="color: #000000; font-weight: bold;">else</span>
    	    <span style="color: #009900;">&#123;</span>
        	    <span style="color: #000066; font-weight: bold;">boolean</span> success <span style="color: #339933;">=</span> f.<span style="color: #006633;">createNewFile</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
        	    <span style="color: #000000; font-weight: bold;">if</span> <span style="color: #009900;">&#40;</span>success<span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
        	        <span style="color: #666666; font-style: italic;">// File did not exist and was created</span>
        	    <span style="color: #009900;">&#125;</span> <span style="color: #000000; font-weight: bold;">else</span> <span style="color: #009900;">&#123;</span>
        	        <span style="color: #666666; font-style: italic;">// File already exists</span>
&nbsp;
        	    <span style="color: #009900;">&#125;</span>
    	    <span style="color: #009900;">&#125;</span>
    	<span style="color: #009900;">&#125;</span> <span style="color: #000000; font-weight: bold;">catch</span> <span style="color: #009900;">&#40;</span><span style="color: #003399;">IOException</span> e<span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
    		<span style="color: #666666; font-style: italic;">//Maybe try a new directory.</span>
    	<span style="color: #009900;">&#125;</span>
		<span style="color: #000000; font-weight: bold;">return</span> f<span style="color: #339933;">;</span>
	<span style="color: #009900;">&#125;</span>
&nbsp;
	<span style="color: #000000; font-weight: bold;">private</span> <span style="color: #000066; font-weight: bold;">void</span> DeleteDatabaseContents<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span>
	<span style="color: #009900;">&#123;</span>
		queue.<span style="color: #006633;">execute</span><span style="color: #009900;">&#40;</span><span style="color: #000000; font-weight: bold;">new</span> SQLiteJob<span style="color: #339933;">&lt;</span>Object<span style="color: #339933;">&gt;</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> 
		<span style="color: #009900;">&#123;</span>
		    <span style="color: #000000; font-weight: bold;">protected</span> <span style="color: #003399;">Object</span> job<span style="color: #009900;">&#40;</span>SQLiteConnection connection<span style="color: #009900;">&#41;</span> <span style="color: #000000; font-weight: bold;">throws</span> SQLiteException 
		    <span style="color: #009900;">&#123;</span>
		      <span style="color: #666666; font-style: italic;">// this method is called from database thread and passed the connection</span>
				StringBuilder sb <span style="color: #339933;">=</span> <span style="color: #000000; font-weight: bold;">new</span> StringBuilder<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
				sb.<span style="color: #006633;">append</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;DROP TABLE IF EXISTS Playlist;&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
				sb.<span style="color: #006633;">append</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;DROP TABLE IF EXISTS Settings;&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
				<span style="color: #666666; font-style: italic;">//sb.append(&quot;DELETE FROM someTable;&quot;);</span>
				<span style="color: #666666; font-style: italic;">//sb.append(&quot;DELETE FROM someTable;&quot;);</span>
&nbsp;
&nbsp;
				connection.<span style="color: #006633;">exec</span><span style="color: #009900;">&#40;</span>sb.<span style="color: #006633;">toString</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
				<span style="color: #000000; font-weight: bold;">return</span> <span style="color: #000066; font-weight: bold;">null</span><span style="color: #339933;">;</span>
		    <span style="color: #009900;">&#125;</span>
		<span style="color: #009900;">&#125;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #009900;">&#125;</span>
	<span style="color: #000000; font-weight: bold;">public</span> <span style="color: #003399;">String</span> getHomePath<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span>
	<span style="color: #009900;">&#123;</span>
		<span style="color: #000000; font-weight: bold;">return</span> HomePath<span style="color: #339933;">;</span>
	<span style="color: #009900;">&#125;</span>
<span style="color: #009900;">&#125;</span></pre></td></tr></table></div>

<p>Now you can run this from anywhere:</p>

<div class="wp_syntax"><table><tr><td class="code"><pre class="java" style="font-family:monospace;">DataAccess da<span style="color: #339933;">;</span>
da <span style="color: #339933;">=</span> DataAccess.<span style="color: #006633;">getInstance</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span></pre></td></tr></table></div>

<p>Source: http://en.wikipedia.org/wiki/Singleton_pattern</p>
<div class='yarpp-related-rss'>
<p>Related posts:<ol>
<li><a href='http://danfolkes.com/2008/08/11/python-cell-phone-number-pad-input/' rel='bookmark' title='Python &#8211; Cell Phone Number Pad Input'>Python &#8211; Cell Phone Number Pad Input</a></li>
<li><a href='http://danfolkes.com/2009/01/22/python-grab-email-from-gmail-and-insert-into-mysql-database/' rel='bookmark' title='Python: Grab Email from Gmail and Insert into MySql Database'>Python: Grab Email from Gmail and Insert into MySql Database</a></li>
<li><a href='http://danfolkes.com/2009/10/19/override-the-window-onload-javascript-function/' rel='bookmark' title='Override the window.onload javascript function'>Override the window.onload javascript function</a></li>
</ol></p>
</div>
]]></content:encoded>
			<wfw:commentRss>http://danfolkes.com/2011/05/20/java-singleton-global-data-access-sqlite/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/

Page Caching using disk: enhanced

 Served from: danfolkes.com @ 2013-05-22 10:58:10 by W3 Total Cache -->