jquery

ASP.Net MVC post value in a combo box

We have a list of items on a ASP.Net MVC page, each row in the list has a combo box. When the user selects a value in the combobox, we would like the form to be submitted. We also need to be able to read which line the user was on and which value was selected. We have given each combobox a name that links it to the row on which it was ...

jQuery toggleClass issue in IE

The following jQuery code works fine in FireFox but not in IE. The loop executes the expected number of times(verified by counting alerts) but the hidden classes do not become visible. $("a.riskInformationButton").bind("click", function(e){ var toggler = $(this).parent().parent().next(); while(!toggler.hasClass("s...

How do you inject urls into jquery AJAX using ASP.NET MVC?

I'm trying to use AJAX via jquery with ASP.NET MVC, but I'm not able to hit my controller action and I think it might be because my url is not specified correctly. The problem is, I'm not sure what is should be! Say I have a controller named "Home", and an action named "AjaxAction", would the jquery look like this? $.get("Home/AjaxAct...

jquery droppable area

Hi All, I have one div a i.e the superset of div b but i want to make the area div a - div b as droppable. How can i do that?? ...

How to increase performance of jQuery

i have an chat application written in jsp and jQuery. I have used the setTimeout method for threads who are continuously posting request in some URL. My browser is hanging after some time and cpu utilization is very high. Is there any way to increase performance of JS? ...

jQuery CRUD in ASP.NET MVC

Seeing as though our team maintain an Intranet which has clients users guaranteed to have javascript enabled we know that we can step in and start using jQuery more "thoroughly". Our system is very large, so even though we use areas in our ASP.NET MVC application the sheer amount of pages to add, edit, delete and view sets of data per s...

jquery validate and asp.net - clear rules?

hey folks, I'm using the fantastic jquery .validate plugin from Jörn Zaefferer at bassistance I'm using asp.net, so have one long form, though the form is broken up into 3 sections via a jquery accordion with buttons to switch between accordion panes. I want the button in pane one to validate pane one fields, same with pane two, etc...

Modal Popup for Selecting an Option [jQuery]

In my application I want to present a list of choices for a user to pick from in a modal popup. I'll be using the value they select in the 'parent' page. I've looked into nyroModal, but none of the examples include a return value after the modal closes. I'm assuming this is because its opening up the content with a new HTTP request, wh...

Handling errors in jQuery.getScript

jQuery's getScript function doesn't seem to support an error callback function. I can't use the global ajax error handling code here, a local error function would be ideal. Documentation that the callback gets data/textStatus seems incorrect - the callback gets neither. Any suggestions on how I detect that a call to getScript failed (...

Disabling radio buttons with jQuery

I'm trying to disable these radio buttons when a the loadActive link is clicked but for some reason it only disables the first in the order and then skips the rest. <form id="chatTickets" method="post" action="/admin/index.cfm/"> <input id="ticketID1" type="radio" checked="checked" value="myvalue1" name="ticketID"/> <input id="t...

jQuery AJAX polling for JSON response, handling based on AJAX result or JSON content

I'm a novice-to-intermediate JavaScript/jQuery programmer, so concrete/executable examples would be very much appreciated. My project requires using AJAX to poll a URL that returns JSON containing either content to be added to the DOM, or a message { "status" : "pending" } that indicates that the backend is still working on generating a...

jQuery - Best way to determine a child element inside list item

From the following HTML I need to figure out which List tag has class active and further on for the active List I need to find the relevant value <li class="active"> <a href="value1" class="Tab1">Services</a> </li> <li><a href="value2" class="Tab2">Create Account</a> </li> <li><a href="value3" class="Tab3">Modif...

Making a form re-enabled after it has been disabled, using jQuery.

I currently have my code set to disable the submit button when the field is submitted. Is there a way I can make it re-enable the submit button later? The first half of my code. $("#segment").submit(function () { $(':submit').attr('disabled', 'disbled'); The second half of my code. if (data == 'success') { $("#se...

How to use jQuery before it is referenced?

I would like to put jQuery at the bottom of the body tag but at the sametime, I have ASP.NET user controls that could potentially use jQuery methods (ie: $()) placed above where jQuery's script is referenced. When this happens, an error is thrown reading that $() is not defined or does not exist. How can I defer the execution of the ja...

Weird bug when combining an ASP.NET updatepanel with the jQuery UI DatePicker

Hi all I've created a page which combines an inline jQuery UI datepicker . I wan't to initiate a callback to the updatepanel when the user clicks a new date to update some data. Now, this page has multiple updatepanels (don't ask :) ), so I need to check which updatepanel did the reload in order to do some stuff clientside. I'm using __...

Modifying jQuery $.ajax() success method during request

In the web app I am working on there is potential for very long running ajax queries. I'm using jQuery's $.ajax method to do something like: this._xhr = jQuery.ajax({ type: "GET", url: "/path/to/service", data: "name=value", success: function(data, message){ // handle a success }, dataType: "json" }); ...

Need to make jquery add css to a table which is added through ajax

I have a webpage... http://beta.charmscorp.com/inspect/projects.php - this webpage is in beta and doesn't currently look super professional and is only half working, also, the server internet connection is slow so it takes a bit to load up the elements properly. Anyways, this page calls other pages through ajax to display in a div. My ...

jquery functions not working properly after .html reload

I have a page with a list of items initially loaded from a include_once('show_calendarV2.php'); line. Next to each item is a delete icon that triggers the following jquery to delete the item from the db and then update the page. $('.delete_schedule_item').click( function() { var id = $(this).next('input[type=hidden]').attr('value'...

jquery simplemodal dynamic height

I'm using the simplemodal popup in jquery, and I would like to set the height of my popup dynamically depending on my content. Currently, it is fixed at 500. If I remove the height property, then it works the first time, but if the content grows, then the height doesn't adjust itself (I have tabs within my popup and each tab loads diff...

jquery tabs load event

Below is jQuery's example of how to get links inside the tabs' panel to load within that panel. $(function(){ $('#example').tabs({ load: function(event, ui) { $('a', ui.panel).click(function() { $(ui.panel).load(this.href); return false; }); } }); }); However, the line ...