<?xml version="1.0" encoding="utf-8"?>
<feed xmlns="http://www.w3.org/2005/Atom" xmlns:creativeCommons="http://backend.userland.com/creativeCommonsRssModule" xmlns:re="http://purl.org/atompub/rank/1.0">
    <title type="text">active questions tagged javascript - Stack Overflow</title>
    <link rel="self" href="http://stackoverflow.com/feeds/tag/javascript" type="application/atom+xml" />
        <link rel="hub" href="http://pubsubhubbub.appspot.com/" />        
    <link rel="alternate" href="http://stackoverflow.com/questions/tagged/?tagnames=javascript&amp;sort=active" type="text/html" />
    <subtitle>most recent 30 from stackoverflow.com</subtitle>
    <updated>2012-02-08T13:42:02Z</updated>
    <id>http://stackoverflow.com/feeds/tag/javascript</id>
    <creativeCommons:license>http://www.creativecommons.org/licenses/by-sa/3.0/rdf</creativeCommons:license> 
    <entry>
        <id>http://stackoverflow.com/q/9194372</id>
        <re:rank scheme="http://stackoverflow.com">1</re:rank>
        <title type="text">Why does MySQL automatically create indexes for me?</title>
        <category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="javascript"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="string"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="json"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="node.js"/>
        <author>
            <name>TIMEX</name>
            <uri>http://stackoverflow.com/users/179736</uri>
        </author>
        <link rel="alternate" href="http://stackoverflow.com/questions/9194372/why-does-mysql-automatically-create-indexes-for-me" />
        <published>2012-02-08T13:36:49Z</published>
        <updated>2012-02-08T13:39:58Z</updated>
        <summary type="html">
            &lt;pre&gt;&lt;code&gt;{ id: 1533,
  story_type_id: 1,
  content_id: 470,
  created_at: Sun, 05 Feb 2012 07:02:43 GMT,
  updated_at: Sun, 05 Feb 2012 07:02:43 GMT,
  type_name: &#39;post&#39; }
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;I have a JSON object with the &quot;datetime&quot; field like above.  It&#39;s perfect.  But when I stringify it (I want to store it in cache), I get this format:&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;&quot;created_at&quot;:&quot;2012-02-05T07:02:43.000Z&quot;
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;This causes problems, because when I want to JSON.parse this, suddenly it&#39;s no longer datetime format and it&#39;s incompatible with my other format.&lt;/p&gt;

&lt;p&gt;What can I do to solve this problem? I have &#39;created_at&#39; littered everywhere throughout my application. I don&#39;t want to manually change each one.&lt;/p&gt;

        </summary>
    </entry>
    <entry>
        <id>http://stackoverflow.com/q/9194189</id>
        <re:rank scheme="http://stackoverflow.com">0</re:rank>
        <title type="text">Multiple javascript instances of an object in IE6</title>
        <category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="javascript"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="internet-explorer-6"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="multiple-instances"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="instances"/>
        <author>
            <name>Erwan</name>
            <uri>http://stackoverflow.com/users/942195</uri>
        </author>
        <link rel="alternate" href="http://stackoverflow.com/questions/9194189/multiple-javascript-instances-of-an-object-in-ie6" />
        <published>2012-02-08T13:25:07Z</published>
        <updated>2012-02-08T13:39:19Z</updated>
        <summary type="html">
            &lt;p&gt;I got a little problem with IE6 which doesn&#39;t appear on Chrome or Safari or Firefox. All is working fine except one thing: my web app uses one javascript but I create multiple instances of the javascript like this:&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;var app = {};
app.mapConceptFirst = new MapConcept(&quot;#first&quot;);
app.mapConceptSecond = new MapConcept(&quot;#second&quot;);
app.mapConceptThird = new MapConcept(&quot;#third&quot;);
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;Here&#39;s the constructor:&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;function MapConcept(id) {
    this.currentNavigator = &quot;&quot;;
    this.start = 0;
    this.angle = 0;
    this.clientX = 0;
    this.clientY = 0;
    this.currentMenu = 2;
    this.h = 0;
    this.w = 0;
    this.itemList;
    this.firstRotation = 0;
    this.section = id;
    $(window).resize(function () {
        this.h = $(window).height();
        this.w = $(window).width();
    });
    jQuery.preLoadImages(&quot;images/anneau.png&quot;, &quot;images/anneau1.png&quot;, &quot;images/anneau2.png&quot;, &quot;images/anneau3.png&quot;, &quot;images/anneau4.png&quot;);
    this.currentNavigator = BrowserDetect.init();
    this.init();
    this.getItems();
}
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;Unfortunately, on IE6 the first instance works fine, all my stuff is running, but the second and third ones don&#39;t work. How can I solve my problem ?&lt;/p&gt;

        </summary>
    </entry>
    <entry>
        <id>http://stackoverflow.com/q/9194255</id>
        <re:rank scheme="http://stackoverflow.com">2</re:rank>
        <title type="text">jQuery Select list, selected text value rather than the value</title>
        <category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="javascript"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="jquery"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="asp.net"/>
        <author>
            <name>Tom Beech</name>
            <uri>http://stackoverflow.com/users/900659</uri>
        </author>
        <link rel="alternate" href="http://stackoverflow.com/questions/9194255/jquery-select-list-selected-text-value-rather-than-the-value" />
        <published>2012-02-08T13:29:39Z</published>
        <updated>2012-02-08T13:41:57Z</updated>
        <summary type="html">
            &lt;p&gt;building on my last question &lt;a href=&quot;http://stackoverflow.com/questions/9191278/jquery-getting-values-from-multiple-selects-together&quot;&gt;jQuery getting values from multiple selects together&lt;/a&gt; &lt;/p&gt;

&lt;p&gt;I have the select list like:&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;  &amp;lt;select name=&quot;access&quot; class=&quot;change&quot; id=&quot;staff_off&quot;  runat=&quot;server&quot;&amp;gt;
                &amp;lt;option value=&quot;8192&quot;&amp;gt;Off&amp;lt;/option&amp;gt;
                &amp;lt;option value=&quot;8192&quot;&amp;gt;On&amp;lt;/option&amp;gt;
  &amp;lt;/select&amp;gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;And I basically want to add or subtract the value of the options if it&#39;s off, subtract if it&#39;s on add it. It&#39;s going to be stored in a cookie (it uses bitwise)&lt;/p&gt;

&lt;p&gt;The jquery I have is:&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;&amp;lt;script&amp;gt;

        $(document).ready(function(){
           var currentAccess = $.cookie(&quot;access&quot;);
        })

        $(&quot;select&quot;).change(function () {
            var currentText = $(this).text()
            var value = $(this).val()

              $.cookie(&quot;access&quot;, value, { expires: 24 });

              alert(currentText);

              alert( $.cookie(&quot;access&quot;) );

            })

    &amp;lt;/script&amp;gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;I&#39;ll do the addition in the change function. The thing I can&#39;t work out is how to get the text of the select to do an if statement (so if it&#39;s yes, add the value, if it&#39;s no, subtract the value)&lt;/p&gt;

&lt;p&gt;Tom&lt;/p&gt;

        </summary>
    </entry>
    <entry>
        <id>http://stackoverflow.com/q/9194387</id>
        <re:rank scheme="http://stackoverflow.com">0</re:rank>
        <title type="text">How do you mitigate risk when introducing multivariate testing into a dynamic web application?</title>
        <category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="javascript"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="html"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="testing"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="google-website-optimizer"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="multivariate-testing"/>
        <author>
            <name>Steve Perkins</name>
            <uri>http://stackoverflow.com/users/461800</uri>
        </author>
        <link rel="alternate" href="http://stackoverflow.com/questions/9194387/how-do-you-mitigate-risk-when-introducing-multivariate-testing-into-a-dynamic-we" />
        <published>2012-02-08T13:37:53Z</published>
        <updated>2012-02-08T13:37:53Z</updated>
        <summary type="html">
            &lt;p&gt;My company is engaging with a multivariate testing vendor (I can&#39;t disclose which one just yet), and I am being asked to integrate their system into our flagship B2C commerce site.&lt;/p&gt;

&lt;p&gt;Usually, the word &quot;integrate&quot; is a heavy-duty term.  However, here it means to add a &lt;code&gt;&amp;lt;script&amp;gt;&lt;/code&gt; tag on several views, and then be out of the loop from that point forward.  The mulitvariate experiments will be set up by our marketing department (and/or the vendor).  Our development team will not be involved in that, and may not even be aware when it&#39;s happening.&lt;/p&gt;

&lt;p&gt;Essentially, I am being told to deliberately add a JavaScript-injection attack vector to our flagship application... and hope for the best.  My concerns are not so much with malicious code as they are with inadvertent screw-ups.  Our CSS and basic page layout is a mess already, and I anticipate catiching the heat when someone else&#39;s multivariate experiment blows up the home page look-n-feel, etc.  Much more importantly, there is a lot of ugly AJAX and server-side cruft that depends on predictable HTML elements, &lt;code&gt;id&lt;/code&gt; attributes, etc... and so if an experiment changes HTML elements too much, core commerce functionality will simply break altogether in unpredictable ways.&lt;/p&gt;

&lt;p&gt;My concerns are amplified by the lack of a real test environment.  The vendor does filtering, so that only AJAX calls from our production URL are processed.  Calls from our Dev or QA environments are ignored.  However, that&#39;s not the same thing as having a test environment.  Rather, it means that &lt;em&gt;production&lt;/em&gt; is now our test environment for each experiment.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Given all of the above, are there any practices available to mitigate some of these risks?&lt;/strong&gt;  Multivariate testing is such a new field, the first several pages of a Google search consists of shady consultants selling buzzwords to CIO&#39;s.  There&#39;s not much written for the in-house technical audience ultimately responsible for keeping an eye on risk.  Are there any ways to properly QA under the above restraints, or is there simply no alternative but to push back(*) in such a scenario?&lt;/p&gt;

&lt;p&gt;(*) Note:  Given the politics of the vendor relationship, we would need to build an extraordinarily airtight case for push-back, and it may be ignored anyway.&lt;/p&gt;

        </summary>
    </entry>
    <entry>
        <id>http://stackoverflow.com/q/9192870</id>
        <re:rank scheme="http://stackoverflow.com">1</re:rank>
        <title type="text">Javascript - session.getAttribute returns undefined value</title>
        <category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="javascript"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="html"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="forms"/>
        <author>
            <name>user1197071</name>
            <uri>http://stackoverflow.com/users/1197071</uri>
        </author>
        <link rel="alternate" href="http://stackoverflow.com/questions/9192870/javascript-session-getattribute-returns-undefined-value" />
        <published>2012-02-08T11:58:40Z</published>
        <updated>2012-02-08T13:37:18Z</updated>
        <summary type="html">
            &lt;p&gt;I have a JSP form that reads input from the user and calls a Java servlet to process
data. Once the data been proccesed, &lt;code&gt;session.setAttribute&lt;/code&gt; is called to store important information. Then in Javascript I try to read the session variable and display
it on the screen. The code looks like this (some code removed):&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;&amp;lt;script type=&quot;text/javascript&quot;&amp;gt;
   var test = &amp;lt;%= session.getAttribute( &quot;mySessionVar&quot; ) %&amp;gt;;
   document.write (test);
}
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;When the user enters an integer in the form, all is working as expected and the output
displayed on the screen properly. However, when the user enters a String in the form, 
&lt;strong&gt;&quot;undefined&quot;&lt;/strong&gt; is displayed on the screen. &lt;/p&gt;

&lt;p&gt;Any idea what I&#39;m doing wrong? &lt;/p&gt;

        </summary>
    </entry>
    <entry>
        <id>http://stackoverflow.com/q/9178847</id>
        <re:rank scheme="http://stackoverflow.com">1</re:rank>
        <title type="text">Simulation in a Web Browser</title>
        <category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="javascript"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="ajax"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="websocket"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="simulation"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="html5-canvas"/>
        <author>
            <name>Balzard</name>
            <uri>http://stackoverflow.com/users/723716</uri>
        </author>
        <link rel="alternate" href="http://stackoverflow.com/questions/9178847/simulation-in-a-web-browser" />
        <published>2012-02-07T15:22:48Z</published>
        <updated>2012-02-08T13:35:45Z</updated>
        <summary type="html">
            &lt;p&gt;Sorry if the title is confusing, it&#39;s hard to sum up in one phrase.&lt;/p&gt;

&lt;p&gt;I am working a a project consisting of rendering a robot simulation in a web browser.
To be more specific, at the university where I&#39;m studying they use a simulator written in C++, this program simulates robots evolving in an environment.
This simulator has many outputs available like 3D OpenGL visualisation etc.
One output available is the basic text render which output for each time step, the position of every robots in the environment.&lt;/p&gt;

&lt;p&gt;Ok, so they asked me to work on a new type of visualization taking place in a browser.
This means that one could upload his code for the simulator, launch it on the server and see the simulation in the browser (in an HTML5 Canvas or SVG) WHILE it is simulated on the server!&lt;/p&gt;

&lt;p&gt;Ok so I first thought using Ajax to get data from the simulator and use some Canvas Library to draw the robots on the screen. But they don&#39;t want to need a Web Server so I thought of writing a new type of visualization directly in the simulator (using a C++ WebSocket library if this actually exists) which would act as a WebSocket server so that the browser can directly talk to the simulator without the need of a Web Server (don&#39;t know if it is possible).&lt;/p&gt;

&lt;p&gt;Well ... That&#39;s the idea. It would be awesome if you could tell me what you think about it and give me some advices/links.
Is it possible to handle this without a Web Server ? If it&#39;s not possible without implementing the HTTP protocol in the simulator, then I&#39;ll skip this idea and do with a Web Server :)&lt;/p&gt;

&lt;p&gt;Second question more precise:
I&#39;ve already looked at some HTML5 Canvas library, fabric.js, jCanvaScript, dojo.gfx, cake, doodle.js, bHive, KineticJS. I am still not sure of which one to use.
I started some experiments with jCanvaScript and I&#39;m facing a problem.
I get data from the server (robots positions at each time step) and then have to draw them in the canvas. I was using some .animate function do get smooth movements. This function takes a number of ms, the time of the animation and I don&#39;t know how to synchronise the animations of all the objects I have to move at each timestep of the simulation.
Do you know a framework that would help implementing that kind of simulation? (just moving objects between each timestep).&lt;/p&gt;

&lt;p&gt;That&#39;s about it, apology for my poor english, I hope it is understandable, if not, tell me, I&#39;ll rephrase.&lt;/p&gt;

&lt;p&gt;Thanks in advance for your help.
I&#39;m a bit lost on that project and any advice would be greatly appreciated !&lt;/p&gt;

&lt;p&gt;Have a good day.&lt;/p&gt;

&lt;p&gt;Balzard.&lt;/p&gt;

        </summary>
    </entry>
    <entry>
        <id>http://stackoverflow.com/q/9194353</id>
        <re:rank scheme="http://stackoverflow.com">0</re:rank>
        <title type="text">status box like twitter status box</title>
        <category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="javascript"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="html"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="ajax"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="twitter"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="status"/>
        <author>
            <name>user1194960</name>
            <uri>http://stackoverflow.com/users/1194960</uri>
        </author>
        <link rel="alternate" href="http://stackoverflow.com/questions/9194353/status-box-like-twitter-status-box" />
        <published>2012-02-08T13:35:32Z</published>
        <updated>2012-02-08T13:35:32Z</updated>
        <summary type="html">
            &lt;p&gt;I am a new PHP learner. I need a status box which just like twitter status box. I have tried many websites and i can not find the exact solution.&lt;/p&gt;

&lt;p&gt;What i exactly need is
1. Status box like twitter, when typing on the box it will increase its size automatically
2.If there is URL in the status, it should automatically highlight URL like twitter
3.After 500 characters user should not allowed to type in.&lt;/p&gt;

&lt;p&gt;I don&#39;t want to use any API. I think the code might be combination of HTML,ajax and javascript. 
Please someone help me. I am new in this area. So if it is possible give a little explanation of your code. &lt;/p&gt;

&lt;p&gt;I found a bit similar question in this website but the answer is not given there. &lt;/p&gt;

        </summary>
    </entry>
    <entry>
        <id>http://stackoverflow.com/q/9192990</id>
        <re:rank scheme="http://stackoverflow.com">0</re:rank>
        <title type="text">how to print the associative array in print_r() fashion from a $.getJSON call?</title>
        <category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="javascript"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="jquery"/>
        <author>
            <name>Istiaque Ahmed</name>
            <uri>http://stackoverflow.com/users/998537</uri>
        </author>
        <link rel="alternate" href="http://stackoverflow.com/questions/9192990/how-to-print-the-associative-array-in-print-r-fashion-from-a-getjson-call" />
        <published>2012-02-08T12:06:20Z</published>
        <updated>2012-02-08T13:34:15Z</updated>
        <summary type="html">
            &lt;p&gt;simple thing.&lt;/p&gt;

&lt;p&gt;$.getJSON is used and the result from the .php file being called is caught as response in the jquery callback function. The json encoded php array is an associative array.&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;$.getJSON(&quot;file.php&quot;,function(response){

// print the associative response array in var_dump or print_r fasion

});
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;file.php contains:&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;&amp;lt;?php

$my_array=array();

//$my_array[&#39;random_index1&#39;]=&quot;random_value1&quot;;

//$my_array[&#39;random_index2&#39;]=&quot;random_value2&quot;;

//$my_array[&#39;random_index3&#39;]=&quot;random_value3&quot;;
// and so on


echo json_encode($my_array);


?&amp;gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;$my_array has random keys and values.&lt;/p&gt;

&lt;p&gt;How can I print the whole &#39;response&#39; array just like the print_r fashion in php?&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;EDIT:&lt;/strong&gt; I want to print it on the webpage or in an alert box. Not that i just want to watch the values in the javascript console(chrome, FF or whatever).&lt;/p&gt;

        </summary>
    </entry>
    <entry>
        <id>http://stackoverflow.com/q/9193932</id>
        <re:rank scheme="http://stackoverflow.com">2</re:rank>
        <title type="text">getting a value along with html markup returned by Ajax in Jquery</title>
        <category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="javascript"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="jquery"/>
        <author>
            <name>user1038814</name>
            <uri>http://stackoverflow.com/users/1038814</uri>
        </author>
        <link rel="alternate" href="http://stackoverflow.com/questions/9193932/getting-a-value-along-with-html-markup-returned-by-ajax-in-jquery" />
        <published>2012-02-08T13:09:48Z</published>
        <updated>2012-02-08T13:33:02Z</updated>
        <summary type="html">
            &lt;p&gt;I use the following to retrieve some html using Jquery:&lt;/p&gt;

&lt;p&gt;index.php&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;$.post(
    &#39;get-products.php&#39;, 
    $(&quot;#offerForm&quot;).serialize() + &#39;&amp;amp;lastid=&#39; + highest, 
    function(data) {            
        $(&#39;#demo&#39;).html(data); 
    }
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;Is it possible to also retrieve a value of a variable from get-products.php, example:&lt;/p&gt;

&lt;p&gt;get-products.php&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;&amp;lt;? echo $htmlOutput;
echo $variable; ?&amp;gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;index.php&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;$.post(
    &#39;get-products.php&#39;, 
    $(&quot;#offerForm&quot;).serialize() + &#39;&amp;amp;lastid=&#39; + highest, 
    function(data) {
        $(&#39;#demo&#39;).html(data);
        //variable processing statement goes here   
    }
&lt;/code&gt;&lt;/pre&gt;

        </summary>
    </entry>
    <entry>
        <id>http://stackoverflow.com/q/9194313</id>
        <re:rank scheme="http://stackoverflow.com">0</re:rank>
        <title type="text">is it possible to call nested function from googlemaps infowindow</title>
        <category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="javascript"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="google-maps"/>
        <author>
            <name>peko</name>
            <uri>http://stackoverflow.com/users/612304</uri>
        </author>
        <link rel="alternate" href="http://stackoverflow.com/questions/9194313/is-it-possible-to-call-nested-function-from-googlemaps-infowindow" />
        <published>2012-02-08T13:32:40Z</published>
        <updated>2012-02-08T13:32:40Z</updated>
        <summary type="html">
            &lt;p&gt;I have following code. Calling saveLatLng works but calling saveLatLng2 doesn&#39;t.&lt;/p&gt;

&lt;p&gt;I like to call the nested function so i can access the infoWindow variable, or do i hava to pass the infoWindow variable to the extern method?&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;&amp;lt;script type=&quot;text/javascript&quot;&amp;gt;
  function initialize() {
    var myLatlng = new google.maps.LatLng({{address.@geolat}}, {{address.@geolon}});
    var myOptions = {
        zoom: 16,
        center: myLatlng,
        mapTypeId: google.maps.MapTypeId.ROADMAP
    };
    var map = new google.maps.Map(document.getElementById(&quot;map_canvas&quot;), myOptions);
    var marker = new google.maps.Marker({
        position: myLatlng,
        map: map,
        clickable: true,
        draggable: true,
        title:&quot;Hello World!&quot;
    });
    var infoWindow = new google.maps.InfoWindow({
    });
    google.maps.event.addListener(marker, &#39;click&#39;, function(event) {
        infoWindow.setContent(&quot;Mit Drag&amp;amp;Drop neu Position setzen!&quot;);
        infoWindow.open(map, marker);
    });
    google.maps.event.addListener(marker, &#39;dragend&#39;, function(event) {
        newLat = marker.position.lat();
        newLng = marker.position.lng();
        infoWindow.setContent(
            &#39;&amp;lt;a href=&quot;javascript:saveLatLng(newLat, newLng);&quot;&amp;gt;test&amp;lt;/a&amp;gt;&amp;lt;br&amp;gt;&#39;
            + &#39;&amp;lt;a href=&quot;javascript:saveLatLng2(newLat, newLng);&quot;&amp;gt;test&amp;lt;/a&amp;gt;&#39;
        );
        infoWindow.open(map, marker);
    });
    var saveLatLng2 = function(newLat, newLng) {
        console.log(newLat + &#39;,&#39; + newLng);
    };
  }

  var saveLatLng = function(newLat, newLng) {
     console.log(newLat + &#39;,&#39; + newLng);
  };
&amp;lt;/script&amp;gt;
&lt;/code&gt;&lt;/pre&gt;

        </summary>
    </entry>
    <entry>
        <id>http://stackoverflow.com/q/9194247</id>
        <re:rank scheme="http://stackoverflow.com">0</re:rank>
        <title type="text">My associative array doesnt store objects</title>
        <category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="javascript"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="arrays"/>
        <author>
            <name>markzzz</name>
            <uri>http://stackoverflow.com/users/365251</uri>
        </author>
        <link rel="alternate" href="http://stackoverflow.com/questions/9194247/my-associative-array-doesnt-store-objects" />
        <published>2012-02-08T13:28:58Z</published>
        <updated>2012-02-08T13:41:42Z</updated>
        <summary type="html">
            &lt;p&gt;&lt;a href=&quot;http://jsfiddle.net/N2Z6Q/&quot; rel=&quot;nofollow&quot;&gt;It&lt;/a&gt; seems it&#39;s always empty :&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;var idStruttura=2;
var arrayMarkers=new Array();

arrayMarkers[&quot;sede_&quot;+idStruttura] = &quot;ciao&quot;;
alert(arrayMarkers.length);
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;Prints always 0. Why? And how can I fix it?&lt;/p&gt;

        </summary>
    </entry>
    <entry>
        <id>http://stackoverflow.com/q/9194153</id>
        <re:rank scheme="http://stackoverflow.com">0</re:rank>
        <title type="text">Why am I not able to populate my Array object?</title>
        <category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="javascript"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="asp.net"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="ajax"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="dojo"/>
        <author>
            <name>Abhisek Bose</name>
            <uri>http://stackoverflow.com/users/632533</uri>
        </author>
        <link rel="alternate" href="http://stackoverflow.com/questions/9194153/why-am-i-not-able-to-populate-my-array-object" />
        <published>2012-02-08T13:23:05Z</published>
        <updated>2012-02-08T13:31:49Z</updated>
        <summary type="html">
            &lt;pre&gt;&lt;code&gt;if (typeof response == &quot;object&quot;) {
    store = new dojo.data.ItemFileReadStore({
        data : response
    });
    console.warn(&quot;Loaded to Store&quot;);
    var itemArray = new Array();
    var completed = function(items) {
        for(var i = 0; i &amp;lt; items.length; i++) {
            console.log(store.getValue(items[i],&quot;itemlabel&quot;));
            itemArray.push(store.getValue(items[i]));
        }
    };
    var error = function() {
        console.log(&quot;Error in fetching data from Store&quot;);
    };

    store.fetch({onComplete: completed, onError: error});
    console.warn(&quot;Item count&quot;+ itemArray.length);
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;So my Item Count gives Always 0 but &lt;/p&gt;

&lt;pre&gt;&lt;code&gt;console.log(store.getValue(items[i],&quot;itemlabel&quot;));
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;In the callback method the above get print the value.&lt;/p&gt;

&lt;p&gt;So if i want to populate my &lt;code&gt;itemArray&lt;/code&gt; what can i do?&lt;/p&gt;

        </summary>
    </entry>
    <entry>
        <id>http://stackoverflow.com/q/9194162</id>
        <re:rank scheme="http://stackoverflow.com">0</re:rank>
        <title type="text">How to open colorbox from inside a iframe on top of parent window</title>
        <category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="javascript"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="jquery"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="modal-dialog"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="colorbox"/>
        <author>
            <name>Josh Randall</name>
            <uri>http://stackoverflow.com/users/840766</uri>
        </author>
        <link rel="alternate" href="http://stackoverflow.com/questions/9194162/how-to-open-colorbox-from-inside-a-iframe-on-top-of-parent-window" />
        <published>2012-02-08T13:23:35Z</published>
        <updated>2012-02-08T13:29:19Z</updated>
        <summary type="html">
            &lt;p&gt;I have a page with an iframe. The link inside an iframe should open colorbox. It works fine.&lt;/p&gt;

&lt;p&gt;But it opens the colorbox inside the iframe. Is it possible to open the iframe over the parent window. &lt;/p&gt;

&lt;p&gt;I appreciate any help.&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;     $(function() {
          $(&#39;#ajax&#39;).colorbox({iframe: true });
     });
&lt;/code&gt;&lt;/pre&gt;

        </summary>
    </entry>
    <entry>
        <id>http://stackoverflow.com/q/9192494</id>
        <re:rank scheme="http://stackoverflow.com">0</re:rank>
        <title type="text">Replace whole DOM in javascript</title>
        <category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="javascript"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="dom"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="replace"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="undo"/>
        <author>
            <name>c1tru55</name>
            <uri>http://stackoverflow.com/users/1153596</uri>
        </author>
        <link rel="alternate" href="http://stackoverflow.com/questions/9192494/replace-whole-dom-in-javascript" />
        <published>2012-02-08T11:32:46Z</published>
        <updated>2012-02-08T13:29:12Z</updated>
        <summary type="html">
            &lt;p&gt;I need to implement undo-redo functionality in my project. But it is very complex and every change affects on many elements. I think saving and restoring whole page will be the best choice. But i have some problems with missing .data() params of DOM elements. I use next functions:&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;// save
var documentCopy = document.documentElement.cloneNode(true);

// restore
document.replaceChild(
documentCopy,
document.documentElement
);
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;How I can save and restore whole DOM with saving jQuery.data() of elements?&lt;/p&gt;

        </summary>
    </entry>
    <entry>
        <id>http://stackoverflow.com/q/9194067</id>
        <re:rank scheme="http://stackoverflow.com">0</re:rank>
        <title type="text">why doesn&#39;t refreshing Firefox reflect javascript code changes?</title>
        <category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="javascript"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="firefox"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="netbeans"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="dojo"/>
        <author>
            <name>TedPrz</name>
            <uri>http://stackoverflow.com/users/906048</uri>
        </author>
        <link rel="alternate" href="http://stackoverflow.com/questions/9194067/why-doesnt-refreshing-firefox-reflect-javascript-code-changes" />
        <published>2012-02-08T13:17:53Z</published>
        <updated>2012-02-08T13:28:19Z</updated>
        <summary type="html">
            &lt;p&gt;I am working on a simple dojo comboBox (dijit.form.ComboBox) connected to a dojo.store.Memory.  I&#39;m using the latest Netbeans and Glassfish setup, with Firefox 10.  My problem is that when I change or comment out code related to the combobox, the changes don&#39;t show up when I refresh the web page.  I&#39;ve tried clean/build, rerunning, etc, but commenting out the code seems to do nothing.  Firefox seems to be running a cached version of the page, instead of rendering the latest code changes I&#39;ve made.  I don&#39;t want to have to clear out the browser cache every time I refresh the page.  (What I ultimately want to be able to do is dictate when the autoComplete turns on and off.)  Any ideas? &lt;/p&gt;

&lt;pre&gt;&lt;code&gt;&amp;lt;!DOCTYPE HTML PUBLIC &quot;-//W3C//DTD HTML 4.01 Transitional//EN&quot; &quot;http://www.w3.org/TR/html4/loose.dtd&quot;&amp;gt;
&amp;lt;html&amp;gt;
    &amp;lt;head&amp;gt;
    &amp;lt;title&amp;gt;&amp;lt;/title&amp;gt;
    &amp;lt;meta http-equiv=&quot;Content-Type&quot; content=&quot;text/html; charset=UTF-8&quot;&amp;gt;                   
    &amp;lt;script src=&quot;http://ajax.googleapis.com/ajax/libs/dojo/1.7.1/dojo/dojo.js&quot; type=&quot;text/javascript&quot; &amp;gt;&amp;lt;/script&amp;gt; 
&lt;/code&gt;&lt;/pre&gt;

 

&lt;pre&gt;&lt;code&gt;    &amp;lt;script type=&quot;text/javascript&quot;&amp;gt;
        dojo.require(&quot;dijit.form.ComboBox&quot;);
        dojo.require(&quot;dojo.store.Memory&quot;);

        var myBox, store;
        dojo.ready(function(){makeComboBox();});

        function makeComboBox(){

            store = new dojo.store.Memory({
                data: [
                    {name:&quot;Alabama&quot;, id:&quot;AL&quot;},
                    {name:&quot;Alaska&quot;, id:&quot;AK&quot;},
                    {name:&quot;American Samoa&quot;, id:&quot;AS&quot;},
                    {name:&quot;Arizona&quot;, id:&quot;AZ&quot;},
                    {name:&quot;Arkansas&quot;, id:&quot;AR&quot;},
                    {name:&quot;Armed Forces Europe&quot;, id:&quot;AE&quot;},
                    {name:&quot;Armed Forces Pacific&quot;, id:&quot;AP&quot;},
                    {name:&quot;Armed Forces the Americas&quot;, id:&quot;AA&quot;},
                    {name:&quot;California&quot;, id:&quot;CA&quot;},
                    {name:&quot;Colorado&quot;, id:&quot;CO&quot;},
                    {name:&quot;Connecticut&quot;, id:&quot;CT&quot;},
                    {name:&quot;Delaware&quot;, id:&quot;DE&quot;}                        
                ]
            });                

            myBox = new dijit.form.ComboBox({                
                id: &quot;stateSelect&quot;,
                name: &quot;state&quot;,
                //value: &quot;Alabama&quot;, 
                //store: store,  &amp;lt;-- the box is still connected to the store, 
                                 &amp;lt;--even if I comment it out
                searchAttr:&quot;name&quot;
            }, &quot;stateSelect&quot;);
            //myBox.set(&quot;autoComplete&quot;, &quot;false&quot;); &amp;lt;-- this doesn&#39;t work either
        }
    &amp;lt;/script&amp;gt;

&amp;lt;div id=&quot;myDiv&quot;  &amp;gt;
    &amp;lt;input id=&quot;stateSelect&quot; &amp;gt;
    &amp;lt;p&amp;gt;&amp;lt;button onClick=&quot;alert(dijit.byId(&#39;stateSelect&#39;).get(&#39;value&#39;))&quot;&amp;gt;get value&amp;lt;/button&amp;gt;&amp;lt;/p&amp;gt;
&amp;lt;/div&amp;gt;
&lt;/code&gt;&lt;/pre&gt;

        </summary>
    </entry>
    <entry>
        <id>http://stackoverflow.com/q/9194170</id>
        <re:rank scheme="http://stackoverflow.com">0</re:rank>
        <title type="text">Chained drop down box value not showing in IE 7,8,9 or lower browser</title>
        <category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="javascript"/>
        <author>
            <name>Manash Kumar</name>
            <uri>http://stackoverflow.com/users/1197239</uri>
        </author>
        <link rel="alternate" href="http://stackoverflow.com/questions/9194170/chained-drop-down-box-value-not-showing-in-ie-7-8-9-or-lower-browser" />
        <published>2012-02-08T13:23:59Z</published>
        <updated>2012-02-08T13:23:59Z</updated>
        <summary type="html">
            &lt;p&gt;&lt;strong&gt;Here is my javascript code::---&lt;/strong&gt;&lt;/p&gt;



//Browser Support Code
function ajaxFunction(str){
    var ajaxRequest;  // The variable that makes Ajax possible!

    try{
        // Opera 8.0+, Firefox, Safari
        ajaxRequest = new XMLHttpRequest();
    } catch (e){
        // Internet Explorer Browsers
        try{
            ajaxRequest = new ActiveXObject(&quot;Msxml2.XMLHTTP&quot;);
        } catch (e) {
            try{
                ajaxRequest = new ActiveXObject(&quot;Microsoft.XMLHTTP&quot;);
            } catch (e){
                // Something went wrong
                alert(&quot;Your browser broke!&quot;);
                return false;
            }
        }
    }
    // Create a function that will receive data sent from the server

    var url=&quot;../frontend/views/home/category.php&quot; + &quot;?value=&quot;+str;

    ajaxRequest.onreadystatechange = function(){
        if(ajaxRequest.readyState == 4){
            //document.myForm.time.value = ajaxRequest.responseText;
            document.getElementById(&quot;class&quot;).innerHTML=ajaxRequest.responseText;
        }
    }

    ajaxRequest.open(&quot;GET&quot;, url, true);
    ajaxRequest.send(null); 

}




        </summary>
    </entry>
    <entry>
        <id>http://stackoverflow.com/q/9194105</id>
        <re:rank scheme="http://stackoverflow.com">0</re:rank>
        <title type="text">Extracting part of current page&#39;s URL in javascript</title>
        <category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="javascript"/>
        <author>
            <name>Maxim V. Pavlov</name>
            <uri>http://stackoverflow.com/users/645460</uri>
        </author>
        <link rel="alternate" href="http://stackoverflow.com/questions/9194105/extracting-part-of-current-pages-url-in-javascript" />
        <published>2012-02-08T13:20:13Z</published>
        <updated>2012-02-08T13:23:32Z</updated>
        <summary type="html">
            &lt;p&gt;In ASP.NET MVC 3 site, I open the following uri&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;http://myserver/incidents/supercompany/register
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;That page needs to make use of ajax JSON retrieval mechanism with the help of jQuery:&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;$.getJSON(&#39;/Incidents/[[COMPANY NAME GOES HERE]]/SearchPeople/&#39; + request.term, function (data) 
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;I am new to javascript. How can I obtain &lt;code&gt;supercompany&lt;/code&gt; part of my current url to build the&lt;/p&gt;

&lt;p&gt;&lt;code&gt;/Incidents/supercompany/SearchPeople/&lt;/code&gt; string?&lt;/p&gt;

        </summary>
    </entry>
    <entry>
        <id>http://stackoverflow.com/q/9194138</id>
        <re:rank scheme="http://stackoverflow.com">0</re:rank>
        <title type="text">Porting my old plain JavaScript projects to CoffeeScript and BackboneJS</title>
        <category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="javascript"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="backbone.js"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="coffeescript"/>
        <author>
            <name>Danwit</name>
            <uri>http://stackoverflow.com/users/1197228</uri>
        </author>
        <link rel="alternate" href="http://stackoverflow.com/questions/9194138/porting-my-old-plain-javascript-projects-to-coffeescript-and-backbonejs" />
        <published>2012-02-08T13:22:31Z</published>
        <updated>2012-02-08T13:22:31Z</updated>
        <summary type="html">
            &lt;p&gt;iam in a mood right now and thought it would be great to port my existing plain JavaScript projects to CoffeeScript and BackboneJS to get a cleaner structure for future development. I also like the CoffeeScript syntax and its ability to compile Lint-proved JavaScript.&lt;/p&gt;

&lt;p&gt;I found some neat Information about how both of them can work together. -&gt; &lt;a href=&quot;http://spin.atomicobject.com/2011/05/06/using-backbone-js-with-coffeescript/&quot; rel=&quot;nofollow&quot;&gt;http://spin.atomicobject.com/2011/05/06/using-backbone-js-with-coffeescript/&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;But my problem is: Iam not quite sure where to start. I usually structured my JavaScript in a pseudo class-based fashion. Like this:&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;var node = new function() {
    this.add = this.add = function(target) {};
    this.set = function(target, options) {};
};
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;Iam not very familiar with BackboneJS and CoffeeScript in practice.
Is it better to start off with a BackboneJS structure and refactor my scripts into that. Or should i rewrite my code in CoffeeScript and move it to BackboneJS afterwards?&lt;/p&gt;

        </summary>
    </entry>
    <entry>
        <id>http://stackoverflow.com/q/9193752</id>
        <re:rank scheme="http://stackoverflow.com">0</re:rank>
        <title type="text">insert XML into DOM leads to not working class/id selectors</title>
        <category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="javascript"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="jquery"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="xml"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="dom"/>
        <author>
            <name>Christian</name>
            <uri>http://stackoverflow.com/users/178597</uri>
        </author>
        <link rel="alternate" href="http://stackoverflow.com/questions/9193752/insert-xml-into-dom-leads-to-not-working-class-id-selectors" />
        <published>2012-02-08T12:57:46Z</published>
        <updated>2012-02-08T13:22:23Z</updated>
        <summary type="html">
            &lt;p&gt;I&#39;m trying to load an XML file with ajax and insert parts of this XML DOM document into the browsers HTML DOM.&lt;/p&gt;

&lt;p&gt;This works so far, but when I try to get an inserted element with a class or id selector with jquery it returns the empty list.&lt;/p&gt;

&lt;p&gt;I tried it only in firefox 10 so far. does anyone have a clue why this might be? is it just not safe to do so?&lt;/p&gt;

&lt;p&gt;test.html:&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;&amp;lt;html&amp;gt;&amp;lt;head&amp;gt;
  &amp;lt;script type=&quot;text/javascript&quot; src=&quot;http://ajax.googleapis.com/ajax/libs/jquery/1.7.1/jquery.min.js&quot;&amp;gt;&amp;lt;/script&amp;gt;
  &amp;lt;title&amp;gt;dom test&amp;lt;/title&amp;gt;
  &amp;lt;script type=&quot;text/javascript&quot;&amp;gt;
    $(function() {
      var xml = null;
      $.ajax({
        type : &quot;GET&quot;,
        async : false,
        url : &#39;test.xml&#39;,
        dataType : &quot;xml&quot;,
        success : function(data) {
          xml = data;
        }
      });

      $(&#39;body&#39;).html($(xml).children().clone());

      console.log($(&#39;h1&#39;)); // prints the h1 element
      console.log($(&#39;.title&#39;)); // prints empty list

      console.log($(&#39;p&#39;)); // prints the p element
      console.log($(&#39;#content&#39;)); // prints empty list
    });      
  &amp;lt;/script&amp;gt;
&amp;lt;/head&amp;gt;&amp;lt;body&amp;gt;&amp;lt;/body&amp;gt;&amp;lt;/html&amp;gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;test.xml:&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;&amp;lt;div id=&quot;root&quot;&amp;gt;
  &amp;lt;h1 class=&quot;title&quot;&amp;gt;Blabla&amp;lt;/h1&amp;gt;
  &amp;lt;p id=&quot;content&quot;&amp;gt;
    Lorem ipsum
  &amp;lt;/p&amp;gt;
&amp;lt;/div&amp;gt;
&lt;/code&gt;&lt;/pre&gt;

        </summary>
    </entry>
    <entry>
        <id>http://stackoverflow.com/q/9194134</id>
        <re:rank scheme="http://stackoverflow.com">1</re:rank>
        <title type="text">Trying to create tetris, but can&#39;t</title>
        <category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="javascript"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="html5-canvas"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="tetris"/>
        <author>
            <name>TMP</name>
            <uri>http://stackoverflow.com/users/1197246</uri>
        </author>
        <link rel="alternate" href="http://stackoverflow.com/questions/9194134/trying-to-create-tetris-but-cant" />
        <published>2012-02-08T13:21:56Z</published>
        <updated>2012-02-08T13:21:56Z</updated>
        <summary type="html">
            &lt;p&gt;For some reason my code refuses to let me assign an x and y position to each block.  Each block is 30 pixels wide and tall and will be colored according to which piece it is a part of.  Gravity and a clear function haven&#39;t been implemented and the move left and move right function are so different because it wasn&#39;t working right and then recreated it as it is seen now in the left function and it works less...&lt;/p&gt;

&lt;p&gt;Please help!&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;&amp;lt;!DOCTYPE html&amp;gt;
&amp;lt;html&amp;gt;
    &amp;lt;head&amp;gt;
        &amp;lt;title&amp;gt;Tetris in Canvas&amp;lt;/title&amp;gt;
        &amp;lt;style type=&quot;text/css&quot;&amp;gt;
            canvas {
                border: solid 1px black;
                margin: -8px;
            }
        &amp;lt;/style&amp;gt;
        &amp;lt;script type=&quot;text/javascript&quot;&amp;gt;
            var canvas = null;
            var ctx = null;
            var blockArray = [];
            var board = [];
            var blockNum = 0;
            for (var s = 0; s &amp;lt; 14; s++) {
                board[s] = [27];
                for (var t = 0; t &amp;lt; 27; t++) {
                    board[s][t] = -1;
                }
            }

            document.onkeydown = function(event) {
                var keyCode;

                if(event == null)
                    keyCode = window.event.keyCode;
                else
                    keyCode = event.keyCode;

                switch(keyCode) {
                    case 37:
                        left(blockArray.length);
                        break;
                    case 38:
                        up(blockArray.length);
                        break;
                    case 39:
                        right(blockArray.length);
                        break;
                    case 40:
                        down(blockArray.length);
                        break;
                    default:
                        break;
                }
            }

            window.onload = function init() {
                canvas = document.getElementById(&#39;Canvas1&#39;);
                ctx = canvas.getContext(&quot;2d&quot;);

                blank();
                addBlock();
                animate();
            }

            function up(i) {
                blank();
                animate();
            }

            function down(i) {
                var u = 0;
                var p = 0;
                while(u&amp;lt;4) {
                    if (blockArray[i].y[u] + 1 &amp;gt; 26) {
                        u = 10;
                    }
                    else if ((board[blockArray[i].x[u]][blockArray[i].y[u] + 1]) == -1) {
                        u++;
                    }
                    else {
                        p = u;
                        for (var g = 0; ((g &amp;lt; 4) &amp;amp;&amp;amp; (p = u)); g++) {
                            if ((blockArray[i].x[u] == blockArray[i].x[g]) &amp;amp;&amp;amp; (blockArray[i].y[u] + 1 == blockArray[i].y[g])) {
                                u++;
                            }
                        }
                        if (p == u)
                            u = 10;
                    }
                }
                if (u &amp;lt; 10) {
                    for (var j=0; j&amp;lt;4; j++) {
                        blockArray[i].y[j] +=1;
                    }
                }
                else
                    addBlock();
                animate();
            }

            function right(i) {
                var u = 0;
                var p = 0;
                while(u&amp;lt;4) {
                    if (blockArray[i].x[u] + 1 &amp;gt; 13) {
                        u = 10;
                    }
                    else if ((board[blockArray[i].x[u] + 1][blockArray[i].y[u]]) == -1)
                        u++;
                    else {
                        p = u;
                        for (var g = 0; ((g &amp;lt; 4) &amp;amp;&amp;amp; (p = u)); g++) {
                            if ((blockArray[i].x[u] + 1 == blockArray[i].x[g]) &amp;amp;&amp;amp; (blockArray[i].y[u] == blockArray[i].y[g]))
                                u++;
                        }
                        if (p == u)
                            u = 10;
                    }
                }
                if (u &amp;lt; 10) {
                    for (var j=0; j&amp;lt;4; j++) {
                        blockArray[i].x[j] +=1;
                    }
                }
                else
                    addBlock();
                animate();
            }

            function left(i) {
                var u;
                var p = 14;
                for (var w = 0; w&amp;lt;4; w++) {
                    if (blockArray[i].x[w] &amp;lt; p) {
                        p = blockArray[i].x[w];
                        u = w;
                    }
                }
                if (p &amp;gt; 0) {
                    if ((board[blockArray[i].x[u] - 1][blockArray[i].y[u]]) == -1) {
                        for (var j=0; j&amp;lt;4; j++) {
                            blockArray[i].x[j] -=1;
                        }
                    }
                }
                animate();
            }           

            function block(x, y, type) {
                blockNum += 1;
                this.id = blockNum;
                this.x = [];
                this.y = [];
                this.landed = false;
                this.type = Math.floor(Math.random() * (6)) + 1;
                typeSet(this.type);
            }

            function addBlock() {
                blockArray[blockArray.length] = new block();
            }

            function typeSet(type) {
                i = blockArray.length;
                switch (type) {
                    case 1:
                        square(i);
                        break;
                    case 2:
                        elR(i);
                        break;
                    case 3:
                        elL(i);
                        break;
                    case 4:
                        line(i);
                        break;
                    case 5:
                        zeR(i);
                        break;
                    case 6:
                        zeL(i);
                        break;
                    default:
                        break;
                }
            }


            function animate() {
                fillBoard();
                colorBoard();
            }

            function fillBoard() {
                for (var i = 0; i &amp;lt; 14; i++) {
                    for (var q = 0; q &amp;lt; 27; q++) {
                        board[i][q] = -1;
                    }
                }
                for (var i=0; i&amp;lt;blockArray.length; i++) {
                    for (var q=0; q&amp;lt;4; q++) {
                        board[blockArray[i].x[q]][blockArray[i].y[q]] = blockArray[i].type;
                    }
                }
            }

            function colorBoard() {
                blank();
                ctx.strokeStyle = &quot;white&quot;;
                for(var q=0; q&amp;lt;14; q++) {
                    for(var r=0; r&amp;lt;27; r++) {
                        switch (board[q][r]) {
                            case 1:
                                ctx.fillStyle = &quot;green&quot;;
                                color(q,r);
                                break;
                            case 2:
                                ctx.fillStyle = &quot;orange&quot;;
                                color(q,r);
                                break;
                            case 3:
                                ctx.fillStyle = &quot;cyan&quot;;
                                color(q,r);
                                break;
                            case 4:
                                ctx.fillStyle = &quot;black&quot;;
                                color(q,r);
                                break;
                            case 5:
                                ctx.fillStyle = &quot;yellow&quot;;
                                color(q,r);
                                break;
                            case 6:
                                ctx.fillStyle = &quot;brown&quot;;
                                color(q,r);
                                break;
                            default: 
                                break;
                        }
                    }
                }
            }

            function color(q,r) {
                ctx.fillRect(q*30,(r-4)*30,30,30);
                ctx.strokeRect(q*30,(r-4)*30,30,30);
            }

            function square(i) {
                blockArray[i].x[0] = 7;
                blockArray[i].y[0] = 0;
                blockArray[i].x[1] = 7;
                blockArray[i].y[1] = 1;
                blockArray[i].x[2] = 8;
                blockArray[i].y[2] = 0;
                blockArray[i].x[3] = 8;
                blockArray[i].y[3] = 1;
            }
            function elR(i) {
                blockArray[i].x[0] = 7;
                blockArray[i].y[0] = 0;
                blockArray[i].x[1] = 7;
                blockArray[i].y[1] = 1;
                blockArray[i].x[2] = 7;
                blockArray[i].y[2] = 2;
                blockArray[i].x[3] = 8;
                blockArray[i].y[3] = 2;
            }
            function elL(i) {
                blockArray[i].x[0] = 7;
                blockArray[i].y[0] = 0;
                blockArray[i].x[1] = 7;
                blockArray[i].y[1] = 1;
                blockArray[i].x[2] = 7;
                blockArray[i].y[2] = 2;
                blockArray[i].x[3] = 6;
                blockArray[i].y[3] = 2;
            }
            function line(i) {
                blockArray[i].x[0] = 7;
                blockArray[i].y[0] = 0;
                blockArray[i].x[1] = 7;
                blockArray[i].y[1] = 1;
                blockArray[i].x[2] = 7;
                blockArray[i].y[2] = 2;
                blockArray[i].x[3] = 7;
                blockArray[i].y[3] = 3;
            }
            function zeR(i) {
                blockArray[i].x[0] = 6;
                blockArray[i].y[0] = 0;
                blockArray[i].x[1] = 7;
                blockArray[i].y[1] = 0;
                blockArray[i].x[2] = 7;
                blockArray[i].y[2] = 1;
                blockArray[i].x[3] = 8;
                blockArray[i].y[3] = 1;
            }
            function zeL(i) {
                blockArray[i].x[0] = 8;
                blockArray[i].y[0] = 0;
                blockArray[i].x[1] = 7;
                blockArray[i].y[1] = 0;
                blockArray[i].x[2] = 7;
                blockArray[i].y[2] = 1;
                blockArray[i].x[3] = 6;
                blockArray[i].y[3] = 1;
            }

            function blank() {
                ctx.restore();
                ctx.fillStyle = &quot;blue&quot;;
                ctx.fillRect(0, 0, ctx.canvas.width, ctx.canvas.height);
                ctx.save();
            }

            function blank2() {
                ctx.restore();
                ctx.fillStyle = &quot;purple&quot;;
                ctx.fillRect(0, 0, ctx.canvas.width, ctx.canvas.height);
                ctx.save();
            }

            function rotateImgRight() {
                for(d = 0; d &amp;lt; 180; d++) {
                    setTimeout(rotateImg, 50);
                }
            }

            function rotateImgLeft() {
                for(d = 0; d &amp;lt; 180; d++) {
                    setTimeout(rotateImg2, 50);
                }
            }

            function rotateImg2() {
                degrees = degrees - 0.5;
                radian = (Math.PI / 180.0) * degrees;

                blank();
                ctx.translate(ctx.canvas.width/2, 700);
                ctx.rotate(radian);
                ctx.drawImage(srcImg, -srcImg.width/2,-srcImg.height/2);
                slide = (degrees / 90) % 4;
            }

            function rotateImg(x,y) {
                degrees = degrees + 0.5;
                radian = (Math.PI / 180.0) * degrees;

                ctx.translate(x,y);
                ctx.rotate(radian);
                ctx.drawImage(srcImg, -srcImg.width/2,-srcImg.height/2);
                slide = (degrees / 90) % 4;
            }
        &amp;lt;/script&amp;gt;
    &amp;lt;/head&amp;gt;
    &amp;lt;body&amp;gt;
        &amp;lt;div style=&quot;width: 100%; text-align:center&quot;&amp;gt;
            &amp;lt;canvas id=&quot;Canvas1&quot; width=&quot;421&quot; height=&quot;690&quot;&amp;gt;Your browser does not support canvas.&amp;lt;/canvas&amp;gt;
        &amp;lt;/div&amp;gt;
    &amp;lt;/body&amp;gt;
&amp;lt;/html&amp;gt;
&lt;/code&gt;&lt;/pre&gt;

        </summary>
    </entry>
    <entry>
        <id>http://stackoverflow.com/q/9194133</id>
        <re:rank scheme="http://stackoverflow.com">0</re:rank>
        <title type="text">JavaScript Mobile Drag and Drop</title>
        <category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="javascript"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="jquery"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="android"/>
        <author>
            <name>Jonathan</name>
            <uri>http://stackoverflow.com/users/555017</uri>
        </author>
        <link rel="alternate" href="http://stackoverflow.com/questions/9194133/javascript-mobile-drag-and-drop" />
        <published>2012-02-08T13:21:56Z</published>
        <updated>2012-02-08T13:21:56Z</updated>
        <summary type="html">
            &lt;p&gt;I was testing out an interface I built using jQuery UI draggable, droppable and sortable and noticed that the drag and drop doesn&#39;t work in the mobile browser.  I suppose there is a different way in which events are fired in the mobile browser.&lt;/p&gt;

&lt;p&gt;Are there any JavaScript frameworks yet, that support drag and drop in the mobile browser?&lt;/p&gt;

&lt;p&gt;If not, any ideas on how one could go about putting together some basic drag/drop functionality?&lt;/p&gt;

        </summary>
    </entry>
    <entry>
        <id>http://stackoverflow.com/q/9194010</id>
        <re:rank scheme="http://stackoverflow.com">0</re:rank>
        <title type="text">Get htaccess URL params in JavaScript</title>
        <category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="javascript"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term=".htaccess"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="url"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="get"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="params"/>
        <author>
            <name>Daniel</name>
            <uri>http://stackoverflow.com/users/1197230</uri>
        </author>
        <link rel="alternate" href="http://stackoverflow.com/questions/9194010/get-htaccess-url-params-in-javascript" />
        <published>2012-02-08T13:14:19Z</published>
        <updated>2012-02-08T13:21:31Z</updated>
        <summary type="html">
            &lt;p&gt;Is there any way in Javascript to get the parameters ume modified URL with htaccess?
As an example: www.website.com/argument/1/argument/2
Where &quot;/argument/2&quot; = &amp;amp;product_id=2
There is some way to pick up these parameters in JavaScript?&lt;/p&gt;

        </summary>
    </entry>
    <entry>
        <id>http://stackoverflow.com/q/9194025</id>
        <re:rank scheme="http://stackoverflow.com">0</re:rank>
        <title type="text">Get original definition of redefined function</title>
        <category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="javascript"/>
        <author>
            <name>asleepysamurai</name>
            <uri>http://stackoverflow.com/users/623548</uri>
        </author>
        <link rel="alternate" href="http://stackoverflow.com/questions/9194025/get-original-definition-of-redefined-function" />
        <published>2012-02-08T13:15:14Z</published>
        <updated>2012-02-08T13:21:21Z</updated>
        <summary type="html">
            &lt;p&gt;I am writing a bookmarklet which performs some function on a page. As part of this function I need to use &lt;code&gt;getElementsByClassName&lt;/code&gt;. However, during testing I found that several websites have redefined &lt;code&gt;getElementsByClassName&lt;/code&gt; to a custom method. Presumably this was done in order to support &lt;code&gt;getElementsByClassName&lt;/code&gt; in all browsers. &lt;/p&gt;

&lt;p&gt;The implementation of custom &lt;code&gt;getElementsByClassName&lt;/code&gt; is a bit sloppy and fails for several of my use cases. Is there any way I could get the original definition of &lt;code&gt;getElementsByClassName&lt;/code&gt;?&lt;/p&gt;

&lt;p&gt;In the chrome javascript console: &lt;code&gt;getElementsByClassName&lt;/code&gt; points to a native function. Is there a way to access this native function, now that &lt;code&gt;getElementsByClassName&lt;/code&gt; has been redefined?&lt;/p&gt;

        </summary>
    </entry>
    <entry>
        <id>http://stackoverflow.com/q/9190496</id>
        <re:rank scheme="http://stackoverflow.com">3</re:rank>
        <title type="text">Showing text from Resources.resx in javascript</title>
        <category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="javascript"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="asp.net-mvc-3"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="encoding"/>
        <author>
            <name>stitch7c0</name>
            <uri>http://stackoverflow.com/users/1196684</uri>
        </author>
        <link rel="alternate" href="http://stackoverflow.com/questions/9190496/showing-text-from-resources-resx-in-javascript" />
        <published>2012-02-08T09:21:12Z</published>
        <updated>2012-02-08T13:21:17Z</updated>
        <summary type="html">
            &lt;p&gt;this is example code in mvc3 razor: &lt;/p&gt;

&lt;pre&gt;&lt;code&gt;@section header
{
    &amp;lt;script type=&quot;text/javascript&quot;&amp;gt;

        $(function() {
            alert(&#39;@Resources.ExampleCompany&#39;);
        });
    &amp;lt;/script&amp;gt;
}

&amp;lt;div&amp;gt;
    &amp;lt;h1&amp;gt;@Resources.ExampleCompany&amp;lt;/h1&amp;gt;
&amp;lt;/div&amp;gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;Code above this is just only example but aslo shows my problem with encoding. 
This variable @Resources.ExampleCompany is a file resources.resx with value ExampleCompany = &quot;Twoja firma / Tw&#243;j biznes&quot;&lt;/p&gt;

&lt;p&gt;In javascript alert shows the &quot;&lt;code&gt;Twoja firma / Tw&amp;amp;#243;j biznes&lt;/code&gt;&quot;&lt;/p&gt;

&lt;p&gt;Why character &#39;&#243;&#39; is &#39;&amp;amp;#243&#39; ? What am i doing wrong? &lt;/p&gt;

&lt;p&gt;In html tag &lt;code&gt;&amp;lt;h1&amp;gt;@Resources.ExampleCompany&amp;lt;/h1&amp;gt;&lt;/code&gt; is display correctly.&lt;/p&gt;

        </summary>
    </entry>
    <entry>
        <id>http://stackoverflow.com/q/9193558</id>
        <re:rank scheme="http://stackoverflow.com">0</re:rank>
        <title type="text">Jquery/Javascript Flickr Gallery.. Need help badly</title>
        <category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="javascript"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="jquery"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="flickr"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="image-gallery"/>
        <author>
            <name>Tyler Gerig</name>
            <uri>http://stackoverflow.com/users/1197182</uri>
        </author>
        <link rel="alternate" href="http://stackoverflow.com/questions/9193558/jquery-javascript-flickr-gallery-need-help-badly" />
        <published>2012-02-08T12:45:26Z</published>
        <updated>2012-02-08T13:18:02Z</updated>
        <summary type="html">
            &lt;p&gt;So i&#39;m working on a project that basically takes the user&#39;s input as a &quot;tag&quot; of sorts for flicker and stores it, to then reuse it to make a gallery of the flicker images it pulls up from the tag. Now I think i&#39;ve got mostly what i&#39;m trying to do... but It&#39;s just not working 100%... or really at all because none of the images show up anymore, but here&#39;s my code&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;&amp;lt;head&amp;gt;
    &amp;lt;meta charset=&quot;utf-8&quot; /&amp;gt;
    &amp;lt;title&amp;gt;Image Gallery&amp;lt;/title&amp;gt;

    &amp;lt;script src=&quot;http://ajax.googleapis.com/ajax/libs/jquery/1.7/jquery.min.js&quot;&amp;gt;&amp;lt;/script&amp;gt;
    &amp;lt;script src=&quot;js/index.js&quot;&amp;gt;&amp;lt;/script&amp;gt;

    &amp;lt;script&amp;gt;
        $(function() {

            $(&quot;#test&quot;).keyup(function(){
                var value = $(this).val()

                $.getJSON(
                    &quot;http://api.flickr.com/services/feeds/photos_public.gne?jsoncallback=?&quot;,
                    {
                        tags: &quot;value&quot;,
                        tagmode: &quot;any&quot;,
                        format: &quot;json&quot;
                    },
                    function(data) {
                        $.each(data.items, function(i,item){
                            $(&quot;&amp;lt;img/&amp;gt;&quot;).attr(&quot;src&quot;, item.media.m).appendTo(&quot;#images&quot;);
                            if ( i == 20 ) return false;
                        });
                    }
                );
            };
        });
    &amp;lt;/script&amp;gt;

&amp;lt;/head&amp;gt;
&amp;lt;body&amp;gt;
    &amp;lt;form&amp;gt;
        Input a Tag for Flicker Images: &amp;lt;input id=&quot;test&quot; type=&quot;text&quot; /&amp;gt;
    &amp;lt;/form&amp;gt;

    &amp;lt;div id=&quot;images&quot;&amp;gt;&amp;lt;/div&amp;gt;

&amp;lt;/body&amp;gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;It seems like it&#39;s something very simple but I JUST cannot figure out what i&#39;m doing wrong..&lt;/p&gt;

        </summary>
    </entry>
    <entry>
        <id>http://stackoverflow.com/q/580669</id>
        <re:rank scheme="http://stackoverflow.com">18</re:rank>
        <title type="text">Redirect parent window from an iframe action using JavaScript</title>
        <category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="javascript"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="iframe"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="dhtml"/>
        <author>
            <name>Click Upvote</name>
            <uri>http://stackoverflow.com/users/49153</uri>
        </author>
        <link rel="alternate" href="http://stackoverflow.com/questions/580669/redirect-parent-window-from-an-iframe-action-using-javascript" />
        <published>2009-02-24T06:24:34Z</published>
        <updated>2012-02-08T13:17:32Z</updated>
        <summary type="html">
            &lt;p&gt;What JavaScript do I need to use to redirect a parent window from an iframe?&lt;/p&gt;

&lt;p&gt;I want them to click a hyperlink which, using JavaScript or any other method, would redirect the parent window to a new URL.&lt;/p&gt;

        </summary>
    </entry>
    <entry>
        <id>http://stackoverflow.com/q/9193528</id>
        <re:rank scheme="http://stackoverflow.com">0</re:rank>
        <title type="text">HTML5 appcache, Get a list of cached files in the client</title>
        <category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="javascript"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="html5"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="html5-appcache"/>
        <author>
            <name>NGT</name>
            <uri>http://stackoverflow.com/users/1016930</uri>
        </author>
        <link rel="alternate" href="http://stackoverflow.com/questions/9193528/html5-appcache-get-a-list-of-cached-files-in-the-client" />
        <published>2012-02-08T12:43:36Z</published>
        <updated>2012-02-08T13:16:48Z</updated>
        <summary type="html">
            &lt;p&gt;In my project, I&#39;m trying to use HTML5 appcache to cache static resources like CSS and JS, and &quot;user specific&quot; files such as images and videos. When I say user specific images/videos, I&#39;m trying to have separate files for each user and I need to control order of the file download as well.&lt;/p&gt;

&lt;p&gt;Given the scenario, my manifest file will be dynamically loaded for every user. Is there a way where I can get a list of resources that are already cached in client side? &lt;/p&gt;

&lt;p&gt;If not, is is possible to read the &quot;.appcache&quot; file in client?&lt;/p&gt;

        </summary>
    </entry>
    <entry>
        <id>http://stackoverflow.com/q/9193587</id>
        <re:rank scheme="http://stackoverflow.com">0</re:rank>
        <title type="text">HTML dropdown can&#39;t capture onChange() if there is only one value in dropdown</title>
        <category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="javascript"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="jquery"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="html"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="javascript-events"/>
        <author>
            <name>Debugger</name>
            <uri>http://stackoverflow.com/users/1112925</uri>
        </author>
        <link rel="alternate" href="http://stackoverflow.com/questions/9193587/html-dropdown-cant-capture-onchange-if-there-is-only-one-value-in-dropdown" />
        <published>2012-02-08T12:47:04Z</published>
        <updated>2012-02-08T13:16:18Z</updated>
        <summary type="html">
            &lt;p&gt;I am using Jquery , for selecting value of drop-down.&lt;br/&gt;
I need do do some action on &lt;strong&gt;OnChange&lt;/strong&gt; event (.change in jquery) , But if there is only one option in drop-down I am not able to capture it in onChange event.&lt;br/&gt;
My drop-down is formed dynamically , so don&#39;t know how many options I&#39;ll get how many options , but I am facing problem if there is just one option.&lt;br&gt;
Is there any way to capture OnChange event for  with only one ?&lt;/p&gt;

        </summary>
    </entry>
    <entry>
        <id>http://stackoverflow.com/q/8350877</id>
        <re:rank scheme="http://stackoverflow.com">0</re:rank>
        <title type="text">facebook &quot;apprequests&quot; with Custom URL?</title>
        <category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="javascript"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="facebook"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="actionscript-3"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="facebook-graph-api"/>
        <author>
            <name>mkayyali</name>
            <uri>http://stackoverflow.com/users/375070</uri>
        </author>
        <link rel="alternate" href="http://stackoverflow.com/questions/8350877/facebook-apprequests-with-custom-url" />
        <published>2011-12-02T02:00:07Z</published>
        <updated>2012-02-08T13:15:25Z</updated>
        <summary type="html">
            &lt;p&gt;I have simple question, I am developing facebook app and using this code to make app requests&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;FB.ui({method: &#39;apprequests&#39;,message: &#39;Invite friends&#39;}, requestCallback);
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;I want to set custom url when the user accept the request.
for example: stackoverflow.com&lt;/p&gt;

&lt;p&gt;any suggestions ?&lt;/p&gt;

        </summary>
    </entry>
    <entry>
        <id>http://stackoverflow.com/q/9180707</id>
        <re:rank scheme="http://stackoverflow.com">1</re:rank>
        <title type="text">Mootools DatePicker standalone</title>
        <category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="javascript"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="mootools"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="datepicker"/><category scheme="http://stackoverflow.com/feeds/tag/javascript/tags" term="uidatepicker"/>
        <author>
            <name>Tarek</name>
            <uri>http://stackoverflow.com/users/503412</uri>
        </author>
        <link rel="alternate" href="http://stackoverflow.com/questions/9180707/mootools-datepicker-standalone" />
        <published>2012-02-07T17:16:17Z</published>
        <updated>2012-02-08T13:12:25Z</updated>
        <summary type="html">
            &lt;p&gt;I have a problem using the &lt;a href=&quot;http://mootools.net/forge/p/mootools_datepicker&quot; rel=&quot;nofollow&quot;&gt;Mootools DatePicker&lt;/a&gt; .&lt;/p&gt;

&lt;p&gt;When i  use the standalone version (no clicks needed to show the datePicker , it show an empty box)&lt;/p&gt;

&lt;p&gt;Here is what i have until now : &lt;/p&gt;

&lt;p&gt;&lt;a href=&quot;http://jsfiddle.net/PcHkD/3/&quot; rel=&quot;nofollow&quot;&gt;http://jsfiddle.net/PcHkD/3/&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;As you can see if you click inside the input the date show&#39;s correctly but onLoad it just show an empty box . &lt;/p&gt;

&lt;p&gt;Any idea of what I&#39;m doing wrong ?&lt;/p&gt;

&lt;p&gt;Thanks&lt;/p&gt;

        </summary>
    </entry>
</feed>

