global ajax method not working
i have the following ajax code, the global events "ajaxSend" and "ajaxComplete" are not working: any thoughs why? regards $(function(){ $.ajaxSetup ({ cache: false }); $("div#ajax_loading_icon").bind("ajaxSend", function(){ $(this).css(border:"1px solid red") }).bind("ajaxComplete", function(){ $(this).css(background:"url('')") }) $('#submit_maj_password_email').click(function(){ var _data= $(this.form).serialize() $.ajax({ type: 'POST', //contentType:
jquery issue on marquee script
Following the info in here; http://www.givainc.com/labs/marquee_jquery_plugin.htm I set up a demo page on my Wordpress site to see if I could get it working... It does not error, it just does not scroll as I expected it to. I have the links in the HEAD section as follows: <script src="http://www.myFallRiver.ca/wp-includes/js/jquery/jquery.js?ver=1.3.2" type="text/javascript"></script> <script type="text/javascript" src="http://www.myFallRiver.ca/wp-includes/js/jquery/jquery.marquee.js"></script>
Question about siblings() and tooltip
Hello, I'm trying to create a tooltip from a simple list. When i hover over a class "tooltip", i want to get the corresponfding sibling div Here's a sample of the code HTML: -------------------- <ul> <li> <a class="tooltip" href="">thumbnail 1</a> <div class="container-tooltip" style="display:none;"> <img src="..." alt="" /> <p>text goes here</p> <p>more text</p> </div> </li> ... <li><a class="tooltip" href="">thumbnail 8</a><div>...</div></li> ... </ul>
Find next element and show
Hello I have this situation where I click the first reply and it shows first respond but problem is when I click second reply only first respond stays showed. How do you show the next one to leavecomment? Here code example: <a class="leavecomment">Reply</a> <div id="respond" style="display:none;">blah</div> <a class="leavecomment">Reply</a> <div id="respond" style="display:none;">blah</div> <a class="leavecomment">Reply</a> <div id="respond" style="display:none;">blah</div> jQuery('.leavecomment').click(
Question using jQuery smooth scrolling.
Hey! I'm a newb to jQuery, but I hear it is the best way to do what I am trying to achieve. Basically I want to be able to do this, http://www.dezinerfolio.com/wp-content/uploads/smoothscrolldemo/df_smooth_scroll.html The only difference is I want to do it to this page, http://www.chriszachary.com/html/Earth.html I want to make it to when you click the arrow at the end of the page, to smooth scroll back to beginning horizontally without just refreshing the page. If anyone could help me achieve
Find table head (th) cells (td)
What i'm currently trying to do is find all columns associated with a table header. For example: <table id="thetable"> <thead> <tr><th colspan="2">Column 1 header</th></tr> </thead> <tbody> <tr><td>Column 1 data</td><td>Column 1 data</td></tr> </tbody> </table> I would be really happy if when something like this would be possible: var jqTh = $( '#thetable thead th:eq(0)' ) jqTh.getTBodyColumns( ).toggle( ); // Get all cells for first th and hide them Thanks in advance, Jos
Global Namespaced Events Not Firing?
It seems that global events that are namespaced do not fire. Please see the following GIST for replication steps. From the code it appears that global events are stored in a cache based solely on the event name, then when triggered, global events are looked up based on both event name and namespace thus it doesn't find them to trigger. Can anyone confirm that this is a bug?
How to convert XML with CDATA to HTML and back again?
I'm receiving XML data via AJAX and the XML includes some CDATA values. The XML needs to be added to the page and then later scraped from the page and sent back as XML via AJAX. Simple Example: I receive - <MyXML> <MyTag> <![CDATA[Hello World]]> </MyTag> </MyXML> and want to end up with: <HTML> <Body> <MyXML> <MyTag> Hello World </MyTag> </MyXML> </Body> </HTML> and then send back
Context lost when using $.post inside a delegated event handler. Bug?
I have some code that's a more involved version of this: $('#container_div').delegate('.trigger_button', 'click', function() { $.post('handler.php', { id: $(this).siblings('.item_id').val() }, function(data) { $(this).siblings('.result_display').val(data.result); }, 'json' ); }); Normally, when I use .post in an event handler, "this" refers to the object that triggered the event. That doesn't happen in this case. When I
[jQuery] height() and width() returning incorrect values in Opera
I'm using height() and width() to find the dimensions of some inline images in the html. FF and IE work fine, but Opera is returning incorrect values. For example, it returns 92px as the width of an image that is actually 160px wide. How can I fix this?
Opera width() & height ()
Hi, i currently ran into an issue where opera returns for any element in the document the viewport values for width & height instead of the element values... i have tested jquery 1.4 & 1.4.2 on opera 9 & 10... FF, IE, Safari are working fine... any tips on this one? thanks daniel
.load .get .post All giving Object doesnot support In IE 8
Hi, Am getting error in just internet Exploer 8. dont know the exacr reson for the first time the same code run 100% right but after a refresh or reload same code give me error object doesnot support this method i also try renadom number with url but still same problem nay one to help tjanks in advance
RemoveClass doesn't work
I've got a problem with removing a class of a element. jQuery does remove the class, when I inspect the element no class is set. But functions especially for the class that has been removed are still executed. This is my code: $('.bewerkbaar').mouseover(function() { $(this).stop().animate( { opacity: 0.6 }, 70); }); $('.bewerkbaar').mouseout(function() { $(this).stop().animate( { opacity: 1 }, 70); }); $('.bewerkbaar').click(function() { alert($(this).attr('class')); $(this).removeClass('bewerkbaar');
jquery ajax codeigniter
Hi y'all, I am new here so please go easy on me! I am using jquery with Codeigniter and I wanted to echo out errors from failed validation or success messages from any successful interaction with my form and it doesn't work. without using ajax in jquery it's fine, takes me to a blank page with errors only but with ajax it doesn't come. Upon looking closely with firebug, I looked at the request made (I am using $.ajax), the response carries the entire webpage of either the page where the form is on
simple getJSON code and memory loss
Below is some simple code asking for json data from flickr periodically. I see it causing increasing memory consumption over time. I even tried a simple json string (from a local server) and it keeps on increasing the memory consumption (so its not probably the json string thats causing it). I checked it via chrome's developer tools and with each call to the server, the increase is proportional. Is there any way to stem the increase in memory leakage. I am a beginner js so i might be totally wrong
Invalid Argument Error on line 113 in Jquery.js
I am using the jquery pikachoose plugin for a gallery and it is throwing errors on line 113 in the js file for IE. Works fine in FF, Safari and Chrome. http://pikachoose.com/ Side Note: I am using multiple galleries on the same page by changing the call name. Not sure if this is the issue or not. My code is: (represents the calling of two galleries for the page) <script type="text/javascript" src="assets/templates/rgb/js/jquery.js"></script> <script type="text/javascript" src="assets/templates/rgb/js/pikachoose.js"></script>
Mouseover/mouseout weirdness
I want to add some captions to images on the following page http://www.ep-studiownetrz.com/projekty.php Unfortunately, I can't use one of the caption plugins because they don't play nice with Fancybox which is also on the page. Anyway, if you roll-over the images you will see that sometimes a caption appears , but sometimes it doesn't (often if i enter the div containing the image from the right). Can any one tell me why the caption loading is erratic ? I've been trying to have the code from various
How to use same id's?
I habe this part of JQuery. It only effects the ditst td id cnc and no other id's with the same name. Any suggestions how to solve this? <script src="http://code.jquery.com/jquery-latest.min.js" type="text/javascript"></script> <script type="text/javascript"> $(document).ready(function() { $('table#pl td#cnc').hide(); $('#hide_cnc').click(function() { if ($(this).attr('checked')) { $('table#pl
Storing jQuery selectors?
Hey all, I am looking to select an element with jQuery via a mouseclick, and then be able to store a reference to that element in the database to retrieve later. Essentially, I am working on a development tool to help me speed up my development time. I want to be able to click on any element on the page, and have the script store a reference for later. I won't know what the structure of the page is, or if the element has an id/class associated with it. I understand how to store it - the database
don't understand delegate
for example I have this item <span id="myid">test</span> with live it is easy: $('#myid').live('click',function(){ //do something }); how to do this with delegate?
parent().css failing in IE - simple jquery
Hi All, I have an extremely simple Jquery function that is failing in IE... $(document).ready(function() { $("ul.sub-menu").parent("li.menu-item").css("background-image", "url(images/nav/navBar_60orangeSubDN.jpg"); }); This simple code results in an error on line 4618 of jquery-4.1.2.js.... The fail code is: if ( set ) { style[ name ] = value; }
how to make tooltip for an image with jQuery?
Hey guys , I need to know how can i make some effect like that : I need to make a tooltip like that please could you tell me how to do that? thanks a lot
Adding specific class for loading content using load() not working in Chrome/Safari.
Hi! I'm using a function to load a page into a div. When I add the class of the element I want to show (.contentpaneopen) Chrome and Safari show no content. It works OK in IE and FF. When I ommit the class it works on all browsers. function loadContent(elementSelector, sourceUrl) { //Works in Chrome en Safari: $(""+elementSelector+"").load(""+sourceUrl+""); //Does not work in in Chrome / Safari (Windows): //$(""+elementSelector+"").load(""+sourceUrl+" .contentpaneopen");
jQuery Click event not being triggered in Firefox?
Hi all, I'm new to jQuery, and am using the following code to capture click on all links with the specific class. $(document).ready(function(){ $('a.candidate').click(function(event){ thumbnail_clicked(event); }); }); Using Firebug, I can see that the document read method is being called, but it appears that the click event method is never called. It's not called during the initial document ready call (I'm not sure if it's supposed to be) and it's not being called when I do click on a link with
Ajax post to a form
Hi guys. I'm trying to send form variables to a php form with POST, via an ajax call. The php logic in the form seems to work when I test it. But when I try to POST via $.ajax, the functions within my success callback don't get called, and no mail is sent. I'm trying to figure out how to diagnose this problem further. I've figured out the selector is correct: the function does get called when the button is clicked. Here is the function in question: (Is there anything obviously wrong with it?) $('#contact-form
checkboxes
Hi , I am new to JQuery. In my page i got a datalist with some checkboxs. SelectAll check box should check all the sub checkboxes only if they are enabled. how can i check whether a check box is enabled or not (disabled or not) . Thanks Ranjith
$.ajax returns "Invalid argument" when VPN'd into a site
Hi guys, I've raised a detailed bug report in the tracker, only to have it closed as I can't reveal the URLs used. So, I was hoping you would be able to help me. Bug: http://dev.jquery.com/ticket/6717 Basically, I'm using a VPN product called iLink by Cognitas. Being on this VPN produces URLs in the following format: https://proxy.domain.com/the-url-you-actually-want For example https://webtopxeu7.domain.com/http://internal.ourdomain.com/Site/default.aspx When I do an AJAX call to a relative URL
Using .ajaxError and passing error function in ajax calls
Hello, I'm currently rewriting all my ajax calls to use the jquery method (much cleaner code! ) and have declared a default ajaxError function, shown below: $(document).ajaxError(function(event, request, settings){ alert("There was an error while communicating with the server. URL: " + settings.url); });However, now I have a few ajax calls where I want to declare an error function in the ajax call. I was hoping that by declaring an error function in the ajax call, it would replace the
jquery ajax not returning the value :S
Hello people, i have this ajax function : function checkTouch(check) { var type = "&OP=CheckTouch&tam="+$('#'+check + ' option:selected').text(); $.ajax({ type: "GET", url: "Validations.php", data:type, dataType: "json", success: function(msg){ return msg.found; }, error:function(response){ alert(response.status + ' ' + response.statusText); } }); } It received well the response but the return msg.found,
Ajax Load and inline javascript.
Hello, Can someone advise, I'm loading some page content with the ajax load event. The loaded content contains some <script> function calls. These appear to get evaluated, but the script ( a google map ) doesn't perform as expected. Is the inline function run with the code on its page, or with the scripts on the page I'm loading it into? Hope that makes sense! Thanks. Ian.
Best way to get true/false from a checkbox?
Hi. I just started to use jquery. What is the easy way to do this: var AllDay = null; function GetCheckBoxValue() { if ($('#myCheckBox).attr('checked') == false) { AllDay = "false"; } else { AllDay = "true"; } } I need to get the true or false from the checkbox. Above works fine, but there most be a smarter way to do it.
help with a jQuery slide
Hi, i am a designer, i am totally noob with java but i want to learn, i am amazed by the things jquery can do, right now i need some help, i am trying to create a slide using jquery, it contains some pictures, it has to auto slide. So i have 5 divs (5 slide frames) behind a bigger div with a background picture (lets call it div6) and each of this 5 divs (each of this divs contains a picture for this slide) slide from behind of the div6 and disappear before the other div slide from behind the div6.
Database data on form using jquery..
how can u display database table in a form using Jquery in ASP.Net??? please answer me as qukly as posible,.. thanks in advance.
How to grab input arrays with unknown index by name?
Hi, i have many inputs like: <input type="hidden" name="combi[<?php echo $sysCompData['combi_id'];?>][desc_features]" value="<?php echo $sysCompData['desc_features'];?>"> I do not know the value of both PHP-Values, they come from a database. I have tried now some hours to grab the values of this array, because i have to compare them to other values in similar inputs. But I simply do not know how? For a simple test i simply want to change the value of the chosen fields. I tried (nearly) everything
$.ajax & post data - can not solve for a few days...
I have really simply code: <script type="text/javascript"> function check(v) { if(v!='') { $.ajax({ type: "POST", url: "test.php", data: { test : "123" }, dataType: "text", error: function(textStatus, errorThrown) { alert(textStatus+", "+errorThrown); }, success: function(data) { alert(data); } }) } } </script> and PHP: <?php echo $_POST['test']; exit; ?> Everything
jQuery check/uncheck all checkboxes in a form
Hi All, I am very new to jQuery, but I have checked over my code several times and cannot find what I've done wrong with my first script, which is to check/uncheck all checkboxes in a html form. Nothing is checking or unchecking, and I am seeing the "Error on this page" in IE whenever i first click one of the two buttons. Here are the steps I have taken 1. I have imported the jQuery library which I have just downloaded (1.4.2 development version, 155kb) with the following code: < script type
How to select an element with a particular attribute
Hi, all I have a standard menu structured with an unordered list. Some of the items in the menu have sub items, but are not themselves links. Here's an example: <ul id="mainMenu"> <li><a href="">home</a></li> <li><a>services</a> <ul> <li><a href="">services 1</a></li> <li><a href="">services 2</a></li> </ul></li> ... As is, if you mouse over one of the list items that do not have a link, the cursor changes to a text cursor when over the text and becomes
Object doesn't support this property or method
I have come across an issue when using the TinyMCE jQuery plugin and v1.4.2 of jQuery.min.js Under Internet Explorer (v7 and v8), you get an error message when a page is first loaded using Tiny MCE - 'Object doesn't support this property or method'. The highlighted code is: a=b.XMLHttpRequest?new XMLHttpRequest():d("Microsoft.XMLHTTP")||d("Msxml2.XMLHTTP"); This does not happen under Firefox or Opera browsers, but even more oddly is the fact that this error goes away if you refresh the page.
import data from excel to SQL server from a web page without uploading
Hi, Want to import data from excel to SQL server from a web page, but wonder whether it is possible to do it without uploading the excel file from client's machine to server first. Can JQuery help pass that data in any format (say, xml) to a aspx page on server side? I saw a lot of articles out there using .net, but they all need to upload it firstly. thanks a lot
function won't work
$(document).ready(function(){ $('#toggler').toggle( function(){ // you can add as much here as you'd like $('#div1').slideToggle('slow'); $('#imgArrow').attr('src','minus.png'); }, function() { // same here $('#div1').slideToggle('slow'); $('#imgArrow').attr('src','plus.png'); }); });I converted this segmant of code into a function called toggle_menu. Which
Next Page