<?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>James Revillini &#187; javascript</title>
	<atom:link href="http://james.revillini.com/tag/javascript/feed/" rel="self" type="application/rss+xml" />
	<link>http://james.revillini.com</link>
	<description>Say 'no' to styrofoam.</description>
	<lastBuildDate>Sun, 25 Jul 2010 13:03:39 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0</generator>
		<item>
		<title>Dynamically populate an element styled with white-space: pre</title>
		<link>http://james.revillini.com/2008/01/22/dynamically-populate-an-element-styled-with-white-space-pre/</link>
		<comments>http://james.revillini.com/2008/01/22/dynamically-populate-an-element-styled-with-white-space-pre/#comments</comments>
		<pubDate>Tue, 22 Jan 2008 16:08:08 +0000</pubDate>
		<dc:creator>james</dc:creator>
				<category><![CDATA[web]]></category>
		<category><![CDATA[dhtml]]></category>
		<category><![CDATA[html]]></category>
		<category><![CDATA[javascript]]></category>

		<guid isPermaLink="false">http://james.revillini.com/2008/01/22/dynamically-populate-an-element-styled-with-white-space-pre/</guid>
		<description><![CDATA[Assume: $ = document.getElementById; pre = $('pre-text-element'); //pre-text-element is the ID of my pre tag element You cannot use: $('element').innerHTML = 'line1\nline2'; //will not work in IE7 You must do this: e = $('element'); while(kid=e.firstChild) { e.removeChild(kid) } //remove all children in the e.appendChild('line1\nline2'); Lame, huh?]]></description>
			<content:encoded><![CDATA[<p>Assume:</p>
<pre>$ = document.getElementById;
pre = $('pre-text-element');  //pre-text-element is the ID of my pre tag element</pre>
<p>You cannot use:</p>
<pre>$('element').innerHTML = 'line1\nline2'; //will not work in IE7</pre>
<p>You must do this:</p>
<pre>e = $('element');
while(kid=e.firstChild) { e.removeChild(kid) }  //remove all children in the
e.appendChild('line1\nline2');</pre>
<p>Lame, huh?</p>
]]></content:encoded>
			<wfw:commentRss>http://james.revillini.com/2008/01/22/dynamically-populate-an-element-styled-with-white-space-pre/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Condiments for SWFUpload Initial Release</title>
		<link>http://james.revillini.com/2007/03/28/condiments-for-swfupload-initial-release/</link>
		<comments>http://james.revillini.com/2007/03/28/condiments-for-swfupload-initial-release/#comments</comments>
		<pubDate>Thu, 29 Mar 2007 05:04:40 +0000</pubDate>
		<dc:creator>james</dc:creator>
				<category><![CDATA[web]]></category>
		<category><![CDATA[dhtml]]></category>
		<category><![CDATA[flash]]></category>
		<category><![CDATA[javascript]]></category>
		<category><![CDATA[skin]]></category>
		<category><![CDATA[upload]]></category>

		<guid isPermaLink="false">http://james.revillini.com/2007/03/28/condiments-for-swfupload-initial-release/</guid>
		<description><![CDATA[I have released a kit which aims to make life a little easier for those of you who want to spruce up the SWFUpload interface with some style. An example using the tango desktop project theme:]]></description>
			<content:encoded><![CDATA[<p>I have released <a href="/projects/condiments-for-swfupload">a kit</a> which aims to make life a little easier for those of you who want to spruce up the SWFUpload interface with some style. An example using the tango desktop project theme:</p>
<p><a title="Screenshot of Condiments in action." href="/projects/condiments-for-swfupload"><img src="http://james.revillini.com/wp-content/uploads/2007/03/screenshot-tango.png" alt="Screenshot of Condiments in action." /></a></p>
]]></content:encoded>
			<wfw:commentRss>http://james.revillini.com/2007/03/28/condiments-for-swfupload-initial-release/feed/</wfw:commentRss>
		<slash:comments>7</slash:comments>
		</item>
		<item>
		<title>‘no element found’ in firebug or firefox javascript console (part 2)</title>
		<link>http://james.revillini.com/2006/10/27/%e2%80%98no-element-found%e2%80%99-in-firebug-or-firefox-javascript-console-part-2/</link>
		<comments>http://james.revillini.com/2006/10/27/%e2%80%98no-element-found%e2%80%99-in-firebug-or-firefox-javascript-console-part-2/#comments</comments>
		<pubDate>Fri, 27 Oct 2006 18:18:17 +0000</pubDate>
		<dc:creator>james</dc:creator>
				<category><![CDATA[software]]></category>
		<category><![CDATA[web]]></category>
		<category><![CDATA[bugs]]></category>
		<category><![CDATA[firebug]]></category>
		<category><![CDATA[javascript]]></category>

		<guid isPermaLink="false">http://james.revillini.com/2006/10/27/%e2%80%98no-element-found%e2%80%99-in-firebug-or-firefox-javascript-console-part-2/</guid>
		<description><![CDATA[I was right. If the server sends a response and the &#8216;Content-Type&#8217; attribute is &#8216;text/xml&#8217;, you must send at least a root node so the xml parser that is built into Mozilla&#8217;s XMLHTTPRequest object doesn&#8217;t cak and give you a &#8216;no element found&#8217; Javascript error. This could be an issue for those of us who [...]]]></description>
			<content:encoded><![CDATA[<p>I was right.  If the server sends a response and the &#8216;Content-Type&#8217; attribute is &#8216;text/xml&#8217;, you <em>must</em> send at least a root node so the xml parser that is built into Mozilla&#8217;s XMLHTTPRequest object doesn&#8217;t cak and give you a &#8216;no element found&#8217; Javascript error.</p>
<p>This could be an issue for those of us who are trying to do the REST thing and send back proper status codes depending on the request method and actions taken by the server.  A 204 (Updated) or 205 (Deleted) response cannot, by definition, have any content body, so sending a root node is not an option to get around this error.  The server needs to determine if the response is going to have an xml content body and assign the Content-Type on the fly.</p>
]]></content:encoded>
			<wfw:commentRss>http://james.revillini.com/2006/10/27/%e2%80%98no-element-found%e2%80%99-in-firebug-or-firefox-javascript-console-part-2/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>&#8216;no element found&#8217; in firebug or firefox javascript console</title>
		<link>http://james.revillini.com/2006/10/27/no-element-found-in-firebug-or-firefox-javascript-console/</link>
		<comments>http://james.revillini.com/2006/10/27/no-element-found-in-firebug-or-firefox-javascript-console/#comments</comments>
		<pubDate>Fri, 27 Oct 2006 16:17:42 +0000</pubDate>
		<dc:creator>james</dc:creator>
				<category><![CDATA[software]]></category>
		<category><![CDATA[web]]></category>
		<category><![CDATA[bugs]]></category>
		<category><![CDATA[firebug]]></category>
		<category><![CDATA[javascript]]></category>

		<guid isPermaLink="false">http://james.revillini.com/2006/10/27/no-element-found-in-firebug-or-firefox-javascript-console/</guid>
		<description><![CDATA[I think I figured it out. I think that the issue crops up if your server sends a response header of &#8216;Content-Type&#8217; set to &#8216;text/xml&#8217; and you send no content. The XMLHTTPRequest object then says &#8216;oh it&#8217;s xml? fine &#8211; i&#8217;ll just PARSE THIS and store it in the reponseXML property.&#8217; At that point, the [...]]]></description>
			<content:encoded><![CDATA[<p>I think I figured it out.  I think that the issue crops up if your server sends a response header of &#8216;Content-Type&#8217; set to &#8216;text/xml&#8217; and you send no content.  The XMLHTTPRequest object then says &#8216;oh it&#8217;s xml? fine &#8211; i&#8217;ll just PARSE THIS and store it in the reponseXML property.&#8217;  At that point, the XML Parser probably bombs and nothing catches it.  But anyway that&#8217;s just a hunch and I&#8217;m only blogging about it because I&#8217;m bored.  I&#8217;ll have test results available later.</p>
]]></content:encoded>
			<wfw:commentRss>http://james.revillini.com/2006/10/27/no-element-found-in-firebug-or-firefox-javascript-console/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
	</channel>
</rss>
