<?xml version="1.0" encoding="ISO-8859-1"?>
<?xml-stylesheet type="text/xsl" media="screen" href="/~d/styles/rss2full.xsl"?><?xml-stylesheet type="text/css" media="screen" href="http://feeds.feedburner.com/~d/styles/itemcontent.css"?><rss xmlns:feedburner="http://rssnamespace.org/feedburner/ext/1.0" version="2.0">
  <channel>
    <title>CodeKeep JavaScript Feed</title>
    <description>The latest and greatest JavaScript code snippets publicly available</description>
    <link>http://www.codekeep.net/feeds.aspx</link>
    <lastBuildDate>Mon, 21 Jan 2013 13:24:07 GMT</lastBuildDate>
    <docs>http://backend.userland.com/rss</docs>
    <generator>RSS.NET: http://www.rssdotnet.com/</generator>
    <atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="self" type="application/rss+xml" href="http://feeds.feedburner.com/CodeKeepJavaScript" /><feedburner:info uri="codekeepjavascript" /><atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="hub" href="http://pubsubhubbub.appspot.com/" /><item>
      <title>JavaScript Popup Window with content</title>
      <description>Description: JavaScript Popup Window with content using DIV&lt;br /&gt;&lt;br /&gt;Link: &lt;a href='http://www.codekeep.net/snippets/80573aab-9f61-4053-a053-b929884f5401.aspx'&gt;http://www.codekeep.net/snippets/80573aab-9f61-4053-a053-b929884f5401.aspx&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;pre style='font-size: 9pt;'&gt;&amp;lt;script type=&amp;quot;text/javascript&amp;quot;&amp;gt;
var popup2 = new Popup();
popup2.autoHide = false;
popup2.content = 'This DIV will not close automatically!&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&amp;lt;a href=&amp;quot;#&amp;quot; onclick=&amp;quot;'+popup2.ref+'.hide();return false;&amp;quot;&amp;gt;Click here to close&amp;lt;/a&amp;gt;';
popup2.width=200;
popup2.height=200;
popup2.style = {'border':'3px solid black','backgroundColor':'yellow'};
&amp;lt;/script&amp;gt;

&amp;lt;a href=&amp;quot;#&amp;quot; onclick=&amp;quot;popup2.show();return false;&amp;quot;&amp;gt;Click Here To Show Popup Object&amp;lt;/a&amp;gt;
&lt;/pre&gt;&lt;img src="http://feeds.feedburner.com/~r/CodeKeepJavaScript/~4/dPzLkCvdpro" height="1" width="1"/&gt;</description>
      <link>http://feedproxy.google.com/~r/CodeKeepJavaScript/~3/dPzLkCvdpro/80573aab-9f61-4053-a053-b929884f5401.aspx</link>
      <pubDate>Mon, 21 Jan 2013 13:24:07 GMT</pubDate>
    <feedburner:origLink>http://www.codekeep.net/snippets/80573aab-9f61-4053-a053-b929884f5401.aspx</feedburner:origLink></item>
    <item>
      <title>Array push / pop example</title>
      <description>Description: Array push / pop example&lt;br /&gt;&lt;br /&gt;Link: &lt;a href='http://www.codekeep.net/snippets/18e8dbc1-0765-48ab-8b3b-5c4660ab4f6f.aspx'&gt;http://www.codekeep.net/snippets/18e8dbc1-0765-48ab-8b3b-5c4660ab4f6f.aspx&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;pre style='font-size: 9pt;'&gt;var mack = [&amp;quot;Mack&amp;quot;]
mack.push(&amp;quot;the&amp;quot;)
mack.push(&amp;quot;Knife&amp;quot;)
show(mack)
show(&amp;quot;after poping last val&amp;quot;)
mack.pop()
show(mack)&lt;/pre&gt;&lt;img src="http://feeds.feedburner.com/~r/CodeKeepJavaScript/~4/uhSQNq_oCII" height="1" width="1"/&gt;</description>
      <link>http://feedproxy.google.com/~r/CodeKeepJavaScript/~3/uhSQNq_oCII/18e8dbc1-0765-48ab-8b3b-5c4660ab4f6f.aspx</link>
      <pubDate>Fri, 04 Jan 2013 03:41:04 GMT</pubDate>
    <feedburner:origLink>http://www.codekeep.net/snippets/18e8dbc1-0765-48ab-8b3b-5c4660ab4f6f.aspx</feedburner:origLink></item>
    <item>
      <title>String.slice</title>
      <description>Description: slice is used to get a substring from a string &lt;br /&gt;&lt;br /&gt;Link: &lt;a href='http://www.codekeep.net/snippets/a31ed81a-3aaf-4e86-b8c7-9a775075b801.aspx'&gt;http://www.codekeep.net/snippets/a31ed81a-3aaf-4e86-b8c7-9a775075b801.aspx&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;pre style='font-size: 9pt;'&gt;function startsWith(string, pattern) {
  return string.slice(0, pattern.length) == pattern;
}

show(startsWith(&amp;quot;rotation&amp;quot;, &amp;quot;rot&amp;quot;));&lt;/pre&gt;&lt;img src="http://feeds.feedburner.com/~r/CodeKeepJavaScript/~4/PJ971kP8jeA" height="1" width="1"/&gt;</description>
      <link>http://feedproxy.google.com/~r/CodeKeepJavaScript/~3/PJ971kP8jeA/a31ed81a-3aaf-4e86-b8c7-9a775075b801.aspx</link>
      <pubDate>Fri, 04 Jan 2013 03:38:05 GMT</pubDate>
    <feedburner:origLink>http://www.codekeep.net/snippets/a31ed81a-3aaf-4e86-b8c7-9a775075b801.aspx</feedburner:origLink></item>
    <item>
      <title> Watch Box Office Movies Streaming THIS IS 40 without downloading </title>
      <description>Description: Watch online movie THIS IS 40 full HD quality Genre(s): Comedy Run Time: 134min Release Date: 12/21/2012 Distributor(s): &lt;br /&gt;&lt;br /&gt;Link: &lt;a href='http://www.codekeep.net/snippets/d8278ebf-d7da-4a99-bb3b-c8f70bcbd3ad.aspx'&gt;http://www.codekeep.net/snippets/d8278ebf-d7da-4a99-bb3b-c8f70bcbd3ad.aspx&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;pre style='font-size: 9pt;'&gt;Download THIS IS 40 movie online, watch THIS IS 40 free movie, download 2012 movie THIS IS 40, free film THIS IS 40, Watch THIS IS 40 online movie, Watch 2012 latest movie THIS IS 40, download THIS IS 40 movie, free online THIS IS 40 movie to download, THIS IS 40 film download, THIS IS 40 movie download, free movie THIS IS 40, watch film THIS IS 40, watch THIS IS 40 movie online, stream download THIS IS 40 movie 2012, free online THIS IS 40 movie full length, free full length THIS IS 40 movie online, Watch THIS IS 40 movie without downloading, download THIS IS 40 movie full in all formats quality, download THIS IS 40 movie full in HD DVD DiVx IPOD quality, watch tv, tv shows, tv series, free online Watch THIS IS 40 movie full length, free full length download THIS IS 40 movie online
&lt;/pre&gt;&lt;img src="http://feeds.feedburner.com/~r/CodeKeepJavaScript/~4/yUkB2QyQZEA" height="1" width="1"/&gt;</description>
      <link>http://feedproxy.google.com/~r/CodeKeepJavaScript/~3/yUkB2QyQZEA/d8278ebf-d7da-4a99-bb3b-c8f70bcbd3ad.aspx</link>
      <pubDate>Tue, 01 Jan 2013 03:32:04 GMT</pubDate>
    <feedburner:origLink>http://www.codekeep.net/snippets/d8278ebf-d7da-4a99-bb3b-c8f70bcbd3ad.aspx</feedburner:origLink></item>
    <item>
      <title>Email Validation in JavaScript</title>
      <description>Description: One of the important things about user input is to verify that the user has supplied the email that you have requested. The function below allows you to verify email address with easy. &lt;br /&gt;&lt;br /&gt;Link: &lt;a href='http://www.codekeep.net/snippets/b1028cde-aa4e-4774-b194-d3c2e151fece.aspx'&gt;http://www.codekeep.net/snippets/b1028cde-aa4e-4774-b194-d3c2e151fece.aspx&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;pre style='font-size: 9pt;'&gt;    &amp;lt;script type=&amp;quot;text/javascript&amp;quot;&amp;gt;  
    function check_email(email){  
        var reg = /^([a-zA-Z0-9_\.\-])+\@(([a-zA-Z0-9\-])+\.)+([a-zA-Z0-9]{2,4})+$/;
        if(reg.test(email)){
            return true;
        }else{  
            return false;
        }  
    }  
    &amp;lt;/script&amp;gt;  
     
    &amp;lt;input type=&amp;quot;text&amp;quot; id=&amp;quot;email&amp;quot;&amp;gt;
    &amp;lt;button onclick=&amp;quot;alert(check_email(document.getElementById('email').value))&amp;quot;&amp;gt;Validate&amp;lt;/button&amp;gt;
&lt;/pre&gt;&lt;img src="http://feeds.feedburner.com/~r/CodeKeepJavaScript/~4/GH9Rqzb2njY" height="1" width="1"/&gt;</description>
      <link>http://feedproxy.google.com/~r/CodeKeepJavaScript/~3/GH9Rqzb2njY/b1028cde-aa4e-4774-b194-d3c2e151fece.aspx</link>
      <pubDate>Sun, 11 Nov 2012 15:32:27 GMT</pubDate>
    <feedburner:origLink>http://www.codekeep.net/snippets/b1028cde-aa4e-4774-b194-d3c2e151fece.aspx</feedburner:origLink></item>
    <item>
      <title>Toggling Elements with JavaScript</title>
      <description>Description: This function allows you to pass two variables that represent ID of two elements on your page. What you click on one of them it hide it and shows another one. &lt;br /&gt;&lt;br /&gt;Link: &lt;a href='http://www.codekeep.net/snippets/52bbc79b-242e-4baa-a384-86f8ba76c5c7.aspx'&gt;http://www.codekeep.net/snippets/52bbc79b-242e-4baa-a384-86f8ba76c5c7.aspx&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;pre style='font-size: 9pt;'&gt;    &amp;lt;script type=&amp;quot;text/javascript&amp;quot;&amp;gt;
    function toggle(id, id2){  
        var toggle_one = document.getElementById(id);  
        var toggle_two = document.getElementById(id2);  
        if(toggle_one.style.display == &amp;quot;block&amp;quot;){  
            toggle_one.style.display = &amp;quot;none&amp;quot;;  
            toggle_two.innerHTML = &amp;quot;Show&amp;quot;;  
        }else{  
            toggle_one.style.display = &amp;quot;block&amp;quot;;  
            toggle_two.innerHTML = &amp;quot;Hide&amp;quot;;  
        }  
    }
    &amp;lt;/script&amp;gt;
     
    &amp;lt;a href=&amp;quot;#&amp;quot; id=&amp;quot;tlink&amp;quot; onclick=&amp;quot;toggle('comments', 'tlink');&amp;quot;&amp;gt;Show&amp;lt;/a&amp;gt; Comments&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;  
    &amp;lt;div id=&amp;quot;comments&amp;quot; style=&amp;quot;display:none;padding 10px;&amp;quot;&amp;gt;Now you can see the comments&amp;lt;/div&amp;gt;
&lt;/pre&gt;&lt;img src="http://feeds.feedburner.com/~r/CodeKeepJavaScript/~4/3TVsL6B77eI" height="1" width="1"/&gt;</description>
      <link>http://feedproxy.google.com/~r/CodeKeepJavaScript/~3/3TVsL6B77eI/52bbc79b-242e-4baa-a384-86f8ba76c5c7.aspx</link>
      <pubDate>Sun, 11 Nov 2012 15:30:08 GMT</pubDate>
    <feedburner:origLink>http://www.codekeep.net/snippets/52bbc79b-242e-4baa-a384-86f8ba76c5c7.aspx</feedburner:origLink></item>
    <item>
      <title>jQuery Ajax</title>
      <description>Description: Simple json ajax template&lt;br /&gt;&lt;br /&gt;Link: &lt;a href='http://www.codekeep.net/snippets/590ad866-cb1a-4af9-9931-e354fab1b8b0.aspx'&gt;http://www.codekeep.net/snippets/590ad866-cb1a-4af9-9931-e354fab1b8b0.aspx&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;pre style='font-size: 9pt;'&gt;        $.ajax({
            url: 'your/url',
            type: 'POST', // default is GET
            contentType: 'application/json; charset=utf-8;',
            data: yourData,
            dataType: 'json',
            success: function (msg) {
            },
            failure: function(){
            }
        });&lt;/pre&gt;&lt;img src="http://feeds.feedburner.com/~r/CodeKeepJavaScript/~4/00qAUznoWyQ" height="1" width="1"/&gt;</description>
      <link>http://feedproxy.google.com/~r/CodeKeepJavaScript/~3/00qAUznoWyQ/590ad866-cb1a-4af9-9931-e354fab1b8b0.aspx</link>
      <pubDate>Fri, 02 Nov 2012 08:51:55 GMT</pubDate>
    <feedburner:origLink>http://www.codekeep.net/snippets/590ad866-cb1a-4af9-9931-e354fab1b8b0.aspx</feedburner:origLink></item>
    <item>
      <title>test</title>
      <description>Description: test&lt;br /&gt;&lt;br /&gt;Link: &lt;a href='http://www.codekeep.net/snippets/afc42330-fda4-4983-b782-317bf36f6323.aspx'&gt;http://www.codekeep.net/snippets/afc42330-fda4-4983-b782-317bf36f6323.aspx&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;pre style='font-size: 9pt;'&gt;function test() {
    alert('test');
}&lt;/pre&gt;&lt;img src="http://feeds.feedburner.com/~r/CodeKeepJavaScript/~4/dWPuNmrYDqw" height="1" width="1"/&gt;</description>
      <link>http://feedproxy.google.com/~r/CodeKeepJavaScript/~3/dWPuNmrYDqw/afc42330-fda4-4983-b782-317bf36f6323.aspx</link>
      <pubDate>Fri, 20 Jul 2012 07:55:54 GMT</pubDate>
    <feedburner:origLink>http://www.codekeep.net/snippets/afc42330-fda4-4983-b782-317bf36f6323.aspx</feedburner:origLink></item>
    <item>
      <title>jQuery CDN fallback</title>
      <description>Description: When the CDN provider is unavailable fall back to local copy&lt;br /&gt;&lt;br /&gt;Link: &lt;a href='http://www.codekeep.net/snippets/01952159-273f-4fde-b49a-f9ca5c1a70b0.aspx'&gt;http://www.codekeep.net/snippets/01952159-273f-4fde-b49a-f9ca5c1a70b0.aspx&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;pre style='font-size: 9pt;'&gt;if (typeof jQuery == 'undefined') {
    document.write(unescape(&amp;quot;%C3script type='text/javascript' src='/Scripts/jquery-1.7.1.min.js'%3E%3C/script%3E&amp;quot;));
}&lt;/pre&gt;&lt;img src="http://feeds.feedburner.com/~r/CodeKeepJavaScript/~4/OdsCGD3aPNo" height="1" width="1"/&gt;</description>
      <link>http://feedproxy.google.com/~r/CodeKeepJavaScript/~3/OdsCGD3aPNo/01952159-273f-4fde-b49a-f9ca5c1a70b0.aspx</link>
      <pubDate>Thu, 19 Jul 2012 03:33:40 GMT</pubDate>
    <feedburner:origLink>http://www.codekeep.net/snippets/01952159-273f-4fde-b49a-f9ca5c1a70b0.aspx</feedburner:origLink></item>
    <item>
      <title>Birthday Generator - Javascript</title>
      <description>Description: This simple script will generate birthday day/month/year. All the data is stored into variable which could be used wherever you want.&lt;br /&gt;&lt;br /&gt;Link: &lt;a href='http://www.codekeep.net/snippets/b191cb8c-62f0-4951-b326-6ce929504f44.aspx'&gt;http://www.codekeep.net/snippets/b191cb8c-62f0-4951-b326-6ce929504f44.aspx&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;pre style='font-size: 9pt;'&gt;//************************************************************
// Generates Birthday Day/Month/Year                         *
// There's no check for the day/month relationship,          *
// so the birthday can't be 29,39,31                         *
// to prevent nonsense like 31.02 (February 31th)            *
//************************************************************
function bnum (min, max) {
    return Math.floor(Math.random() * (max - min + 1)) + min;
}
var bday=bnum(1,29)
var bmonth=bnum(1,12)
var byear=bnum(1980, 1995)
alert(bday);
alert(bmonth);
alert(byear);&lt;/pre&gt;&lt;img src="http://feeds.feedburner.com/~r/CodeKeepJavaScript/~4/0p7Xix0DEz8" height="1" width="1"/&gt;</description>
      <link>http://feedproxy.google.com/~r/CodeKeepJavaScript/~3/0p7Xix0DEz8/b191cb8c-62f0-4951-b326-6ce929504f44.aspx</link>
      <pubDate>Sat, 16 Jun 2012 00:08:10 GMT</pubDate>
    <feedburner:origLink>http://www.codekeep.net/snippets/b191cb8c-62f0-4951-b326-6ce929504f44.aspx</feedburner:origLink></item>
    <item>
      <title>Create Add to Favorites/Bookmark button in Javascript</title>
      <description>Description: Most today's web browsers like Firefox (Ctrl+D), Opera (Ctrl+T) and IE (Ctrl+D) provide a keyboard shortcuts to enable users bookmark their favorite pages. But if you want to provide your visitors with a "Bookmark this page" link.&lt;br /&gt;&lt;br /&gt;Link: &lt;a href='http://www.codekeep.net/snippets/7a7c72a6-741e-4cba-bd92-dc75c68ce85b.aspx'&gt;http://www.codekeep.net/snippets/7a7c72a6-741e-4cba-bd92-dc75c68ce85b.aspx&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;pre style='font-size: 9pt;'&gt;&amp;lt;script type=&amp;quot;text/javascript&amp;quot;&amp;gt;
    function CreateBookmarkLink(){
        var title = document.title;
        var url = document.location.href;
     
        if(window.sidebar){
            /* Mozilla Firefox Bookmark */
            window.sidebar.addPanel(title, url, &amp;quot;&amp;quot;);
        }else if(window.external){
            /* IE Favorite */
            window.external.AddFavorite(url, title);
        }else if(window.opera &amp;amp;&amp;amp; window.print) {
            /* Opera Hotlist */
            alert(&amp;quot;Press Control + D to bookmark&amp;quot;);
            return true;
        }else{
            /* Other */
            alert(&amp;quot;Press Control + D to bookmark&amp;quot;);
        }
    }
    &amp;lt;/script&amp;gt;
     
    &amp;lt;a href=&amp;quot;javascript:CreateBookmarkLink();&amp;quot;&amp;gt;Add to Favorites/Bookmark&amp;lt;/a&amp;gt;
&lt;/pre&gt;&lt;img src="http://feeds.feedburner.com/~r/CodeKeepJavaScript/~4/Grzi26ihwws" height="1" width="1"/&gt;</description>
      <link>http://feedproxy.google.com/~r/CodeKeepJavaScript/~3/Grzi26ihwws/7a7c72a6-741e-4cba-bd92-dc75c68ce85b.aspx</link>
      <pubDate>Fri, 08 Jun 2012 07:52:00 GMT</pubDate>
    <feedburner:origLink>http://www.codekeep.net/snippets/7a7c72a6-741e-4cba-bd92-dc75c68ce85b.aspx</feedburner:origLink></item>
    <item>
      <title>Redirect with a Timer</title>
      <description>Description: You can use JavaScript window.location to redirect a visitor to a required page. You may have seen this feature used by sites with full page ads, or to redirect visitors to the site's new domain name. &lt;br /&gt;&lt;br /&gt;Link: &lt;a href='http://www.codekeep.net/snippets/b70fdb7e-136d-45e4-b501-6d61913f31c8.aspx'&gt;http://www.codekeep.net/snippets/b70fdb7e-136d-45e4-b501-6d61913f31c8.aspx&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;pre style='font-size: 9pt;'&gt;&amp;lt;script type=&amp;quot;text/javascript&amp;quot;&amp;gt;
    var count = 6;
    var redirect = &amp;quot;http://www.apphp.com&amp;quot;;
     
    function countDown(){
        var timer = document.getElementById(&amp;quot;timer&amp;quot;);
        if(count &amp;gt; 0){
            count--;
            timer.innerHTML = &amp;quot;This page will redirect in &amp;quot;+count+&amp;quot; seconds.&amp;quot;;
            setTimeout(&amp;quot;countDown()&amp;quot;, 1000);
        }else{
            window.location.href = redirect;
        }
    }
    &amp;lt;/script&amp;gt;
     
    Our webpage has beed moved. Please update your bookmarks for the new site.
    &amp;lt;br&amp;gt;
     
    &amp;lt;span id=&amp;quot;timer&amp;quot;&amp;gt;
    &amp;lt;script type=&amp;quot;text/javascript&amp;quot;&amp;gt;countDown();&amp;lt;/script&amp;gt;
    &amp;lt;/span&amp;gt;
&lt;/pre&gt;&lt;img src="http://feeds.feedburner.com/~r/CodeKeepJavaScript/~4/Jttney22UMs" height="1" width="1"/&gt;</description>
      <link>http://feedproxy.google.com/~r/CodeKeepJavaScript/~3/Jttney22UMs/b70fdb7e-136d-45e4-b501-6d61913f31c8.aspx</link>
      <pubDate>Fri, 08 Jun 2012 07:50:52 GMT</pubDate>
    <feedburner:origLink>http://www.codekeep.net/snippets/b70fdb7e-136d-45e4-b501-6d61913f31c8.aspx</feedburner:origLink></item>
    <item>
      <title>Copy Selected Text in JavaScript</title>
      <description>Description: Sometimes you have some information on your page and your visitors might want to copy it. The easiest way is to provide a mechanism that allows them to simply click a button to do so. You have to paste this code into the head of your web page:&lt;br /&gt;&lt;br /&gt;Link: &lt;a href='http://www.codekeep.net/snippets/4fc9306a-649e-4bec-83d0-52ed8157ee26.aspx'&gt;http://www.codekeep.net/snippets/4fc9306a-649e-4bec-83d0-52ed8157ee26.aspx&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;pre style='font-size: 9pt;'&gt;&amp;lt;script language=&amp;quot;javascript&amp;quot;&amp;gt;
    function CopyText(el){
        var selectedText = &amp;quot;&amp;quot;;
        if(window.getSelection){
            selectedText = window.getSelection();
        }else if (document.getSelection){
            selectedText = document.getSelection();
        }else if (document.selection){
            selectedText = document.selection.createRange().text;
        }
        if(selectedText != &amp;quot;&amp;quot;){
            selectedText = selectedText.toString();
            el.focus();
            el.value = selectedText;
            }else {
            alert(&amp;quot;Select a text in the page and then press this button!&amp;quot;);
        }
    }
    &amp;lt;/script&amp;gt;
     
    Select any part of this text to copy it...
    &amp;lt;form name=&amp;quot;frmCopyText&amp;quot;&amp;gt;
    &amp;lt;textarea name=&amp;quot;txtSelect&amp;quot; rows=&amp;quot;4&amp;quot; cols=&amp;quot;45&amp;quot;&amp;gt;&amp;lt;/textarea&amp;gt;&amp;lt;br&amp;gt;
    &amp;lt;input onclick=&amp;quot;CopyText(this.form.txtSelect)&amp;quot;
           type=&amp;quot;button&amp;quot;
           value=&amp;quot;Press to copy the highlighted text&amp;quot;
           name=&amp;quot;btnCopy&amp;quot;&amp;gt;
    &amp;lt;/form&amp;gt;
&lt;/pre&gt;&lt;img src="http://feeds.feedburner.com/~r/CodeKeepJavaScript/~4/u0Ppz0rcIlU" height="1" width="1"/&gt;</description>
      <link>http://feedproxy.google.com/~r/CodeKeepJavaScript/~3/u0Ppz0rcIlU/4fc9306a-649e-4bec-83d0-52ed8157ee26.aspx</link>
      <pubDate>Fri, 08 Jun 2012 07:49:13 GMT</pubDate>
    <feedburner:origLink>http://www.codekeep.net/snippets/4fc9306a-649e-4bec-83d0-52ed8157ee26.aspx</feedburner:origLink></item>
    <item>
      <title>Create Back Button with JavaScript</title>
      <description>Description: You may create a back button like your browser has. The following script allows the visitor to press a button and returns the him to the previous page. &lt;br /&gt;&lt;br /&gt;Link: &lt;a href='http://www.codekeep.net/snippets/9ad7e53b-5cdb-433d-a763-c502845a7e28.aspx'&gt;http://www.codekeep.net/snippets/9ad7e53b-5cdb-433d-a763-c502845a7e28.aspx&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;pre style='font-size: 9pt;'&gt;&amp;lt;form&amp;gt;
    &amp;lt;input type=&amp;quot;button&amp;quot; value=&amp;quot;Previous Page&amp;quot; onclick=&amp;quot;history.go(-1)&amp;quot;&amp;gt;
    &amp;lt;/form&amp;gt;
&lt;/pre&gt;&lt;img src="http://feeds.feedburner.com/~r/CodeKeepJavaScript/~4/szUcDi8Cm5g" height="1" width="1"/&gt;</description>
      <link>http://feedproxy.google.com/~r/CodeKeepJavaScript/~3/szUcDi8Cm5g/9ad7e53b-5cdb-433d-a763-c502845a7e28.aspx</link>
      <pubDate>Fri, 08 Jun 2012 07:48:23 GMT</pubDate>
    <feedburner:origLink>http://www.codekeep.net/snippets/9ad7e53b-5cdb-433d-a763-c502845a7e28.aspx</feedburner:origLink></item>
    <item>
      <title>jQuery UI queue effects</title>
      <description>Description: Queue effects on a selector&lt;br /&gt;&lt;br /&gt;Link: &lt;a href='http://www.codekeep.net/snippets/72c7efb6-4918-46a3-a68a-2e5deed526a9.aspx'&gt;http://www.codekeep.net/snippets/72c7efb6-4918-46a3-a68a-2e5deed526a9.aspx&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;pre style='font-size: 9pt;'&gt;var s = $(&amp;quot;#selector&amp;quot;);

i.queue(&amp;quot;q&amp;quot;, function (next) {
    $(this).effect(&amp;quot;shake&amp;quot;);
    next(); // Dequeue next
});

i.delay(1000, &amp;quot;q&amp;quot;); // Add a delay between effects

i.queue(&amp;quot;q&amp;quot;, function () {
    $(this).effect(&amp;quot;pulsate&amp;quot;, { times: 8, mode: &amp;quot;show&amp;quot; }, 150);
    next(); // Dequeue next
});

i.dequeue(&amp;quot;q&amp;quot;); // Start&lt;/pre&gt;&lt;img src="http://feeds.feedburner.com/~r/CodeKeepJavaScript/~4/5E0MhTFE5x0" height="1" width="1"/&gt;</description>
      <link>http://feedproxy.google.com/~r/CodeKeepJavaScript/~3/5E0MhTFE5x0/72c7efb6-4918-46a3-a68a-2e5deed526a9.aspx</link>
      <pubDate>Fri, 01 Jun 2012 06:58:36 GMT</pubDate>
    <feedburner:origLink>http://www.codekeep.net/snippets/72c7efb6-4918-46a3-a68a-2e5deed526a9.aspx</feedburner:origLink></item>
    <item>
      <title>console</title>
      <description>Description: test&lt;br /&gt;&lt;br /&gt;Link: &lt;a href='http://www.codekeep.net/snippets/46166b69-e6ca-456a-8fce-296d7d04adf4.aspx'&gt;http://www.codekeep.net/snippets/46166b69-e6ca-456a-8fce-296d7d04adf4.aspx&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;pre style='font-size: 9pt;'&gt;console.log('hello world')&lt;/pre&gt;&lt;img src="http://feeds.feedburner.com/~r/CodeKeepJavaScript/~4/_v7XhCR84DE" height="1" width="1"/&gt;</description>
      <link>http://feedproxy.google.com/~r/CodeKeepJavaScript/~3/_v7XhCR84DE/46166b69-e6ca-456a-8fce-296d7d04adf4.aspx</link>
      <pubDate>Fri, 27 Apr 2012 08:32:46 GMT</pubDate>
    <feedburner:origLink>http://www.codekeep.net/snippets/46166b69-e6ca-456a-8fce-296d7d04adf4.aspx</feedburner:origLink></item>
    <item>
      <title>Cross browser attach event</title>
      <description>Description: Cross browser attach event&lt;br /&gt;&lt;br /&gt;Link: &lt;a href='http://www.codekeep.net/snippets/45abacd7-7510-486e-bf69-32a3f1b71d4f.aspx'&gt;http://www.codekeep.net/snippets/45abacd7-7510-486e-bf69-32a3f1b71d4f.aspx&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;pre style='font-size: 9pt;'&gt;function XBrowserAddHandler(target, eventName, handlerName) {
    if (target.addEventListener)
        target.addEventListener(eventName, handlerName, false);
    else if (target.attachEvent)
        target.attachEvent(eventName, handlerName);
    else
        target[&amp;quot;on&amp;quot; + eventName] = handlerName;
}

&lt;/pre&gt;&lt;img src="http://feeds.feedburner.com/~r/CodeKeepJavaScript/~4/CCo7GGRvaRQ" height="1" width="1"/&gt;</description>
      <link>http://feedproxy.google.com/~r/CodeKeepJavaScript/~3/CCo7GGRvaRQ/45abacd7-7510-486e-bf69-32a3f1b71d4f.aspx</link>
      <pubDate>Wed, 11 Apr 2012 11:01:21 GMT</pubDate>
    <feedburner:origLink>http://www.codekeep.net/snippets/45abacd7-7510-486e-bf69-32a3f1b71d4f.aspx</feedburner:origLink></item>
    <item>
      <title>jQuery Tooltip</title>
      <description>Description: Jquery tooltip &lt;br /&gt;&lt;br /&gt;Link: &lt;a href='http://www.codekeep.net/snippets/88ae9dd1-c513-4f95-b1ee-7b8bee43c793.aspx'&gt;http://www.codekeep.net/snippets/88ae9dd1-c513-4f95-b1ee-7b8bee43c793.aspx&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;pre style='font-size: 9pt;'&gt;$(document).ready(function () {
       //Tooltips
       $(&amp;quot;.tip_trigger&amp;quot;).hover(function () {
           tip = $(this).find('.tip');
           tip.show(); //Show tooltip
       }, function () {
           tip.hide(); //Hide tooltip
       }).mousemove(function (e) {
           var mousex = e.pageX + 20; //Get X coodrinates
           var mousey = e.pageY + 20; //Get Y coordinates
           var tipWidth = tip.width(); //Find width of tooltip
           var tipHeight = tip.height(); //Find height of tooltip

           //Distance of element from the right edge of viewport
           var tipVisX = $(window).width() - (mousex + tipWidth);
           //Distance of element from the bottom of viewport
           var tipVisY = $(window).height() - (mousey + tipHeight);

           if (tipVisX &amp;lt; 20) { //If tooltip exceeds the X coordinate
of viewport
               mousex = e.pageX - tipWidth - 20;
           } if (tipVisY &amp;lt; 20) { //If tooltip exceeds the Y
coordinate of viewport
               mousey = e.pageY - tipHeight - 20;
           }
           tip.css({ top: mousey, left: mousex });
       });
   });


&amp;lt;style type=&amp;quot;text/css&amp;quot;&amp;gt;

img {border: none;}
h1 {
   font: 4em normal Georgia, 'Times New Roman', Times, serif;
   padding: 10px 0;
   color: #aaa;
   text-align: center;
}
h1 span { color: #666; }
h1 small{
   font: 0.3em normal Verdana, Arial, Helvetica, sans-serif;
   text-transform:uppercase;
   letter-spacing: 0.65em;
   display: block;
   color: #666;
}
h1 a {text-decoration: none;}
a {color: #d60000; text-decoration: none;}

 
.tip {
   color: #fff;
   background:#1d1d1d;
   display:none;  
   padding:10px;
   position:absolute;  z-index:1000;
   -webkit-border-radius: 3px;
   -moz-border-radius: 3px;
   border-radius: 3px;
}
 
&amp;lt;/style&amp;gt;&lt;/pre&gt;&lt;img src="http://feeds.feedburner.com/~r/CodeKeepJavaScript/~4/yr_r4MtLhss" height="1" width="1"/&gt;</description>
      <link>http://feedproxy.google.com/~r/CodeKeepJavaScript/~3/yr_r4MtLhss/88ae9dd1-c513-4f95-b1ee-7b8bee43c793.aspx</link>
      <pubDate>Fri, 16 Mar 2012 13:44:19 GMT</pubDate>
    <feedburner:origLink>http://www.codekeep.net/snippets/88ae9dd1-c513-4f95-b1ee-7b8bee43c793.aspx</feedburner:origLink></item>
    <item>
      <title>Add String.trim extension method</title>
      <description>Description: if the String class does not have a trim function in the current browser, add it.&lt;br /&gt;&lt;br /&gt;Link: &lt;a href='http://www.codekeep.net/snippets/809b6691-ec7b-48df-b813-e2fcc6b5da41.aspx'&gt;http://www.codekeep.net/snippets/809b6691-ec7b-48df-b813-e2fcc6b5da41.aspx&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;pre style='font-size: 9pt;'&gt;// if trim is not already defined add it
if (typeof &amp;quot;test&amp;quot;.trim != 'function') {
    //javascript extenstion method
    String.prototype.trim = function () { // this trim was suggested by Tobias Hinnerup
        return (this.replace(/^\s+/, '').replace(/\s+$/, ''));
    }
}&lt;/pre&gt;&lt;img src="http://feeds.feedburner.com/~r/CodeKeepJavaScript/~4/_mSiX7zXpAM" height="1" width="1"/&gt;</description>
      <link>http://feedproxy.google.com/~r/CodeKeepJavaScript/~3/_mSiX7zXpAM/809b6691-ec7b-48df-b813-e2fcc6b5da41.aspx</link>
      <pubDate>Thu, 05 Jan 2012 08:33:33 GMT</pubDate>
    <feedburner:origLink>http://www.codekeep.net/snippets/809b6691-ec7b-48df-b813-e2fcc6b5da41.aspx</feedburner:origLink></item>
    <item>
      <title>scroll to bottom in html</title>
      <description>Description: scroll to bottom of a list, panel, etc.
sencha touch, extjs, etc.&lt;br /&gt;&lt;br /&gt;Link: &lt;a href='http://www.codekeep.net/snippets/15962097-5ffc-43bc-b1e7-0b5dd50ae4b6.aspx'&gt;http://www.codekeep.net/snippets/15962097-5ffc-43bc-b1e7-0b5dd50ae4b6.aspx&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;pre style='font-size: 9pt;'&gt;var el = list.getEl();
el.dom.scrollTop = el.dom.scrollHeight;
&lt;/pre&gt;&lt;img src="http://feeds.feedburner.com/~r/CodeKeepJavaScript/~4/kktvM6xTIZU" height="1" width="1"/&gt;</description>
      <link>http://feedproxy.google.com/~r/CodeKeepJavaScript/~3/kktvM6xTIZU/15962097-5ffc-43bc-b1e7-0b5dd50ae4b6.aspx</link>
      <pubDate>Tue, 29 Nov 2011 08:08:14 GMT</pubDate>
    <feedburner:origLink>http://www.codekeep.net/snippets/15962097-5ffc-43bc-b1e7-0b5dd50ae4b6.aspx</feedburner:origLink></item>
    <item>
      <title>Show Hide table data</title>
      <description>Description: Show Hide table data uses href, anchors, div tags, and javascript to toggle between showing and hiding a table on the html page.&lt;br /&gt;&lt;br /&gt;Link: &lt;a href='http://www.codekeep.net/snippets/8d00ff04-c48a-461f-9ccf-9ca92063fbc1.aspx'&gt;http://www.codekeep.net/snippets/8d00ff04-c48a-461f-9ccf-9ca92063fbc1.aspx&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;pre style='font-size: 9pt;'&gt;&amp;lt;script type=&amp;quot;text/javascript&amp;quot;&amp;gt;
&amp;lt;!--
function switchView(obj) {
	var el = document.getElementById(obj);
	if ( el.style.display != &amp;quot;none&amp;quot; ) {
		el.style.display = 'none';
	}
	else {
		el.style.display = '';
	}
}
//--&amp;gt;
&amp;lt;/script&amp;gt;


&amp;lt;table&amp;gt;
&amp;lt;tr&amp;gt;
            &amp;lt;td width=&amp;quot;30%&amp;quot; align=&amp;quot;right&amp;quot; valign=&amp;quot;top&amp;quot;&amp;gt;&amp;lt;a href=&amp;quot;##GotoMyControlName&amp;quot; onClick=&amp;quot;switchView('MyControlName'); return false;&amp;quot;&amp;gt;My Heading Text:&amp;lt;/a&amp;gt;&amp;lt;/td&amp;gt;
            &amp;lt;td width=&amp;quot;1%&amp;quot;&amp;gt;&amp;amp;nbsp;&amp;lt;/td&amp;gt;
            &amp;lt;td&amp;gt;
&amp;lt;!-- BEGIN section of page that will toggle between show/hide by clicking link in cell above. --&amp;gt;
                &amp;lt;div id=&amp;quot;MyControlName&amp;quot; style=&amp;quot;display:none&amp;quot;&amp;gt;
                    &amp;lt;table border=&amp;quot;0&amp;quot; cellpadding=&amp;quot;3&amp;quot; cellspacing=&amp;quot;0&amp;quot; &amp;gt;
                    &amp;lt;tr &amp;gt;
                    &amp;lt;td&amp;gt;&amp;lt;span class=&amp;quot;cPreReq&amp;quot;&amp;gt;MyOUTPUTgoesHere&amp;lt;/span&amp;gt;&amp;amp;nbsp;&amp;lt;/td&amp;gt;
                    &amp;lt;/tr&amp;gt;
                    &amp;lt;/table&amp;gt;
                &amp;lt;/div&amp;gt;
&amp;lt;!-- END section of page that will toggle between show/hide --&amp;gt;
            &amp;lt;/td&amp;gt;
          &amp;lt;/tr&amp;gt;

&amp;lt;/table&amp;gt;&lt;/pre&gt;&lt;img src="http://feeds.feedburner.com/~r/CodeKeepJavaScript/~4/RhhuMSg431w" height="1" width="1"/&gt;</description>
      <link>http://feedproxy.google.com/~r/CodeKeepJavaScript/~3/RhhuMSg431w/8d00ff04-c48a-461f-9ccf-9ca92063fbc1.aspx</link>
      <pubDate>Fri, 11 Nov 2011 14:26:36 GMT</pubDate>
    <feedburner:origLink>http://www.codekeep.net/snippets/8d00ff04-c48a-461f-9ccf-9ca92063fbc1.aspx</feedburner:origLink></item>
    <item>
      <title>Cross-Browser event triggering</title>
      <description>Description: A browser friendly way to trigger an event on an element.&lt;br /&gt;&lt;br /&gt;Link: &lt;a href='http://www.codekeep.net/snippets/28e75842-cb23-45df-abb0-04b39d2c8d79.aspx'&gt;http://www.codekeep.net/snippets/28e75842-cb23-45df-abb0-04b39d2c8d79.aspx&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;pre style='font-size: 9pt;'&gt;/*
This is just a simple snippet which doesn't really explain the detailed contents 
of an event object, but it gives an idea of the differences between specific 
browsers. This function will fire the onChange event for an element passed to 
it (say...a checkbox).
*/

function FireOnChange(element) {
  if (element.onchange) {
      var e = null;
      if (document.createEventObject) {
          //ie
          e = document.createEventObject();                    
          element.fireEvent('onchange', e);
      }
      else {
          //others
          e = document.createEvent('HTMLEvents');
          e.initEvent('change', true, true);
          element.dispatchEvent(e);
      }
   }
}&lt;/pre&gt;&lt;img src="http://feeds.feedburner.com/~r/CodeKeepJavaScript/~4/gBl-XNPt38s" height="1" width="1"/&gt;</description>
      <link>http://feedproxy.google.com/~r/CodeKeepJavaScript/~3/gBl-XNPt38s/28e75842-cb23-45df-abb0-04b39d2c8d79.aspx</link>
      <pubDate>Thu, 13 Oct 2011 23:40:58 GMT</pubDate>
    <feedburner:origLink>http://www.codekeep.net/snippets/28e75842-cb23-45df-abb0-04b39d2c8d79.aspx</feedburner:origLink></item>
    <item>
      <title>Centralise &lt;div&gt;</title>
      <description>Description: Will centre a &lt;div&gt; element to half of the screen width creating the central column effect.&lt;br /&gt;&lt;br /&gt;Link: &lt;a href='http://www.codekeep.net/snippets/c1791c4e-90d2-4809-b656-2aba0f3c038b.aspx'&gt;http://www.codekeep.net/snippets/c1791c4e-90d2-4809-b656-2aba0f3c038b.aspx&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;pre style='font-size: 9pt;'&gt;function setMainWidth() {

    // This value extends the &amp;lt;div&amp;gt; width
    var extend = 800;
    //-----------------------------------
    // Set the name of the &amp;lt;div&amp;gt; ID
    var elementId = &amp;quot;mainPage&amp;quot;;
    //-----------------------------------


    var pageWidth = 0;

    if (self.innerWidth) {
        pageWidth = self.innerWidth;
    }
    else if ((document.documentElement) &amp;amp;&amp;amp; (document.documentElement.clientWidth)) {
        pageWidth = document.documentElement.clientWidth;
    }
    else if (document.body) {
        pageWidth = document.body;    
    }

    var e = document.getElementById(elementId);
    if (e) {
        pageWidth += extend;
        e.style.width = (pageWidth / 2) + &amp;quot;px&amp;quot;;
        e.style.position = &amp;quot;absolute&amp;quot;;
        e.style.left = &amp;quot;50%&amp;quot;;
        e.style.marginLeft = &amp;quot;-&amp;quot; + (pageWidth / 4) + &amp;quot;px&amp;quot;;
    }
}&lt;/pre&gt;&lt;img src="http://feeds.feedburner.com/~r/CodeKeepJavaScript/~4/kqH9YhDwB0U" height="1" width="1"/&gt;</description>
      <link>http://feedproxy.google.com/~r/CodeKeepJavaScript/~3/kqH9YhDwB0U/c1791c4e-90d2-4809-b656-2aba0f3c038b.aspx</link>
      <pubDate>Thu, 06 Oct 2011 04:47:38 GMT</pubDate>
    <feedburner:origLink>http://www.codekeep.net/snippets/c1791c4e-90d2-4809-b656-2aba0f3c038b.aspx</feedburner:origLink></item>
    <item>
      <title>Valores dos checkbox com jquery</title>
      <description>Description: Pegar os valores dos checkbox com jquery&lt;br /&gt;&lt;br /&gt;Link: &lt;a href='http://www.codekeep.net/snippets/115bc561-e0b8-4139-b614-6e346d4dfc60.aspx'&gt;http://www.codekeep.net/snippets/115bc561-e0b8-4139-b614-6e346d4dfc60.aspx&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;pre style='font-size: 9pt;'&gt;$(function(){
  $('#btnClick').click(function(){
    var val = [];
    $(':checkbox:checked').each(function(i){
      val[i] = $(this).val();
    });
  });
});&lt;/pre&gt;&lt;img src="http://feeds.feedburner.com/~r/CodeKeepJavaScript/~4/4sWHQIl1Sg4" height="1" width="1"/&gt;</description>
      <link>http://feedproxy.google.com/~r/CodeKeepJavaScript/~3/4sWHQIl1Sg4/115bc561-e0b8-4139-b614-6e346d4dfc60.aspx</link>
      <pubDate>Mon, 03 Oct 2011 07:50:20 GMT</pubDate>
    <feedburner:origLink>http://www.codekeep.net/snippets/115bc561-e0b8-4139-b614-6e346d4dfc60.aspx</feedburner:origLink></item>
    <item>
      <title>Run jQuery in asp.net</title>
      <description>Description: I found that jQuery was firing on a page load but not when an update panel was refreshed, this catches the partial load event as well and runs my jQuery.  it might not be the right way of doing it but it works well for me.&lt;br /&gt;&lt;br /&gt;Link: &lt;a href='http://www.codekeep.net/snippets/74439ab2-63a1-49c9-ad1d-c733b9be3139.aspx'&gt;http://www.codekeep.net/snippets/74439ab2-63a1-49c9-ad1d-c733b9be3139.aspx&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;pre style='font-size: 9pt;'&gt;&amp;lt;script language=&amp;quot;javascript&amp;quot; type=&amp;quot;text/javascript&amp;quot;&amp;gt;

   
    $(document).ready(function () {
        injectJQUERY();
    });

    function pageLoad(sender, args) {
        if (args.get_isPartialLoad()) {
            injectJQUERY();
        }
    }

    function injectJQUERY() {
        $(document).ready(function () {

    }

&amp;lt;/script&amp;gt;&lt;/pre&gt;&lt;img src="http://feeds.feedburner.com/~r/CodeKeepJavaScript/~4/Oq6KCGOSUG8" height="1" width="1"/&gt;</description>
      <link>http://feedproxy.google.com/~r/CodeKeepJavaScript/~3/Oq6KCGOSUG8/74439ab2-63a1-49c9-ad1d-c733b9be3139.aspx</link>
      <pubDate>Mon, 05 Sep 2011 08:01:33 GMT</pubDate>
    <feedburner:origLink>http://www.codekeep.net/snippets/74439ab2-63a1-49c9-ad1d-c733b9be3139.aspx</feedburner:origLink></item>
  </channel>
</rss>
