<?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>Peter Törnstrand &#187; asp</title>
	<atom:link href="http://www.tornstrand.com/tag/asp/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.tornstrand.com</link>
	<description>Drupal, PHP and web developing</description>
	<lastBuildDate>Fri, 16 Apr 2010 07:04:56 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.1</generator>
		<item>
		<title>Classical ASP YouTube class</title>
		<link>http://www.tornstrand.com/2008/02/12/classical-asp-youtube-class/</link>
		<comments>http://www.tornstrand.com/2008/02/12/classical-asp-youtube-class/#comments</comments>
		<pubDate>Tue, 12 Feb 2008 16:37:07 +0000</pubDate>
		<dc:creator>peter</dc:creator>
				<category><![CDATA[asp]]></category>
		<category><![CDATA[classical asp]]></category>
		<category><![CDATA[oop]]></category>
		<category><![CDATA[video]]></category>

		<guid isPermaLink="false">http://www.tornstrand.com/2008/02/12/classical-asp-youtube-class/</guid>
		<description><![CDATA[Believe it or not but from time to time I actually get to do some programing with classical ASP, you know that stoneage technology that came before the .NET framework. Back in the days the concept of using classes was beyond me so when I got the chance the other day to do some ASP [...]]]></description>
			<content:encoded><![CDATA[<p>Believe it or not but from time to time I actually get to do some programing with classical ASP, you know that stoneage technology that came before the .NET framework. Back in the days the concept of using classes was beyond me so when I got the chance the other day to do some ASP coding I decided to do it the OOP way.<span id="more-9"></span></p>
<p>Classical ASP actually offers a pretty decent support for classes. It has private and public properties, constructors, functions, sub&#8217;s and getter and setter methods similar to those in ASP.NET.</p>
<p>The job was to create a video listing page for a clients site where the client would upload videos on YouTube and then have them automatically listed on her own site. The class supports video listing by searching, videos uploaded by a users and videos from a specific feed.</p>
<p>Let&#8217;s have a look at an example:</p>
<pre>Set results = Server.CreateObject("Scripting.Dictionary")
Set yt = new YouTube
yt.Search results, "", "BillGates", 1, 10, "video", true, 0, "rating"
keys = results.Keys
For i = 0 To results.Count -1
    Response.Write(results.Item(keys(i)).Title &amp; "&lt;br/&gt;")
    Response.Write(results.Item(keys(i)).ShortDescription &amp; "&lt;br/&gt;")
Next</pre>
<p>The code above would return videos 1-10 uploaded by the user BillGates sorted by rating. Download the source code below.</p>
<p><a href="http://www.tornstrand.com/wp-content/uploads/2008/02/youtube_class.txt" title="Classical ASP YouTube class">Source code: Classical ASP YouTube class</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.tornstrand.com/2008/02/12/classical-asp-youtube-class/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>
