How can I create a function, that will call another function, and when it completes, fire another callback function?
so existing functions are:
function f1(..) {..}
function myCallback() {...}
Now is it possible to make f1 fire and finish, THEN run myCallback()?
...
I am calling the following jQuery code on page load to test the concept of calling an external web service from the client. The data object in the success callback is always empty. What am I doing wrong?
$.ajax({
url: "http://www.google.com/search",
type: 'GET',
data: { q: "green tea" },
success: function(data) { alert(...
i have a vector illustrator file with all the counties of california as distinct paths. i need to have these counties be links to other pages online. is there a way to automatically generate an html imagemap from this file? illustrator provides an export as jpg function that has options for polygonal imagemap shapes, but it isnt working....
I ran into a usage of jQuery's die that is either a custom extension or not documented... According to the jQuery docs, the second parameter should be a method (http://api.jquery.com/die/). I'm seeing a usage where the second parameter is selector string. Does anyone know what this does?
$("*").die('click', '.optionsMenu');
I'd...
Hi there, I'm trying to implement a very simple footer notification element to slide up for a moment, then slide back down. I'm using:
$('button').click( function () {
$('#message-box').slideUp('slow').delay(1500).slideDown('slow');
});
However, when you click the button, it delays for the 1500 ms then slides up and never slides d...
I am having trouble passing the url of $.PhotoUpdater.doUpdate(url) to do the doUpdate function.
Firefox returns this error :
useless setTimeout call (missing quotes around argument?)
[Break on this error] timer = setTimeout($.PhotoUpdater.doUpdate(url), 5000)
my code:
$.extend({
PhotoUpdater: {
startUpdate: function(organi...
I'm converting a Web Forms app to MVC.
I have a js method that calls a Controller action method (below)
function GetUsers(pageNum) {
var sortTh = $('thead .sort', document.getElementById('usersTable'));
var sortCol = sortTh.find('a').attr('rel');
// { } is declarative shorthand for new Object().
var userRequest = {};
userRequ...
I'm trying to use jQuery to fill in a form in an iFrame. Do you see anything wrong with this code? It should be selecting the inputs and filling them in with the values TESTuser and TESTpassword.
Here is the HTML from the iFrame :
<td align="right"><label for="rcmloginuser">CSID</label></td>
<td><input name="_user" id="rcmloginuser" ...
I've been trying to figure out how to work this jQuery Form plugin to upload a file, but it doesn't seen to do what I need it to do.
I have the jQuery:
$('.upload-file').click(function()
{
$('#htmlForm').ajaxForm({
// target identifies the element(s) to update with the server response
target: '#htmlExampleTarge...
I'm currently trying to use customized scroll bars in Drupal. This with jScrollPane which is relying, like Drupal, on jQuery. The problem is the following. Usually the page looks like that:
http://granjow.net/uploads/temp/drup-jscrollbar1.jpg
Now, during scrolling, some boxes flow over:
http://granjow.net/uploads/temp/drup-jscrollbar2...
Sorry for my english,
I have this html code:
<tr>
<td><input type="checkbox" class="chk" /></td>
<td><div class="disabled">text to hide 1</div></td>
<td><div class="disabled">text to hide 2</div></td>
</tr>
next, I have a jQuery line to hide all class="disabled" items :
$("div.disabled").hide() ;
So, I want to show disabled ...
I have a custom error script that displays custom error messages on a page if a user tries to submit a form and it fails validation.
On the focusout of the input element (the input that failed validation) I am trying to remove the DOM element I added, but its removing all of the DOM elements with the class name I specify that exist on t...
I'm viewing a page, and want to know which event is fired when I click on a button, and I want to trace through the .js files to help me learn what is going on.
Is this possible?
...
currently I have the a basic jQuery gallery:
<ul>
<li>IMAGE</li>
<li>IMAGE</li>
</ul>
// with NAV stuff
I cycle through the images with animations and everything works great.
However, my client "NEEDS" another setup, whereby there will be a new page per slide. GQ.com is a good example of this. Click the link to check it out.
...
Hi All,
given a hierarchical view on my asp.net mvc page is it possible to type in the search field and have the treeview dynamically filter out the tree as more letters are typed but leave the root nodes alone (like don't include north,south,east,or west)?
Thanks,
rod.
[TextBox filter goes here]
[treeview control below] /* I'm look...
So I have a grid on a page that displays tablular data, with a checkbox by each row.
So in this situation, when a checkbox is clicked, allot of things will react on the page potentially.
Also, if a button is clicked, again allot of things will potentially react on the page.
So say if someone checks a checkbox, the row should be highli...
Don't be afraid to use any technical jargon or low-level explanations for things, please. I'm savvy enough with computer architecture and low-level programming languages to comprehend any optimizations or memory management techniques, as well as complex structures (classes, member variables, etc.)
My primary focus of code is web-based a...
I am currently working on downloading the data automatically on this page:
http://jcmramp.pjm.com/jcmRamp/ramp-data.jsp
I would like to somehow be able to control the URL so that, say, when I use the URL:
jcmramp.pjm.com/jcmRamp/ramp-data.jsp?directionSlt=1
the option selected for Location parameter would be PJM and when I do
jcmr...
Hello,
How can I replace following lines with links to the Google jQuery API?
1st line is already done.
<script type="text/javascript" src="//ajax.googleapis.com/ajax/libs/jquery/1.3.2/jquery.min.js"></script>
<script type="text/javascript" src="catalog/view/javascript/jquery/tab.js"></script>
<script type="text/javascript" src="ca...
I need to call this from the code behind if there is a certain value read in from a
query string variable ie
x as string = request.querysting("Var")
if x = 'Hide" then
function guestHide()
{
$(".panel").hide("slow");
}
end if
...