<?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/"
	xmlns:itunes="http://www.itunes.com/dtds/podcast-1.0.dtd"
	xmlns:media="http://search.yahoo.com/mrss/"
>

<channel>
	<title>Web Development Blog &#187; Embedding YouTube Videos the Standards Compliant Way—SFWobject 2.0 | Web Development Blog &#8211; Heidi Cool &#8211; Cleveland, Ohio</title>
	<atom:link href="http://www.heidicool.com/blog/category/javascript/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.heidicool.com/blog</link>
	<description>web • content • marketing • navigation • seo • social media</description>
	<lastBuildDate>Thu, 17 Feb 2011 21:09:05 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
	<!-- podcast_generator="podPress/8.8" -->
		<copyright>&#xA9; </copyright>
		<managingEditor>gravity69@gmail.com ()</managingEditor>
		<webMaster>gravity69@gmail.com()</webMaster>
		<category></category>
		<itunes:keywords></itunes:keywords>
		<itunes:subtitle></itunes:subtitle>
		<itunes:summary>content bull; architecture bull;nbsp;marketing bull;nbsp;seo bull; social media</itunes:summary>
		<itunes:author></itunes:author>
		<itunes:category text="Society &amp; Culture"/>
		<itunes:owner>
			<itunes:name></itunes:name>
			<itunes:email>gravity69@gmail.com</itunes:email>
		</itunes:owner>
		<itunes:block>No</itunes:block>
		<itunes:explicit>no</itunes:explicit>
		<itunes:image href="http://www.heidicool.com/blog/wp-content/plugins/podpress/images/powered_by_podpress_large.jpg" />
		<image>
			<url>http://www.heidicool.com/blog/wp-content/plugins/podpress/images/powered_by_podpress.jpg</url>
			<title>Web Development Blog</title>
			<link>http://www.heidicool.com/blog</link>
			<width>144</width>
			<height>144</height>
		</image>
		<item>
		<title>Embedding YouTube Videos the Standards Compliant Way—SFWobject 2.0</title>
		<link>http://www.heidicool.com/blog/2008/04/20/embedding-youtube-videos-the-standards-compliant-waysfwobject-20/</link>
		<comments>http://www.heidicool.com/blog/2008/04/20/embedding-youtube-videos-the-standards-compliant-waysfwobject-20/#comments</comments>
		<pubDate>Mon, 21 Apr 2008 03:24:50 +0000</pubDate>
		<dc:creator>Heidi Cool</dc:creator>
				<category><![CDATA[Heidi's Entries]]></category>
		<category><![CDATA[How-to]]></category>
		<category><![CDATA[Html]]></category>
		<category><![CDATA[Javascript]]></category>
		<category><![CDATA[Video]]></category>
		<category><![CDATA[Web Standards]]></category>
		<category><![CDATA[youtube]]></category>

		<guid isPermaLink="false">http://www.heidicool.com/blog/?p=132</guid>
		<description><![CDATA[As video becomes easier to produce, more and more people are creating and sharing videso online. Whether you are a professor demonstrating your research, a student working on a film project, or me creating how-to instructions, you've realized that there are times when video can enhance your Web content.

Back at the turn of the century, embedding video was complicated. Streaming required a special server, you had to decide what format(s) you wanted to stream, then you had to provide links to whatever software users might need to view your video—in case it wasn't already installed on their computers.

With YouTube, that's all changed. Now you can just go to the YouTube page for the video you wish to embed, copy the coding they provide, paste it into your html file or blog entry and publish the page.

It's just that easy—unless, like me, you care about adhering to Web standards. In that case, it requires a few more steps, but don't worry, they're not that complicated.

]]></description>
			<content:encoded><![CDATA[<p>As video becomes easier to produce, more and more people are creating and sharing videos online. Whether you are a professor demonstrating your research, a student working on a film project, or me creating how-to instructions, you've realized that there are times when video can enhance your Web content. </p>

<p class="photoright">
<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" width="425" height="350" id="myFlashContent">
<param name="movie" value="http://www.youtube.com/v/b-tYxJcFj9I&amp;hl=en" />
<param name="wmode" value="opaque" />
<!--[if !IE]>-->
<object type="application/x-shockwave-flash" data="http://www.youtube.com/v/b-tYxJcFj9I&amp;hl=en" width="425" height="355">
<param name="wmode" value="opaque" />
<!--<![endif]-->
<a href="http://www.adobe.com/go/getflashplayer">
<img src="http://www.adobe.com/images/shared/download_buttons/get_flash_player.gif" alt="Get Adobe Flash player" />
</a>
<!--[if !IE]>-->
</object>
<!--<![endif]-->
</object>
<br />The resolution on YouTube is not as crisp as the original. <br />
You can also view the video in <a href="http://blog.case.edu/webdev/2008/04/20/youtubeembed.mov">higher resolution .mov format</a>.</p>


<p>Back at the turn of the century, embedding video was complicated. Streaming required a special server, you had to decide what format(s) you wanted to stream, then you had to provide links to whatever software users might need to view your video&mdash;in case it wasn't already installed on their computers. </p>
<p>With <a href="http://www.youtube.com">YouTube</a>, that's all changed. Now you can just go to the YouTube page for the video you wish to embed, copy the coding they provide, paste it into your html file or blog entry and publish the page. </p>
<p>It's just that easy&mdash;unless, like me, you care about adhering to <a href="http://www.heidicool.com/blog/2007/08/28/an-introduction-to-web-standards/">Web
standards</a>. In that case, it requires a few more steps, but don't worry, they're not that complicated. YouTube videos can be embedded on the Web using swfobject.js&mdash;in a manner similar to the method I described last year in &quot;<a href="http://www.heidicool.com/blog/2007/04/19/embedding-flash-objects-for-internet-explorer/">Embedding
Flash Objects for Internet Explorer</a>.&quot; You can also use this method for embedding regular Flash .swf files. Just substitute the path to your .swf for the YouTube link in the instructions below. </p>

<h5>Downloading swfobject 2.0</h5>
<p>SWFObject 2.0 provides a significant upgrade to SWFObject 1.5&mdash;what we'd previously been using to embed Flash .swf files. To begin you will want to <a href="http://swfobject.googlecode.com/files/swfobject_2_0.zip">download
the new script</a> from the <a href="http://code.google.com/p/swfobject/">SWFobject
project page</a>. After downloading the script, you can upload it to your site, in whichever directory you prefer. <em>Note: SWFobject 2.0 is not backwards compatible with 1.5, but the script has the same file name, swfobject.js. If you are already using 1.5 on your site&mdash;and don't plan to immediately edit all the pages that use it&mdash;you should rename the file to something like swfobject2.js or store it in a different directory so that you don't write over the prior version.</em> </p>

<h5>Generate the embed code for your page</h5>
<p>While you could do this manually by following the instructions in the <a href="http://code.google.com/p/swfobject/wiki/documentation">documentation</a>, the SWFobject team has provided a rather handy Web-based code generator that we'll use in this example. </p>
<ol>
<li>Go the the YouTube page for the video you wish to embed and copy the embed code provided.</li>
<li>Paste this into a blank file in Dreamweaver or your preferred editor. We won't be using this code in our page, but we'll want it for reference.
<p class="code">&lt;object width=&quot;425&quot; height=&quot;355&quot;&gt;&lt;param
name=&quot;movie&quot; value=&quot;http://www.youtube.com/v/b-tYxJcFj9I&amp;hl=en&quot;&gt;&lt;/param&gt;&lt;param
name=&quot;wmode&quot; value=&quot;transparent&quot;&gt;&lt;/param&gt;&lt;embed
src=&quot;http://www.youtube.com/v/b-tYxJcFj9I&amp;hl=en&quot; type=&quot;application/x-shockwave-flash&quot; wmode=&quot;transparent&quot; width=&quot;425&quot; height=&quot;355&quot;&gt;&lt;/embed&gt;&lt;/object&gt;</p>
</li>
<li>Within this code you will see a link to the video after value=&quot;. Within
this link there may be an ampersand. <a href="http://www.html-reference.com/Escape.htm">Escape</a> the &amp; by
typing amp; after it. </li>
<li>Copy this link,<span class="code">http://www.youtube.com/v/b-tYxJcFj9I&amp;amp;hl=en</span>,
then go to the <a href="http://code.google.com/p/swfobject/wiki/generator">SWFObject
2.0 HTML and JavaScript generator</a>.</li>
<li>Paste the link in the box to the right of &quot;Flash (.swf):.&quot;</li>
<li>Near the top of the generator, choose between static and dynamic. I will
be using static in this example as dynamic would require me to put additional
code--specific to this video--in my header. Here on the blog my headers are
part of my templates so I can't use anything that would be specific to only
one entry. (The <a href="http://code.google.com/p/swfobject/wiki/documentation">documentation</a> offers
additional information on the static and dynamic methods.)</li>
<li>Copy the width and height values from the YouTube embed code and paste
them into the dimensions boxes in the generator.</li>
<li>Click on &quot;more&quot; in the SWF definition box if you like to edit
additional <a href="http://kb.adobe.com/selfservice/viewContent.do?externalId=tn_12701&amp;sliceId=2">attributes</a>. </li>
<li>In the HTML definition box choose the version of XHTML or HTML and character
encoding you use on your Web site. </li>
<li>Click the &quot;Generate Code&quot; button.</li>
</ol>

<h5>Embedding the video in your page</h5>
<ol>
<li>Copy the script code found with the head of the generated output. <p class="code">&lt;script
type=&quot;text/javascript&quot; src=&quot;swfobject.js&quot;&gt;&lt;/script&gt;<br />
&lt;script type=&quot;text/javascript&quot;&gt;<br />
swfobject.registerObject(&quot;myFlashContent&quot;, &quot;9.0.0&quot;);<br />
&lt;/script&gt; </p></li>
<li>Paste this into the head of your HTML file or blog templates. <em>Note:
Because I have already been using the previous version of SWFobject on this
blog, I named my script swfobject2.js before uploading it to the server.
Therefore I must also change the name in this code then add it to the code
that is already in my templates.</em> Thus my files will include:
<p class="code">&lt;script type=&quot;text/javascript&quot; src=&quot;swfobject.js&quot;&gt;&lt;/script&gt;<br />
&lt;script
type=&quot;text/javascript&quot; src=&quot;swfobject2.js&quot;&gt;&lt;/script&gt;<br />
&lt;script type=&quot;text/javascript&quot;&gt;<br />
swfobject.registerObject(&quot;myFlashContent&quot;, &quot;9.0.0&quot;);<br />
&lt;/script&gt; </p></li>
<li>Copy the object code found within the body of the generated output. <p class="code">&lt;object classid=&quot;clsid:D27CDB6E-AE6D-11cf-96B8-444553540000&quot; width=&quot;425&quot; height=&quot;350&quot; id=&quot;myFlashContent&quot;&gt;<br />
&lt;param name=&quot;movie&quot; value=&quot;http://www.youtube.com/v/b-tYxJcFj9I&amp;amp;hl=en&quot; /&gt;<br />
&lt;param name=&quot;wmode&quot; value=&quot;opaque&quot; /&gt;<br />
&lt;!--[if !IE]&gt;--&gt;<br />
&lt;object type=&quot;application/x-shockwave-flash&quot; data=&quot;http://www.youtube.com/v/b-tYxJcFj9I&amp;amp;hl=en&quot; width=&quot;425&quot; height=&quot;355&quot;&gt;<br />
&lt;param name=&quot;wmode&quot; value=&quot;opaque&quot; /&gt;<br />
&lt;!--&lt;![endif]--&gt;<br />
&lt;a href=&quot;http://www.adobe.com/go/getflashplayer&quot;&gt;<br />
&lt;img src=&quot;http://www.adobe.com/images/shared/download_buttons/get_flash_player.gif&quot; alt=&quot;Get Adobe Flash player&quot; /&gt;<br />
&lt;/a&gt;<br />
&lt;!--[if !IE]&gt;--&gt;<br />
&lt;/object&gt;<br />
&lt;!--&lt;![endif]--&gt;<br />
&lt;/object&gt;</p></li>
<li>Paste this into the place in your file where you would like the video to
appear. </li>
<li>Upload the file to your server and watch the video! </li>
</ol>

<h5>SWFObject Resources</h5>
<ul>
<li><a href="http://www.swffix.org/devblog/">SWFObject devblog</a></li>

<li><a href="http://groups.google.com/group/swfobject">Active Content Developer Center</a> </li>
<li><a href="http://blogs.msdn.com/ie/archive/2008/04/08/ie-automatic-component-activation-now-available.aspx">IE Automatic Component Activation Now Available</a> (Internet Explorer users will no longer have to click to activate videos embedded using the static method.) </li>
<li><a href="http://www.adobe.com/devnet/activecontent/faq.html">SWFObject discussion group</a> </li>
<li><a href="http://code.google.com/p/swfobject/wiki/SWFObject_2_0_documentation">SWFObject 2.0 Documentation</a> </li>
<li><a href="http://code.google.com/apis/youtube/js_api_reference.html">YouTube JavaScript Player API Reference</a> </li>

</ul>

<h5>About the <em>Embedding YouTube Videos the Standards Compliant Way</em> video</h5>
<p>The video screen captures were recorded using <a href="http://www.shinywhitebox.com/home/home.html">iShowU</a>, a program I discovered yesterday afternoon. The scenes were pieced together, and audio was recorded and added in <a href="http://www.apple.com/ilife/imovie/">iMovie</a>. As this was my first time experimenting with iShowU some portions of the video are a bit wobbly, but overall I found it very easy to use. I expect my skills will improve with time. </p>
<p>I'll post more about the process as I become more familiar with the software. Members of the Case Western Reserve University community interested in producing similar instructional videos may also wish to visit the <a href="http://fc.case.edu/">Freedman
Center</a> which offers tools and instructions on this and related topics. </p>

]]></content:encoded>
			<wfw:commentRss>http://www.heidicool.com/blog/2008/04/20/embedding-youtube-videos-the-standards-compliant-waysfwobject-20/feed/</wfw:commentRss>
		<slash:comments>18</slash:comments>
<enclosure url="http://blog.case.edu/webdev/2008/04/20/youtubeembed.mov" length="24578199" type="video/quicktime" />
		</item>
		<item>
		<title>When one image just won&#8217;t do; incorporating slideshows on your Web site. Part 1: Javascript</title>
		<link>http://www.heidicool.com/blog/2007/06/06/when-one-image-just-wont-do-incorporating-slideshows-on-your-web-site-part-1-javascript/</link>
		<comments>http://www.heidicool.com/blog/2007/06/06/when-one-image-just-wont-do-incorporating-slideshows-on-your-web-site-part-1-javascript/#comments</comments>
		<pubDate>Thu, 07 Jun 2007 01:27:59 +0000</pubDate>
		<dc:creator>Heidi Cool</dc:creator>
				<category><![CDATA[Heidi's Entries]]></category>
		<category><![CDATA[How-to]]></category>
		<category><![CDATA[Javascript]]></category>
		<category><![CDATA[slideshow1]]></category>

		<guid isPermaLink="false">http://www.heidicool.com/blog/?p=98</guid>
		<description><![CDATA[It's funny how people get the same idea at the same time. Last week I had two different people ask me how they could use a slideshow instead of a still picture on their Web site.
]]></description>
			<content:encoded><![CDATA[
<p class="photoright">
<script language="JavaScript1.2" type="text/javascript">
/*Multi image slideshow script- by javascriptkit.com
Visit JavaScript Kit (http://javascriptkit.com) for script
Credit must stay intact for use*/

//#1 SPECIFY number of slideshows
var number_of_slideshows=1

//#2 SPECIFY interval between slide (2000=2 seconds)
var interval=2000

//#3 SHOULD each slide be linked to a unique URL?
var linked=1

var slideshows=new Array(number_of_slideshows)
for (i=0; i <number_of_slideshows;i++)
slideshows[i]=new Array()

//#4 SPECIFY image paths of 1st slideshow
slideshows[0][0]='http://blog.case.edu/webdev/2007/06/06/parade1a.jpg'
slideshows[0][1]='http://blog.case.edu/webdev/2007/06/06/parade2a.jpg'
slideshows[0][2]='http://blog.case.edu/webdev/2007/06/06/parade3a.jpg'
slideshows[0][3]='http://blog.case.edu/webdev/2007/06/06/parade4a.jpg'
slideshows[0][4]='http://blog.case.edu/webdev/2007/06/06/parade5a.jpg'




<!--Remove the below portion if "var linked" above is set to 0-->

var slidelinks=new Array(number_of_slideshows)
for (i=0; i <number_of_slideshows;i++)
slidelinks[i]=new Array()

//#5 SPECIFY urls of 1st slideshow
slidelinks[0][0]='http://blog.case.edu/webdev/2007/06/06/parade1a.jpg'
slidelinks[0][1]='http://blog.case.edu/webdev/2007/06/06/parade2a.jpg'
slidelinks[0][2]='http://blog.case.edu/webdev/2007/06/06/parade3a.jpg'
slidelinks[0][3]='http://blog.case.edu/webdev/2007/06/06/parade4a.jpg'
slidelinks[0][4]='http://blog.case.edu/webdev/2007/06/06/parade5a.jpg'




function clickredir(){
window.location=slidelinks[maininc][subinc]
}

<!-- END removal-->

var maininc=0
var subinc=0

if (linked)
document.write('<a href="javascript:clickredir()"><img src="'+slideshows[0][0]+'" name="multislide" border=0></a>')
else
document.write('<img src="'+slideshows[0][0]+'" name="multislide">')

function slideit(){
subinc= (subinc<slideshows[maininc].length-1)? subinc+1: 0
document.images.multislide.src=slideshows[maininc][subinc]
}

function setslide(which){
clearInterval(runit)
maininc=which
subinc=0
runit=setInterval("slideit()",interval)
}

runit=setInterval("slideit()",interval)
</script><br />
Slideshow using javascript<br /><br />
Photos are from Parade the Circle 2006.<br />
<a href="http://www.clevelandart.org/educef/parade/html/index.html">This year's parade</a> is this Saturday, June 9.

</p>
<p>It's funny how people get the same idea at the same time. Last week I had two different people ask me how they could use a slideshow instead of a still picture on their Web site. Many people find that one image doesn't exemplify all of the qualities of the department's site. That was true for me when I was building the <a href="http://www.case.edu/univrel/marcomm/">Marketing and Communications</a> site. There wasn't one image that would symbolize our group so I used Flash to make a slideshow highlighting different facets and activities of the university. This slideshow appears on our main page in place of the usual photograph. </p>
<p>If you are already familiar with Flash you may want to use this option. If you've never used Flash, you will probably find it easier to use Javascript. There are many scripts available that only require minor edits. </p>

<h5>Using Javascript to create a slideshow</h5>
<p>If you do a Google search on "<a href="http://www.google.com/search?q=javascript+slideshow&amp;start=0&amp;ie=utf-8&amp;oe=utf-8&amp;client=firefox-a&amp;rls=org.mozilla:en-US:official">javascript slideshow</a>" you'll find all sorts of options. For today's project I chose to use the <a href="http://wsabstract.com/script/script2/multishow.shtml">Multi image slideshow</a> script I found from <a href="http://javascriptkit.com/">http://javascriptkit.com/</a>. This is the slideshow you will see on the right.  You don't need to be a Javascript whiz to use this script. Anyone comfortable with the basics of HTML should be able to make the edits fairly easily. </p>
<ul>
<li>To use this script you will first want to prepare a series of .jpg images that are sized to the same dimension. Upload these to the same directory as the page on which the slideshow will appear. </li>
<li>Copy the script from the box on <a href="http://wsabstract.com/script/script2/multishow.shtml">http://wsabstract.com/script/script2/multishow.shtml</a> and paste it into the location it should appear on your Web page. </li>
<li>Edit the script.
<ul>
<li>This script allows you to have multiple sets of slides and links to each set. Since I was only using one set I deleted the code for the two extra sets, changed "3" to "1" in "#1 SPECIFY number of slideshows" and removed the links that came after the end of the script. The comments in the script make it easy to understand which sections you can edit or remove.</li>
<li>Under "#2 SPECIFY interval between slide" I left the interval at 2000 but you could easily modify this if you want the pictures to change more slowly.</li>
<li>Add or delete paths to images as necessary. I used 5 images (rather than 3) so, following the same format as in the script, I added my 4th and 5th images in the areas under "#4 SPECIFY image paths of 1st slideshow" and "#5 SPECIFY urls of 1st slideshow."</li>
</ul></li>
<li>Save your .html file, upload it to the server and see if it is working. If it isn't working check to make sure you specified the right paths to your images and didn't accidently delete any necessary code. </li>
</ul>

<p>P.S. Those of you know pay attention to such things may have noticed that this script causes some validation errors. I'm going to see about cleaning it up tomorrow.</p>

<h5>P.S. P.S. For those of you anxious to update your sites, I will begin distributing the appropriate new logo files for Web Development on July 1st. I am preparing and testing the files now.</h5>






]]></content:encoded>
			<wfw:commentRss>http://www.heidicool.com/blog/2007/06/06/when-one-image-just-wont-do-incorporating-slideshows-on-your-web-site-part-1-javascript/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>

