• highlight row on click with multiple tables

    Hi I have a fairly big table and I am using the code below to highlight the row on click, if I click on another row it removes the first highlight and highlights the new row, it works fine, The scroll/Ajax code is JScroll (jscroll.com) Now the problem, I now only load the first x number of rows, then use a jquery script that loads more rows when I scroll down, it requires that the table is in a div, and the new rows are appended to the div on return from the script. Because of the way it works, I
  • Portfolio filter problem

    Hello, I have a portfolio with filters (portfolio.html ) . The issue is that I want to put the same category from the home ( index.html ) and click to go and filtered portfolio page .How it’s made?   Thanks !!
  • jquery ui Type Error: s is not a constructor

    I am using jqueryui select menu but it is not working on some old Firefox browsers like FF26. I am getting error [Type Error: s is not a constructor]. Please let me know how I can get around this. I already googled it a lot but no solution. Below is the screenshot: 
  • Jquery-Mobile-Navigation

    Hello! I am almost done the design the website I've been working on but have run into an issue with the mobile navigation. It covers up the rest of my navigation, and I'm not sure how to fix this problem. Any advice or insight would be helpful. I have provided the Jquery I'm using below and here is a link to the site: http://www.giiwedinnoodin.com/index-F.html Jquery var screensize = document.documentElement.clientWidth; $(document).ready(function(){ var isMobile = window.matchMedia("only screen
  • understanding John's class inheritance

    hey guys i was just going to john R's post here and  he talks of a pattern he found that looks like below : var Person = Class.extend({   init: function(isDancing){     this.dancing = isDancing;   },   dance: function(){     return this.dancing;   } });   var Ninja = Person.extend({   init: function(){     this._super( false );   },   dance: function(){     // Call the inherited version of dance()     return this._super();   },   swingSword: function(){     return true;   } });   var p = new Person(true);
  • TypeError: Converting circular structure to JSON

    i got error message when posting data through Ajax TypeError: Converting circular structure to JSON $.ajax({                         "url": "http://www.test.com",                         "crossDomain": true,                         "type": "GET", "dataType": "jsonp",                         "jsonpCallback": "mycb",                         "data": {                             "email": "xyz@test.com",                              "name": "amit",                             "url": "http://www.test.com/"
  • jquery not working in localhost

    hi guys i would like help with this jquery code the effect does not appear in localhost browser. here are my files. index page <!doctype html> <html lang="en"> <head> <link rel="stylesheet" type="text/css" href="css/contain.css" > </head> <body> <p><input id="search_name" type="text"/></p> <ul id="names">     <li>Andrew thiarara</li>     <li>Paul thiarara</li>     <li>gmoney thiarara</li>     <li>cecel thiarara</li> </ul> <script type="text/javascript" src="js/contains.js"></script> <script type="text/javascript"
  • Adding link to TAB into a tab content

    Hi! I'm trying to add a link to a tab into a tab content, but it doesn't work, i don't know why : <div id="tabs">       <ul>             <li><a href="tab-1">Tab 1</a></li>             <li><a href="tab-2">Tab 2</a></li>             <li><a href="tab-3">Tab 3</a></li>       </ul>       <div id="tab-1">             <h1>Tab 1</h1>             <p>Lorem Ipsum</p>             <a href="#tab-3" class="ui-tabs-anchor">Link to Tab 3</a>       </div>       <div id="tab-2">             <h1>Tab 2</h1>          
  • document ready function

    Shoud I place every code written in jquery into a document ready function? Every or there is some exception? Thank you. Next question is :  can jquery code without ready function cause slow rendering page? Thanks
  • jQuery UI regional localization issue

    Hi, I'm working on a PHP, Javascript application and i'm using with success the jQuery and jQuery UI libraries. But i have a problem when i try to load the jquery-ui-i18n.min.js file. The application enters into an infinite loop and dies. And i don't know how to find/fix the problem. This is the page source: http://screencast.com/t/RrlLq8zPUDEI And the error: http://screencast.com/t/WKGPuPPZE1oS If i don't load that file, everything works except the translations for the datepicker: http://screencast.com/t/UlF1RdML
  • Changing the text in text box changes the width in IE 11

    Changing the text in text box changes the width in IE 11 http://jsfiddle.net/3TwKF/20/ Please let me know for any solution
  • Change the default /hover colour for a single tab

    I'm a newbie to jquery and have managed to use theme roller to style a set of tabs.   The very last tab is called 'Resources' and contains links to useful stuff about the project. Thing is, the default colour of this tab needs to be green so it stands out from the rest of the grey 'content' tabs! (And the hover state needs to be a lighter shade of green so it matches the colour behaviour of the other tabs.) . I'm fine playing with the HTML and hoped someone could guide me on how to change the default/hover
  • Returning value from AJAX call

    Basically, im trying to write a script that uses AJAX to verify if a username exists. Depending on the response from the AJAX call, it should return true or false. I know I can accomplish this by doing async:false, but thats a no no. Heres a basic version of the script: function whatever (username) { var result = true; $.get( "/account/check_username/" + username, function ( response ) { if($.trim( response ) == 'Exists') { result = false; } } ); return
  • issue with panel data-display push

    I'm just getting into jQuery Mobile - loving it but now hitting the learning curve. Basically I want a number of pages that call the same panel. I have the following. Most of it works. However every other "push" fails with the panel content disparaging at the end of the push ... can't see why. page1.html <!DOCTYPE html> <html> <head> <meta name="viewport" content="width=device-width, initial-scale=1"> <link rel="stylesheet" href="http://code.jquery.com/mobile/1.4.5/jquery.mobile-1.4.5.min.css"> <script
  • spritz.js documentation or gt repo

    hey guys have a look at the source of this website  .  In the resources you will come across a plugin called spritz.js , can somebody tell me where can i find the documentation of this plugin ? or is it hosted on git .  i have made a small demo to illustrate the usage of spritz.js . 
  • Switch between hover and click events, depending on window width

    I have made an HTML5 responsive, 2 levels menu you can see HERE The wide screen version shows submenus upon hovering over the main menu items; the narrow screen (less then 800px) version shows submenus upon clicking the main menu items. The problem is that, if I resize the window, the switch between hover and click events does not happen properly. Of course, I want the menu to react at click on mobile devices... What shall I change in my script? Or is there an already made solution that I can use?
  • backspace key press on Jquery ui Autocomplete textbox doesn't remove any letters on it?

    This is my text field for which i am uisng Autocomplete .       <input type="text" name="state" id="state"  placeholder="State" maxlength="25" required onkeypress="return nospecialCharacters(event)"/>     $("#state").autocomplete({       source: function(request, response) {         var statevalue = $.trim($("#state").val());         if (statevalue) {           $.ajax({             url: url + 'eee',             dataType: 'jsonp',             jsonp: false,              timeout: 6000,             jsonpCallback:
  • How can I create a class for datepicker script?

    I am not a coder and am new to jquery.  I am using a datepicker script and I need it to appear in more than one place on the page.  I asked in another forum but only got as far as the advice to "create a class" before his patience ran out.  I am not sure if he meant a css class or something within the js file.   Any help would be GREATLY appreciated.  :)  This is the script I have in the head tag:   <link rel="stylesheet" href="jquery-ui-datepicker.css">   <script src="jquery-1.10.2-datepicker.js"></script>
  • Syntax

    forexample in Mozilla Developers its written: Syntax arr.forEach(callback[, thisArg]) i know forEach usage etc. but i dont understand the way it declares the syntax its written like [, ] what does callback[, thisArg] mean? why it opens the bracket, puts comma and closes bracket after thisArg ??? in fact i cant learn forEach syntax and usage by the way its declared 8-}
  • Run PHP with JQuery Progress Bar

    Hi, As an example, I have customers in my database. I want to check the numbers of the customers using check_total_number.php then after getting the value I want to run update_customer_data.php but with showing a progress bar for that number of customers. How can I do that using $.ajax? Thanks, Jassim
  • Failed to execute surroundcontents on selection containing span tag

    I am trying to color the background of a user text selection with two colors according to his choice with the option to change the color of an already colored selection. I use jquery and html to generate span tag . the problem I encounter is when the user want to change a already colored selection example: colored selection text0 text1 text2 text3 with color1 <span class= color1> text0 text1 text2 text3 </span> text4 text5 text6 user select text2 text3 text4 to color it with color2, this var newNode
  • Using URL Parameters

    I am using some URL parameters in my jQuery and have come across a bug. Since JS is not my primary (or even secondary if I'm honest) language I am at a loss to know why. I have the following function. function urlParam(name){ var results = new RegExp('[\?&amp;]' + name + '=([^&amp;#]*)').exec(window.location.href); if (results == null) { return null; } else { return results[1] || 0; } }; I then call this with the following lines (much reduced for debugging)... var urlProduct = urlParam('product');
  • Question for confirmation : are DOM changes applied immediately ?

    I've got a weird case of adding an HTML fragment from an Ajax call does not seem to have happened immediately. In the done() callback the fragment is appended into an element and some subsequent code is executed. The code fails because it doesn't seem to find the added markup. And indeed, when pausing the execution, the markup is not present yet. However, everything works when the code is scheduled in a timeout of zero ms. Maybe some kind of precedence in the rendering process of the page. I'm pretty
  • How can I get a hidden HtmlTableRow to display?

    I am creating some html elements via server-side (C#) code. Since this is a jQuery forum, I won't show that code, but it adds a column caption row and a first row of "textboxes" that are visible; then, I add two more rows of textboxes that start off invisible. I additionally (no pun intended) have a button (with the caption "+") that should make the first invisible row visible on the first click, and the second invisible row visible on the second click. I'm trying to accomplish that with this jQuery:
  • Event Listener Not Working With colorbox Plugin

    I am using jQuery Plugin 'colorbox' for a lightbox solution on my site, but when I try to use any event listeners, such as 'cbox_complete' to customize the size of the colorbox to allow for a larger space under the photos for the captions, it doesn't seem to ever fire. Here is the page with the colorbox and below is my event listener. Just click the first image in the content area of the page to start the slideshow. Right now I have the title positioned over the bottom of the photos being loaded
  • Click event for dynamic checkbox not working?

    http://jsfiddle.net/au901wLt/1/ Click event for dynamic checkbox not changing value?
  • Ajax url error

    Following is a snippet of ajax code which works fine if the call is made from home page. If I use it in another page I get 404 error code regarding the "url:" option. As seen from the code the url is "wp-content/plugins/myplugin/build_responsive_css.php" In case of another page say "page1" I get the following error in the Chrome consol: page1/wp-content/plugins/aaa-responsive-design-helper/build_responsive_css.php 404 (Not Found) How can I solve that? Regards I. Sher
  • How to create the tables in Matrix form

    When i enter 3 in the input box it should be able to create a 3X3 tables (i mean 9 tables should be created) dynamically and it can happen up to 64, how can we do in jquery, Any help would be  appreciated.  
  • Uncaught ReferenceError: jQuery is not defined

    Hello guys i am using jquery in python but i cant resolve this error need help
  • How to calculate the difference between two cordinates

    I need to calculate the difference between the two co-ordinates as mentioned below. The values are left and top positions Starting Coordinates : 8 , 115 Ending Coordinates : 168, 115 Difference is : 160, 0 and then i need to divide it by 40 So my final result will be : 4,0 Please let me know how can i do it in Jquery.
  • Getting div top position

    Hi, I need to get a div's top position that has the following css - #bodyDIV {             position: absolute;             width: 80%;             height: 80%;             bottom: 10%;             left: 10%;             background-color: #808080;             border-radius:3px;         } The following code return "auto" mydiv.css("top") What is the right way to get the actual div's top position ?
  • Background ajax

    Hi, I send an ajax request every some time with a javascript timer , when ajax call start it shows the jquery mobile loading sign. I want that ajax call to be in the background without showing the loading sign , How I do that ?. Thanks
  • Please advice on plaform

    Hello, I am planning on creating an app aiming to the android platform and I would like some advice from users with experience with jquery mobile. My app is going to incorporate: - Google map usage - User current location - Sql database - Forms that the user will save data - user saved points (lat/lon) into the database - Geo location queries Can these be accomplished with jquery mobile and HTML5 or should I be looking directly at native android development? thnx in advance
  • I am new in Jquery..I want to get all controls values from table which is generated dyanamically in cs page,i want to do same operation using this control id or class?

    i want to iterate tables values and add in to #txtGrandTotal textbox. each textbox keyup event i want the fire this function and calculate add or minus textbox value and get result in last outside txtGrandTotal which is not part of dynamically generated textbox. for example i want tax calculation in that many textbox generated like dynamically generated table name is tblTable --------------- ------------ ----------------- basic amount-      330 discount 5%-      16.5(minun from basic) subresult=          
  • jQuery UI Resizable display issue with div inside <ul>

    Hello,       I'am trying to apply the resizable widget for div inside the grid items.But the 3 resizable icons displayed incorrectly for the grid item.If you apply it for normal div then it displays properly but not for elements inside <ul><li> tags. for example      <ul>           <li>                <div id="usernote">                    ///content goes here                </div>          </li>      </ul>     $("#usernote").resizable();  Thanks in advance for the response. Regards,
  • How to et the current end points of svg path?

    Hi all there is an example of how to draw a svg path (and others) while I am scrolling - link . So there is a path rendered in svg. At the beginning that path is not rendered. Just as I am scrolling it is  rendered step-by-step ... so how can I get the current position of last points [ x,y ]? I hope you understand what I want and thank you for answers.
  • Using text-indent with animate

    Following a JQuery tutorial, the instructor uses this code to rotate a menu button $('#toggleMenu').animate({     'text-indent':1 },{     duration:1000,     easing:'linear',     step:function(now){         $(this).css('transform', rortateZ(' + (now * 360) + 'deg)');        } }); And then same code but with 'text-indent':0 to reverse the animation, the instructor said he is using 'text-indent' to be used with step function but I really dont understand, can you explain more the what is the role of
  • Replacing substrings in a string to a common string

    I have a string that contains few substrings separated with spaces. I want to replcae all spaces with a two character string: " -" (space with hyphen). example: original string : "aaaaa    bbbbbb abc" required string: "aaaaa -bbbbbb -abc" I tried javascript replcae but it doesn't work. Can someone help please? I. Sher 
  • ajax refresh form

    hey guys, i am new in jquery, i tried just load a specific div with error msg in a form, works nice the page not reload perfect, the one problem that return for me my full page repeated 4 times in the same page. example: when i click the button load in index 4 index page :) i want just load everything inside that div with that class $(".text-danger") thanks. userview.php <div class="row">         <?php          $attributes = array("class" => "form-horizontal", "id" => "userform", "name" => "userform");
  • Facing issues with Jquery Mobile and jquery ui autcomplete feature

    This is the way i am using autocomplete for my jquery mobile application which is using jquery ui       <input type="text" id="iamat"  name="iamat" onkeypress="return nospecialCharacters(event)" required/>     <div class="autoSearch_result_Wrap" id="iamatsearch" name="iamatsearch"></div>       $("#iamat").autocomplete(       {         source: function(request, response)         {           var iamat = $.trim($("#iamat").val());             $.ajax(             {                  success: function(data)
  • 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