• $_POST data on same page and output

    Hello when a button is clicked I want to post data to the same page and show something. Only there is nothing showing up. My code: $(document).ready(function(){       $("#orderbycommonnameup").click(function(e){         e.preventDefault();         var url = document.location.href;         $.post(url,{orderby: "comnasc"},function(data){             window.location.reload();         });     }) }); <a href="#" id="orderbycommonnameup"><img src="images/icon-arrow-up.png"></a> and on the same page as
  • Uncaught TypeError

    Hello Guys: I'm working with ASP .Net and JQuery, i'm developing a MsgBox Dialog control (ascx) the control work's successfuly but i can't display it on Chrome, Opera, Safari and Firefox this browsers send the next error: Uncaught TypeError: Cannot read property 'element' of undefined....  The MsgBox dialog only appear in IE, i don't know what's happen, the code that i wrote to display this MsgBox dialog is
  • Datepicker advertising on windows tab

    I need help modifying some strange jQuery UI datepicker behavior.  The datepicker is working perfectly as advertised inside my website, but has taken up advertising on my website windows tab. The name of my website has been replaced on the windows tab with "jQuery UI Datepicker - Default functionality". Appreciate your help getting my website name back on the windows tab. Dan
  • .hover() function works but image flickers multiple times

    <!doctype html> <html> <head> <script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.4/jquery.min.js"></script> <script> $(document).ready(function() { //preload images var nNormal = $("img").attr("src"); var nHover = new Image(); nHover.src = "http://d0od.wpengine.netdna-cdn.com/wp-content/uploads/2015/02/wallpaper-icon.png"; //attach hover event $("img").hover( function() { $(this).attr("src", nHover); }, function() { $(this).attr("src", nNormal); } ); }); </script> </head> <body> <div>
  • How to find and updated an INPUT field?

    I created a JSFiddle to help explain the change I wish to make. <tr>             <td class='priority'>                 <input name="sequence" value="1" size="6" />             </td>             <!--Added INPUT field  in the td class priority-->                         <td>George Washington</td>             <td>Apple</td>             <td>N</td>             <td><a class='btn btn-delete btn-danger'>Delete</a> </td> This would be generated from a php call to a database that is currently working well.
  • jquery ui datepicker not closing after selection IE11

    Hi, This isn't working in IE11 in fact, after selecting a day the calendar closes itself in Chrome but not in IE11 so I tried the hide in onSelelect but no success. hide()Returns: jQuery (plugin only) Close a previously opened date picker. This method does not accept any arguments. Code examples: Invoke the hide method: 1 $( ".selector" ).datepicker( "hide" ); Is there any workaround ?
  • jQuery SelectMenu not showing the selected item when using scroll bar in IE>9

    Hi  I am using jQuery select menu to display dropdown list. The drop down list has around 100 items. so i used to max-height to display some items and used scroll bar to go to see other items. when i am using the scroll bar the selected item is not displaying in IE9 and above. it is working fine in chrome. you can use the following link in IE9 and above and find the observation. http://view.jqueryui.com/master/demos/selectmenu/default.html in the above link go to select a number dropdown and select
  • How do I update the html inside a variable

    Hello, I have the following html inside a variable: <tbody><tr class="contract"><td style="width: 25%"></td><td style="width: 25%"></td><td style="width: 25%"></td><td style="width: 25%"></td></tr><tr><td colspan="1"><input type="hidden" id="radio42918" visiblecondition="" mandatorycondition="" class="radio-values"><span class="prompt42918"><label class="prompt-label prompt42918" colspan="1" itemid="42918">Radio<label class="mandatory-text-sign hide-item">*</label></label></span></td><td colspan="1"><input
  • How to tell that a submenu has been selected rather than the top menu

    I need to determine that the user has selected a sub-menu item rather than the top level item, and I'm having real trouble in determining that within the select event. I tried if ( ui.item.children('ul').length === 0) But the problem I have is that if the user clicks on the top level menu and then clicks on it again, it triggers the event, and subsequently using: ui.item.context.textContent contains all the sub-menu items.
  • history.back(); to empty page

    Hello guys! I'm using jQuery mobile for a while now and i bumped into a problem that i have never seen before. I'm using phonegap to make my project an native app on some devices when i call history.back(); it will go back to the page and then jump to an empty page (or let's that page hide). I'm using jquery mobile 1.3.2 and i know it's solved in 1.4.5 but i can't just upgrade to this version because i did alot of curstom changing in the 1.3.2. So i hope that one of you guys knows how i can fix this.
  • understanding usage of deffered.promise in jquery animation

    hey guys have a look at this code below ,  FIDDLE HERE Code here :: $("button").on("click", function () {     $("p").append("Started...");     $("div").each(function (i) {         $(this).fadeIn().fadeOut(1000 * (i + 1));     });     $("div").promise().done(function () {         $("p").append(" Finished! ");     }); }); now what is promise() even doing in this code ? .  aso another question i woudl like to ask is , is  Deferred, Promise and Future a Javascript thing ? or is it all only exclusively
  • scripts.js function doesn't run when button is clicked

    Hello, I have a button used for logging in, and when a user clicks this a box should be overlayed allowing them to login, I know it does work as the site I'm using is a template, however in practice it doesn't work. HTML: <div class="header-login">           <a href="#" class=""><i class="fa fa-power-off"></i> Login</a>           <div>             <form action="#">               <input type="text" class="form-control" placeholder="Username">               <input type="password" class="form-control"
  • Why does changing the val of a text input element in jQuery not fire my TextChanged event?

    I'm trying to change a value in jQuery that will cause a chain reaction, so to speak, to fire the element's TextChanged event. I've got this server-side code: PDFGenBtnClicked = new TextBox(); PDFGenBtnClicked.ID = "pdfgenbtnclicked"; PDFGenBtnClicked.Text = "no"; PDFGenBtnClicked.Style["display"] = "none"; PDFGenBtnClicked.AutoPostBack = true; PDFGenBtnClicked.TextChanged += new EventHandler(PDFGenBtnClicked_TextChanged); . . . protected void PDFGenBtnClicked_TextChanged(object sender, EventArgs
  • AJAX POST

    I want to post my entire form, do I need to specify each field or should this work? $( document ).on("click", "#register-submit" , function() {   $.post( "register-process.php", {}).done(function() { alert( "Registration Complete");   }); })
  • Lookng for a good responsive menu , something like the one on https://hbr.org/

    hey guys .  have a look at the menu here  , i reallly like that menu , the menu used on that site is very similar to a popular jquery plugin , Sidr.js  . but the menu used on that site is different in a few ways and is more elegant than sidr.js .  is there a jquery plugin thats similar to that one as on the site link i provided ? I really love that menu .  basically i just want to experiment with different kinds of responsive menus. (preferably not experimental ones ! ) .Any suggestions ? 
  • newbie 3 part form processing question with include

    Hi all, I am a query newbie attempting to incorporate J query mobile into a pre-existing multipage website. In this case I have this previously working Page setup:  It may sound a bit odd but it is working fine negotiating with and external website mypage.php in this header I have various https://code.jquery.com/xxxx links (only here) In the body of this page I have A PHP include to = myform.php myform.php is and rather complex form that goes in three parts to the external website - (this form came
  • meta http-equiv="refresh" not working with JQM

    hi all, Currently I am using JQM on a multi page site submit button on page 1 that goes to page 2 has : rel="external" and works well however on page 2 I have database processing at the top - then  this header that goes to page 3 <meta http-equiv="refresh" content="0; url=page3.php"> Without JQM page 1 goes to page 2 then auto goes to page 3 WITH JQM - it STOPS on page 2 and doesn't see the refresh I guess.... Q: Is there a way to get this to process to get to page 3?
  • Drop position on a Jquery Draggable and Droppable

    Hello. I want to make a floor plan with a sidebar draggable elements into a container droppable. Then, from that container where i drop elements from sidebar, i want to make them draggable again to arrange where i want in the container. http://jsfiddle.net/96t0qwmg/2/ I`ve made an example here but it has some problems: 1) when i drag elements from sidebar, they not placed where i dropped in container. Need to position them exactly where i drag. 2) if i drag 2-3 links from sidebar to dropable, then
  • Allow * wildcard in .removeClass()

    It would be nice to be able to use the * character as a wildcard in calls to .removeClass(). For example, elem.removeClass('foo-*') would remove all classes that start with foo-. Currently, the easiest way to do this seems to be the following, which is neither elegant nor efficient: .removeClass(function (_, cl) { return cl.split(' ').filter(function (c) { return c.substr(0, "foo-".length) === "foo-"; }).join(' '); })
  • controling authentication using jquery mobile

    Hi. I'm new on hybrid apps. I try to develop a hybrid app using jquery mobile. I try to make a login form and post it. I think that post username and password using ajax. How i can keep logged-in user data on my application. And how i can control a page is shown or not  to user by his authenticate state. I hope, i can explain my issue. Can anyone give me an idea? Thanks in advance.
  • can I use the jquery ui component in jquery mobile?

    Hi, I am a beginner of jquery mobile programming! I want to know the relationship between the jquery ui and the jquery mobile. If I use the jquery ui widgets in a jquery mobile project for handset, did them will conflict? Thanks a lot!!!
  • How to Use a Variable As Array Name

    How can I make the alert work? ========= code ============= var arr0 = ["king", "queen"] var arr1 = ["boy", "girl"] var arr_name = [" arr0", "arr1"]; alert( arr_name[0 ]. length);
  • ie11 Unable to get property 'nodeType' of undefined or null reference

    I have a curious problem that I have been struggling with for a few days. I have a simple psp page written with jsp 2.2, richFaces 4.5.7 (which loads jQuery library v1.11.3) running on a WildFly-9.0.0 server.  When I load the page in Internet Explorer 11 (it all works in Firefox and Chrome) I start to get errors, the first is in jquery.js line 4198: // Minified: var a,b,c     var input = document.createElement( "input" ),         div = document.createElement( "div" ),         fragment = document.createDocumentFragment();
  • How to add content in a div using jquery

    Hello I am experimenting an issue using jquery to create come content to be displayed inside a div. I am using the plugin Lightbox for photogallery. Lightbox display a large image , once clicked on a thumb, that is not part of the original html dom where the thumb is placed, so is getting a bit tricky for me that i am learning jquery. I have a $title variable to be shown inside a div that contains an image. the title is related to any image I have in the gfallery. this is my php page that i created
  • splice and push - Easy But..

      alert(process_stage1[1])  returns undefined. Why???    stage0 =["a", "b", "c", "d"]; -----------------[code] -------------------------------------------    var stage_status = 'initial_stage';      if(stage_status=='initial_stage'){     var init = stage0.splice(0, 3);                                                          process_stage1.push(init);      alert(process_stage1[1]); // undefined??? Why???      } //if
  • How to apply css style on determine row in html table.

    Hi, I would like to realize an analysis of data in a table html . That is, I want to know if it is possible in jquery check if all < td > are filled by values , if a  < td > contains a value <5 , if another <td>has value " successful " . When one of the cases described above occurs , I would turn red background color in the column row . Thanks in advance. Tegatti
  • AJAX on a page loaded by AJAX

    I have a page index.php for example, on this page I have a menu and depending on what menu option is selected the page content is loaded. One (actually many of these pages) will be forms which I then want to also post via AJAX. However when my page loads via AJAX (add_user.php) I can't post this using AJAX Why?
  • How was code contributed before GitHub Pull-request was used?

    Does anyone know how the code was contributed to the project before GitHub Pull-request was used? via patch on mailing list or issue tracker? Is that history archived? Thank you! Shin
  • Newbie: best method to send data and return results without leaving site?

    I haven't written the code yet (actually looking for examples/samples for this as well), but I have hypothetical scenario where a user is on a checkout page and I want the user to enter in their shipping/handling info (or it's entered automatically) and they click a "send this info" button. They never leave the page, and it just returns saying successful. But after they click the send button it actually goes and posts the info to a different website/db and saves this info. I'm thinking a RESTFUL
  • resizable accordion is broken in latest release

    so I was working on a jquery accordion that I wanted to customize with some special behavior. The widget I am working on only has 1 tab and is collabsible, resizeable and draggable. I have applied the resizeable to a parent widget. since I don't want the parent widget to obscure more space than it needs if the accordion is collabsed I resize the parent widget when I collabse expand the accordion. I use 4 variables to this. (uncollapsed width/height and collapsed width/height). I get the active state
  • jquery selectable

    Hi, I downloaded JQuery selectable from the webpage, as I have 3 different services(plans, i.e trial, basic and premium) that I want my customers to be able to choose from. All three are situated next to each other, separated in different div-s and consist of information, for example price, storage, bandwidth, etc.  The problem I'm having is that I need to save the selection, in order to be able to send it to my database, but I'm unable to save it like selection 1, selection 2, selection 3 because
  • floating menu, lags during page scroll

    Hi guys,  I have a floating menu moves together with the page scrolll. Here is my code. $(window).scroll(function() {    var bottomHeight = $(window).height()/100*35;    $('.logo').css('bottom',parseInt(bottomHeight) - parseInt($(document).scrollTop())); }); Problem is when i scroll move then one frame a time, the menu will look like its lagging. Does anyone know how to fix this?  Thanks in advance.  Cheers, Thomas
  • JQuery-UI draggable reset to original pos

    Hi, How to reset the draggable elements. And also attached zip files. Without reset it is working fine. Below is code :- <!DOCTYPE html> <html lang="en"> <head>     <title></title> </head> <body> <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.5.0/jquery.min.js"></script> <script src="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8.9/jquery-ui.min.js"></script>     <!-- <link href="http://code.jquery.com/ui/1.8.24/themes/blitzer/jquery-ui.css" rel="stylesheet" type="text/css" /> -->
  • jQuery.each breaks on undefined object

    Hi, I'd like to ask some enlightenment on what's the reason behind $.each function breaks the loop when there is an undefined object.  This is a sample link
  • Transition from JavaScript alerts to jAlert?

    Hi! I'm working on a quiz-like game for a website. You enter letters into separate fields to spell a word. If the word is right, you get a "congratulations" dialogue; if it's not, the dialogue tells you how many letters you have right out of how many total letters there are. However, the standard JavaScript alert isn't ideal in this situation for two reasons: I need to insert a link to the next question if your answer is correct. A lot of browsers enable you to turn off dialogues after a certain
  • Cancel sortable

    Hi! I have a problem with sortables cancel method. When the user moves one item in the sortable to a new place I save the position via ajax (called in "update"). If the user moves another item after his session is expired, I want to cancel his / her last move and move the item to its old place. But $( 'selector' ).sortable( 'cancel' ) reverts both moves. How can I cancel just the last move?
  • dragging over an image to change image

    I need to create the effect similar to this page: http://www.teslamotors.com/modelx where you can drag on an image to change it. what's the best way to create such an effect? Thanks for any suggecstions
  • Getting values from array of same class elements in jquery

    <tr> <td class="moduleSupport"> 1 </td> <td class="moduleName"> Cargo Hold </td> <td class="currentModuleQuantity"> <input class="currentModuleQuantity" placeholder="Enter current quantity" type="text"> <span class="currentModuleQuantityErr"></span> </td> </tr> <tr> <td class="moduleSupport"> 1 </td> <td class="moduleName"> Crow Nest </td> <td class="currentModuleQuantity"> <input class="currentModuleQuantity" placeholder="Enter current quantity" type="text"> <span class="currentModuleQuantityErr"></span>
  • French Characters Corrupted on Form Submit

    Hi All, Long time lurker, first time poster. Would it be possible for someone to please help me out. I have a guestbook in jquery mobile that also needs to be in french. upon form submit of any of these french characters: "áàäãâùæçéèêëîïôœùûü«»ÜÛÙŒÔÏÎËÊÈÉÇÆÄÂÀ" it automatically replaces the entry with these characters: âùæçéèêëîïôÅ�ùûü«»Ã�à Pages are encoded in UTF-8. For test purposes, try pasting: "áàäãâùæç" in the last text field and hit submit. Any help is greatly appreciated.
  • How to detect HTML5 stream was disconnected on Android by jPlayer

    I use jPlayer  as my HTML5 stream player, I prepared two channels, if channel one is disconnected I can switch to channel two, and I want do it when playing, I can't find disconnect event on HTML5 audio api, so I use ended event as disconnected status, it works perfect on desktop and iPhone, but not work on Android, when I play on Android browser, and disconnect on purpose, the browser looks like play but the sound is lost, that's mean if I lost signal on Android browser will not trigger anything,
  • Next Page

  • Announcements

  • The Basics of jQuery AJAX

    A step-by-step tutorial for those new to jQuery and wanting to use AJAX in their projects. Includes valuable information about troubleshooting using the console and understanding the request / response. http://jayblanchard.net/basics_of_jquery_ajax.html
  • jQuery Conference 2010: Boston Announcement

      The jQuery Project is very excited to announce the jQuery Conference 2010: Boston on October 16-17, 2010.  The conference will be held at the Hilton Boston Logan in Boston, Massachusetts.  The best part of this announcement is that Tickets are on sale now!  This venue is the largest that the project has worked with to date (Harvard Law School in ‘07, the MIT Stata Center in ‘08 and Microsoft New England Research Center in ‘09) and we expect to sell out very quickly. A brief synopsis of some of