this is currently what i have, if the request times out there is no message returned.
$.getJSON(jsonUrl, function(data){
/*here*/
if (data.stat != "ok") { //checks if query was valid
$('#content').html('content not available');
return;
}
else {...Do Code...}
});
My question is,...
Hi,
I've got two Jquery functions that I can get to work fine alone on the page, but not when I have them both in at the same time. I'm unable to see what I might be doing wrong as I've got similar code working well on other pages.
First function:
$(document).ready(function()
{
$("#add-questions").click(function() {$("#extra-questi...
I am using the following code to remove an element from the DOM tree:
function onItemDeleted(name) {
$("#" + name).remove();
}
Would this be bad for performance since I am not indicating any parent for the element. The element is a TR contained in a TABLE element. The DOM search for this el...
So I'm attending college in the fall, thus my dad won't be quiet about the scholarship thing. I've wrote two wordpress plugin and a jQuery plugin, so I was wondering if there are any legit scholarships I could enter because of these? Thanks for any advice =D
...
I use thickbox to load an html. This html has a form that i need to add some stuff to the database. I have a select box in the main html (the one that i load thickbox from).
What i want to do is when i press the close button in thickbox, the select box has to be updated with the stuff i just added in the database. I was thinking to modi...
http://cambridgeuplighting.com/testimonials
This code works in Safari, IE7, and IE8, but not in FF 3.5.7. The code changes the background of the little background icon when you hover over a div.
jQuery(function( $ ){
$('.oneThird').hover(function(){
$(this).find('span.icon').css( {'background-position-y': '-60px'} );
}, function()...
Does jQuery allow us to use .each loops for live elements?
I'm creating radio buttons on the fly and need to loop over all of them, but the .each loop doesn't seem to work on live elements.
If jquery is not supporting this kind of live looping, is there any other way to accomplish this?
...
I need an import tools for a web app. I've been looking around and found some, just not sure about their stability. I'm using the Zend Framework for part of the project and was hoping I could find an import tool there, since I already have the framework, but couldn't see one...am I looking in the wrong place?
I would like the web us...
I have inherited a project, that provides an order form to a customer.
The order form is a table, and the adding to cart is (meant to be!) handled with jQuery.
Code I have to work with looks something like this:
<table>
<form id="prod1" method="post" action="">
<tr>
<td>Prod Name</td><td><input type="text" na...
I'm using the following jquery code to show a contextual delete button only for table rows we are hovering with our mouse. This works but not for rows that have been added with js/ajax on the fly...
Is there a way to make this work with live events?
$("table tr").hover(
function()
{
},
function()
...
in firefox when im inside a input textbox and press down the up/down arrow key it doesn't autorepeat. how can i make that happen and control how many keypress it will fire up per sec?
UPDATE: i use:
$('#search_view #search').live('keydown', function(event) {
if(event.keyCode == 40) {
// code
}
});
but it just execute t...
Can you guys help me out with this? I've got a form and it has a textarea where the user will paste in some text. I want to use jQuery to send the text they paste to a php script which will decode it and output some information. I've got a div, and I want that div to be updated with the html my script outputs.
...
CSS: is it possible to have a DIV that is both centered horizontally and fixed to the bottom of the browser? I'm using a set width and height for the internal div.
I've tried putting a div with position:relative inside a fixed outer div, and that aligns things vertically but then the outer div is not centered and I'm back to square one....
with firebug i only knows how to see what ajax-files are called.
i have a jquery mouse click event handler bounded to a link element.
is it possible to see what javascript code is used when clicking on an element in case you forgot if you got an event handler or other javascript code coupled to it?
...
What sort of selector would be I need in order to insert after the parent (divouter) of the test3 class in the example below? Thanks.
<div class='divouter'>
<div class='divinner'>
<input class=test1></input>
</div>
</div>
<div class='divouter'>
<div class='divinner'>
<input class=test2></input>
</div>
</d...
I have about 40 questions in a survey that need to be validated all the same way. What's the easiest way to do this without writing every validation down?
For example: Every question must be a natural number, maxlength of 2, and value less than 12.
Using jQuery validation
...
i am trying to get the text of the selected drop down
I'm trying:
$(document).ready(function() {
$("#product_category_id").change(function(){
alert($(this).val())
})
});
Also, how do I set option of a drop down to a specific option:
$(document).ready(function() {
$("#product_category_id").change(function(){
...
I have a simple jQuery AJAX funciton:
$.ajax({
type: "GET",
url: "json/" + address,
dataType: "json",
timeout: 1000,
data: "username=" + username + "&paging_limit=" + paging_limit,
success: function(json){alert("somthing")},
error: function(){alert("somthing else")}
});
I get the following error in Firefox (3.6) when the req...
Hi,
I just created an image gallery at http://nu-lightbox.appspot.com/, a google app engine. I tested this website with firefox 3.5 in Windows XP and Ubuntu Linux. If you open the website and click on the circular blue arrowed button, you will notice how jaggy (not smooth) the animation is.
The weird thing is when I open the HTML pag...
How would I write an event in jQuery so that if I click any of the links it'll delete not the divouter surrounding it, but the divouter before it?
<div class='divouter'>
<a href='#'>Link</a>
</div>
<div class='divouter'>
<a href='#'>Link</a>
</div>
<div class='divouter'>
<a href='#'>Link</a>
</div>
<div class...