<?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>Pakzilla &#187; JavaScript</title>
	<atom:link href="http://www.pakzilla.com/category/porgramming/javascript/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.pakzilla.com</link>
	<description>A developer&#039;s blog!</description>
	<lastBuildDate>Tue, 30 Apr 2013 09:37:16 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.5.1</generator>
		<item>
		<title>How to copy to clipboard in Chrome extension</title>
		<link>http://www.pakzilla.com/2012/03/20/how-to-copy-to-clipboard-in-chrome-extension/</link>
		<comments>http://www.pakzilla.com/2012/03/20/how-to-copy-to-clipboard-in-chrome-extension/#comments</comments>
		<pubDate>Tue, 20 Mar 2012 09:37:48 +0000</pubDate>
		<dc:creator>Tahir Akram</dc:creator>
				<category><![CDATA[JavaScript]]></category>
		<category><![CDATA[Chrome Extensions]]></category>

		<guid isPermaLink="false">http://www.pakzilla.com/?p=1933</guid>
		<description><![CDATA[While developing a Chrome extension you can come up with the situation to copy text to clipboard. I was searching over internet since I found following code snippet. It works like a charm.<div class='yarpp-related-rss'>

Related posts:<ol>
<li><a href='http://www.pakzilla.com/2012/01/01/a-reference-to-html-5-tags/' rel='bookmark' title='A reference to HTML5 tags'>A reference to HTML5 tags</a></li>
<li><a href='http://www.pakzilla.com/2012/03/20/evaluating-leaflet-js-as-alternative-of-google-maps/' rel='bookmark' title='Evaluating Leaflet JS as alternative of Google Maps'>Evaluating Leaflet JS as alternative of Google Maps</a></li>
<li><a href='http://www.pakzilla.com/2007/04/08/accessing-a-selected-row-from-hdatatable/' rel='bookmark' title='Accessing a selected row from h:dataTable'>Accessing a selected row from h:dataTable</a></li>
</ol>
</div>
]]></description>
				<content:encoded><![CDATA[<p>While developing a Chrome extension you can come up with the situation to copy text to clipboard. I was searching over internet since I found following code snippet. It works like a charm. </p>
<pre class="brush: jscript; title: ; notranslate">
function copyToClipboard( text ){
			  	var copyDiv = document.createElement('div');
				copyDiv.contentEditable = true;
				document.body.appendChild(copyDiv);
				copyDiv.innerHTML = text;
				copyDiv.unselectable = &quot;off&quot;;
				copyDiv.focus();
				document.execCommand('SelectAll');
				document.execCommand(&quot;Copy&quot;, false, null);
				document.body.removeChild(copyDiv);
			}
</pre>
<div class='yarpp-related-rss'>
<p>Related posts:<ol>
<li><a href='http://www.pakzilla.com/2012/01/01/a-reference-to-html-5-tags/' rel='bookmark' title='A reference to HTML5 tags'>A reference to HTML5 tags</a></li>
<li><a href='http://www.pakzilla.com/2012/03/20/evaluating-leaflet-js-as-alternative-of-google-maps/' rel='bookmark' title='Evaluating Leaflet JS as alternative of Google Maps'>Evaluating Leaflet JS as alternative of Google Maps</a></li>
<li><a href='http://www.pakzilla.com/2007/04/08/accessing-a-selected-row-from-hdatatable/' rel='bookmark' title='Accessing a selected row from h:dataTable'>Accessing a selected row from h:dataTable</a></li>
</ol></p>
</div>
]]></content:encoded>
			<wfw:commentRss>http://www.pakzilla.com/2012/03/20/how-to-copy-to-clipboard-in-chrome-extension/feed/</wfw:commentRss>
		<slash:comments>6</slash:comments>
		</item>
	</channel>
</rss>
