javascript

$().buttonset not working on dialog modal box JQUERY

Hello everyone! I've done a dialog box that contains a form inside it, and I would like to add some jquery fancy items to it. I've been trying with $().buttonset() as I've done with most of my radio buttons in the application, in order to get a coherent IU for my application. The thing is that, even if following the rules specified, t...

How to run a javascript when browser process is killed?

Hi, I hav onUnload="cleanup()" defined in my html body tag. The cleanup() method in javascript is function cleanup() {--clean up session--}. But when the browser is terminated by killing the process using task manager, I want to do the same action as cleanup. How can this be done? ...

Move document.ready function to a separate javascript fucntion?

Hi, Is it possible to move the following code within a jQuery document.ready function into a separate javascript function, so that it can be called just like any other javascript function, i.e.: <script type="text/javascript"> $(document).ready(function() { $('div#infoi img[title]').qtip({ position: { adjust: { x:-1...

How can I get the followers of a user on twitter, then get posts from those followers over a period of time so i can create a database?

I've been assigned a research project to enhance social networking based adaptive e-learning and to do so I need to be able to extract several (hundreds, maybe thousands) of status updates or tweets in order to perform factor analysis on key words. Apparently this can be done with javascript but I have never used javascript before so I'...

Show hidden scrollbar

A client is opening our website into a popup window using JavaScript with window.open. They are turning off scrollbars and making the window a fixed height, causing the pages to not be scrollable. I control the code of the website being loaded this way, but not the calling JavaScript. Is there any way I can force the display of scrollbar...

Get the label of click check box

hi i have a page which generate check boxes dynamically and i have the following event which fires every time a user click on any of the check boxes $(':checkbox').click(function() { }); My question is how can i get the text of the check box that has been trigger by the user? Thank you ...

to call a javascript function periodically

I want to call function with arguement periodically. I tried setTimeout("fnName()",timeinseconds); and it is working. But when I add an arguement it won't work. eg: setTimeout("fnName('arg')",timeinseconds); ...

Table Template with Rich UI

Hello, I'm trying to find a html (or maybe flash) table template with rich ui features. I googled it, but couldn't find something that has a rich ui, also looked through jquery, still no luck. Before going any deeper search, I believe someone may have suggestions for me. Thanks. ...

Variable scope in javascript

This is a simple question, but I can't work it out. The specifics aren't important, but here's the gist. I have some code like this: var lat = 0; var lon = 0; if (navigator.geolocation) { navigator.geolocation.getCurrentPosition(function(position) { lat = position.coords.latitude; lon = position.coords.longitud...

Change Vimeo Video using JQuery

Hello all, How can I change the ID of the embedded vimeo video? Here is the embed code for example: <object width="578" height="325"> <param name="allowfullscreen" value="true" /> <param name="allowscriptaccess" value="always" /> <param name="movie" value="http://vimeo.com/moogaloop.swf?clip_id=11527784&amp;amp; server=vimeo.com&amp;sh...

set the focus of a popup window everytime

I have two pages one.html and two.html i am opening a new window using following code //here popup is a global variable popup=window.open('two.html','two'); for the first time a popup window open successfully and get the focus but if i try to open it again without closing already opened popup then two.html is not getting focus for...

Set hidden form field values with JavaScript but request still empty

HI volks, I try to set some hidden form field values with an onclick event. Ok, after I did something like this: document.getElementById('hidden_field').value = 123; I can output the value with the firebug console by entering this: alert(document.getElementById('hidden_field').value); So the values are definitely set. But now when...

AJAX get data from large HTML page as the large HTML page loads

Not entirely sure whether this has a name but basically I have a large HTML page that is generated from results in a db. So viewing the HTML page (which is a report) in a browser directly does not display all contents immediately but displays what it has and additional HTML is added as the results from the DB are retrieved... Is there...

getting file size in javascript

given a path of a file like: C:\file.jpg how can i get the size of the file in javascript? ...

Where Do I Download TraceMonkey?

I can get the Spidermonkey javascript engine from here: http://www.mozilla.org/js/spidermonkey/ And, I know that Tracemonkey is the newer version released after SpiderMonkey but I cannot find the download link for it in Mozilla? Is it released for public use? Should I stick back to SpiderMonkey or switch to Google's V8 altogether - i...

jQuery/javascript delete suffix of variable

I have a variable set to retrieve the id of a specific element which is "PubRecNum-1" (the number is also variable and will change depending on the record number). What I'm needing is a way to only take the first 3 letters of the variable "Pub" (needed for comparison purposes). Any ideas? ...

How do I bind a click to an anchor without a framework (javascript)

I know this is easily done in jQuery or any other framework, but that's not really the point. How do I go about 'properly' binding a click event in pure javascript? I know how to do it inline (I know this is terrible) <a href="doc.html" onclick="myFunc(); return false">click here</a> and this causes my javascript to execute for a JS e...

How do you access byte level information in JavaScript?

The generally accepted answer is that you can't. However there is mounting evidence that this is not true based on the existence of projects that read in types of data that are not basic HTML types. Some projects that do this are the JavaScript version of ProtoBuf and Smokescreen. Smokescreen is a flash interpreter written in JS so if i...

Running a JavaScript code when a browser bookmark is clicked

I've written a code that has successfully created a bookmark for any of the following browsers - IE, Firefox and Opera. <script language="JavaScript" type="text/javascript"> function bookmark() { var title = 'Google'; var url = 'http://google.com'; if (document.all)// Check if the browser is Internet Ex...

Zend and mootools

Hi There, I am trying to write a commenting system with Zend and Mootools, basically mootools provides and modalbox and Zend processes the comment etc. My issue is that I cannot get the ID of the post that the user is commenting on to move from Javscript to PHP. I think it is because the Modal window is an iFrame essentially. Below is...