When I resize the browser window to a lower width than 477px, window.innerWidth or window.getSize().x (using mootools) still returns 477px.
Anyone ever had that problem? What's going on here?
The problem occurs in Firefox and Chrome.
...
Hi all, this is how i normally check for youtube url validity using javascript. It works great but fails for urls with "-" before the video id eg http://www.youtube.com/watch?v=-pIaQpwYEjY
Any remedy available as I'm not well versed with regex
var matches = $('#as_url').val().match(/^http:\/\/(?:www\.)?youtube.com\/watch\?(?=.*v=\w+)(?...
I came across a jQuery lightbox plug-in called PrettyPhoto. Seems very interesting. At the bottom of documentation I noticed a section about Public API, which I paste in its entirety below:
Version 2.5 introduced an easy to use API. You can now open prettyPhoto from anywere. The public API functions are the following:
$.prettyPhoto...
Consider a web page with of links to files. FlashGet's normal operation is by right-clicking, and selecting from the context menu.
I want to make it easy to launch FlashGet, and make a selection of file type to my desired file type without downloading any other resources being linked to.
For example, my desired file type is .rar , and...
Trying to make a JSONP request to yellowapi (Yellow Pages), even specifying a callback is giving me the "invalid label" error. Here is what I have so far:
$.ajax({
dataType: 'jsonp',
cache : false,
url: "http://api.sandbox.yellowapi.com/FindBusiness/",
data : "apikey="+testingPurposes+"&what="+what+"&where="+where+"
&fmt=JSON&pg...
I need to make a request to a different domain with Ajax in jQuery!
Should I use iframe?
Edited:
On facebook.com working chat, with few different domain name?
GET http:// www.facebook.com/ajax/presence/reconnect.php?__a=1&reason=6&iframe_loaded=false&post_form_id=23be2df75b74a0bcb61358814c56ba4f 200 OK
GET http://0.50.channel.facebo...
I am trying to get a list of mutual friends of myself and another user but none of the API I found in the documentation works. Either I get some weird permission errors that I can only get my friends list and no other user or I get the following error:
Fatal error: Call to a member function friends_getMutualFriends() on a non-object in ...
Hi everyone.
Maybe this question has been asked before but I am struggling in doing this. I have got a php file which does not include any piece of php code (might be in the future),it includes just javascript and some html. What I want to do is clicking a button in this php file to send some amount of data to another php file.
put it ...
I currently have a python and C version of wsproxy (WebSockets to plain TCP socket proxy) in noVNC. I would like to create a version of wsproxy using node.js. A key factor (and the reason I'm not just using existing node WebSocket code) is that until the WebSocket standard has binary encoding, all traffic between wsproxy and the browser/...
Hi, everyone. I've got a string looks like
var s = "2qf/tqg4/ad(d=d,s(f)d)"
And I've got another string
var n = "abc = /fd/dsf/sdf/a.doc, "
What I want to do is insert n after the first '('
So it will look like
"2qf/tqg4/ad(abc = /fd/dsf/sdf/a.doc, d=d,s(f)d)"
Thanks very much!!!
...
Using the Google Javascript API I am trying to authenticate myself (locally) to create a new event in my calendar. However, I get an error (see below) stating that my "next" parameter is bad or missing when I execute the log-in portion of the script. I am following the data api interactive samples for "Create a single event".
Update 1: ...
How can I set up the designed in visual studio to put a space after my javascript functions?
At present when I press the return key I get this
var myfunc = function() { .... };
When I want this
var myfunc = function () { .... };
Know its a setting somewhere but cant find it - will help with my JSlinting!
...
I wrote an office addin and with which there is a function : openFile(String path)
and in the office addin I embed a browser object and with that I can embed a webpage on the office addin, and now I hope I can call the C# function "openFile" and pass in a path in the webpage with javascript, and let office open the designated file for me...
Hi,
I have two divs. Say div1 and div2. By default div2 is invisible.
When the user hovers over div1, I need to display div2. Now if the div2 is hovered then i need to keep displaying this div2 (even if div1 is no longer hovered), otherwise reset the div2's visibility to hidden.
How do I keep div2 visible while hovered?
...
Here is the format of the css I'm trying to edit using jquery.
/*8d*/ .class{color:#444444;}
/*5d*/ .class{background-color:#444444;}
/*3f*/ .class{color:#444444;}
/*9d*/ .class{color:#444444;}
I want to replace several entire lines within using Regular Expressions. For example, How do I select line 5d the replace with "/*5d*/ .new{bo...
I just want to select the text in a paragraph when I click or double click the "p" tag.Not highlight,just like using mouse to make a select area to choose text to be selected!
thank you very much!!
I am so sorry!
It is about a web page function.I have several paragraph and *.rar file link address on the page, and I want to select all...
The following page will not display in ie.
http://dl.dropbox.com/u/6957663/muchWorth.html
I believe it has to do with the javasscript I implemented but I'm not sure.
Is there some file encoding I am missing?
I am on ubuntu linux in gedit.
...
I've been using this plugin to block the UI: http://jquery.malsup.com/block/
The plugin works excellently, it's just that I'd be enormously surprised if jQuery UI didn't do such a thing already, given that it must do effectively the same thing for it's Dialog feature.
How does one block the UI using JQuery UI?
...
I am trying to move everything contained within the div id "tile", to the center of the web browser. By default the CSS is undefined and it appears on the left side of the browser. What I would like to do is move the entire div to the center using javascript when the button "move" is clicked.
The html is shown directly below, and the a...
Possible Duplicate:
Javascript swap array elements
I have a array like this:
this.myArray = [0,1,2,3,4,5,6,7,8,9];
Now what I want to do is, swap positions of two items give their positions.
For example, i want to swap item 4 (which is 3) with item 8 (which is 7)
Which should result in:
this.myArray = [0,1,2,7,4,5,6,3,8,9]...