Tag: google chrome

Origin is not allowed by Access-Control-Allow-Origin?

I am trying to fetch weather information from Yahoo using XHR in a Chrome extension: $.ajax({ url: “https://weather.yahooapis.com/forecastrss?w=” + 250226 + “&u=c”, dataType: ‘xml’, success: function(data) { console.log(data); } }); and I have requested the permission to cross-origin using this script: $(“button”).click(function(){ chrome.permissions.request({ origins: [‘*://weather.yahooapis.com/*’] }, function(granted) { if (granted) { console.log(“Success creating permission.”); //successful […]

Javascript WYSIWYG editor that works in a chrome packaged app

Are there any WYSIWYG editors that work in a chrome packaged app. Most of them don’t seem to work with the increased security policy. Chrome complains about TinyMCE using unload. I have also tried nicedit, cleditor, wymeditor and a few others(can’t quite remember).

Chrome getElementsByTagName() with xml DOM returns improper NodeList

Possible Duplicate: Chrome: Disable same origin policy so a little background information about my issue: Writing a JavaScript file for a gallery; pulling data from an xml file, here. Loading the DOM Object with XMLHttpRequest(), using async loading. Parsing the responseText with a DOMParser to make a DOM object. Works on FireFox, fails on Chrome. […]

Chrome for mobile input field maxlength behaviour

I’ve noticed that when using the maxLength attribute on an input field, Chrome for mobile will allow more characters than the maxLength to be entered, then cut back to the max length amount when the field loses focus. Chrome for mobile is the only browser that I’ve seen exhibit this particular behaviour. This has been […]

Capturing keypress, directing to specific element in Chrome

I am building a chat application and I am trying to make sure that any time a user presses a key, the key they press ends up getting entered into a specific element (an editable HTML document ui.rte1Content in an iframe ui.rteIFrame, to be exact). This should happen no matter which element on the page […]

order of execution of js in iframes set by javascript

I am trying to understand the behavior of code execution order in iframes and it seems to be different in FF and chrome. The use case is simple: we have two functions in top frame, creation manager and window creation. window creation function finds an iframe and sets its src attribute to javascript:top.writeBody(document)’ where writeBody […]

window.open doesn't work in geolocation success callback

I have a link on a page that should open a new tab and show driving directions on Google Maps from the users location via HTML5 Geolocation to point B. I have set up a jsbin of how i’ve tried to implement this. Here’s the link: JSBIN. I guess it has to do with that […]

Developing chrome extension

I am a beginner in developing chrome extensions , i have written the following code in popup.html file which i linked to default_popup of browser_action of my extension <!DOCTYPE html> <html> <head> <script type=”text/javascript” > function returnname() { var x=document.getElementById(“name”).value; alert(x); }; </script> </head> <body> <p>Username : <input type=”text” id=”name” height=”20″ width=”50″ /> </p> <p>Password […]

Dynamically set background image not showing in Chrome

I came across an issue with the background image of a div not showing in Chrome. A website I’m working on has two image containers sitting on top of another: The one with the lower z-index shows the currently selected image while the one with the higher z-index is used to preview other images when […]

Single Application in Chrome

Does anyone know a way to detect only 1 single instance of a web application is running in Chrome? I’m currently using a flag using localStorage but when stuff like browser crashing, that flag is still there so the next time I try to access the app it will give me an error because it […]