• content type setting

    $.ajax({ url:url, contentType:"foo" }) $.ajax({ url:url, headers:{ content-type:"foo" } }) what is the differences between the two code snippets?
  • display messages from server in my contact form with jQuery Ajax and JSON

    hello everyone i habe a problem to display my successes and errors messages in Browsers Firefox and IE. my messages are displaying in a different browser window and not in he set Tags from my html. Here you can see my code: $('#abschicken').click(function() { event.preventDefault();     // get the form data var formData = { 'name' : $('input[name=name]').val(), 'email' : $('input[name=email]').val(), 'tel' : $('input[name=tel]').val(), 'bemerkung' : $('textarea[name=bemerkung]').val() }; // process
  • Very strange behaviour after regex-test ?

    Hi guys, I got a very strange behaviour and I really want to know why it does what it does. This is the page: Please remove the"-" signs and use the correct protocol: yttp://p-r-o-f-o-r-m-a.s-c-i-e-n-c-e-a-n-d-m-o-t-i-o-n.com From line 189 to 193 on this page I simply want to color the content of a <label>-tag in red if the email-field was not correct. works fine in all browsers I tested. // Test if valid email if(!regex.test($('input[name="email"]').val())) { flag = false; emailregex =
  • addClass() does not add class

    In my css i have the following classes: .orange {         background-color: orange;     }     .coral {         background-color: coral;     }     .brick {         color: firebrick;     }     .indian {         color: indianred;     }     .pinky {         color: pink;     }     .purple {         color: RGB(102, 51, 153);         font-weight: bold;     } when i use them like this, they work: $('h1').addClass('blue'); $('h2').addClass('red'); $('h3').addClass('yellow pinky'); $('h4').addClass('orange
  • DOM manipulation methods when to use html elements and when not to

    In replicating the manipulation methods exercises, I noticed that sometimes html tags are used and sometimes they are not when adding a string.  What is the best practice? Thank you in advance! Ingrid
  • Upgrading jQuery mobile from 1.2.1 to 1.4.5

    I'm very new to jQuery and have to update a existing project, when i simply replace the old lines with new code the whole css stop working right, its a single page application. <link rel="stylesheet" href="<?php echo AppEnvironment::getMobileUrl() . '/css/jquery.mobile-1.2.1.min.css' ?>" /> <link rel="stylesheet" href="<?php echo AppEnvironment::getMobileUrl() . '/css/style.css' ?>" /> <link rel="shortcut icon" href="<?php echo AppEnvironment::getMobileUrl() . '/img/favicon.ico' ?>" type="image/x-icon"
  • validation plugin doesn't work

    I use jquery validation plugin to validate a form but it depict "$(...).validate is not a function(…)" error message Here is my php code <html> <head>     <title>Add Supplier</title> <link href="css/addsupplier.css" rel="stylesheet" type="text/css"> <?php require('../includes/_header.php'); ?>    <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.12.4/jquery.min.js"></script>    <script src="http://ajax.aspnetcdn.com/ajax/jquery.validate/1.11.1/jquery.validate.min.js"></script>    <script
  • Need to create an auto scroll

    I have a project and was tasked to make data scroll.  I can use a grid, HTML etc.  Still unsure how I want to proceed.   First I need to say I have never used JScript or JQuery but all the searches pointed me to using those tools.   We have dynamic data (right now everything is server side).  We also are using VS 2015, Telerik and Oracle. I need to show something like the following that will scroll (settings need to be able to be changed by the user) and once it hits the bottom, a data refresh will
  • Adding span or div tags to checkbox and label

    I've created a checkbox list in .net, but as part of a responsive design I need to keep the checkbox and the label on the same line. I thought that this would be a matter of inserting a span or div tag before the checkbox and after the label, and then I could add a nowrap class to keep them on the same line. At first I thought that .before and .after were what I needed, and these work fine if you add some random text, but not with html tags. If I add the span tag before the element, jQuery closes
  • I got massive problems with jQuery

    The issues are related to Version Control for jQuery plugin, which uses old version of jQuery causing all of the issues. How can I solve this????
  • Need help troubleshooting uncaught reference error: jquery not defined

    Hi! Need help troubleshooting uncaught reference error: jquery not defined It is a wordpress site. I'm trying to help someone use the thrive plugin to build some landing pages, but apparently it has a conflict with the theme - diamond.  This is the error that is coming up and what I'm sure is causing the issue. I've tried calling jquery in the functions.php file.  I don't know.  I'm still learning dev for wordpress. I can't seem to locate the offending code.  It doesn't help that my time is limited
  • Dynamically Change Cursor Background Color

    Currently I can change my cursor when I hover over certain DIVs by using the code snippet below. $('#myDiv').css( 'cursor', 'url(myCursorImage.png), auto');             But suppose I have an image of an arrow with a clear background that I want to use for my cursor image. Is it possible to dynamically change the background of this image using css?
  • what's wrong with this jquery?

    I have a radio button list with a name of "ReportTypeId". For each radiobutton I want to display an alert with its value when it's clicked.  I wrote the following jQuery which gets all 5 radio buttons the list with a name of "ReportTypeId": $("[name='ReportTypeId']").toArray().forEach(function(reportTypeId){ reportTypeId.click(function(reportTypeId){ alert(reportTypeId.value);}); }); When I set a breakpoint and examine tthe variables at load time the variables look as expected.  However, when I click
  • Problem Jquery and .one function since firefox update

    Hi there, i've found a bug that only occurs in newest Firefox or Chrome. In older Versions it works, in Internet Explorer 11 it works too. I have 2 Layers: "maincontent" and "subcontent". The "maincontent" layer shows a Link to hide "maincontent" and show "subcontent". In "subcontent" is a link to hide "subcontent" and show "maincontent" again. Simple. When i klick the link in "maincontent" i have a small fadeout effect with animate.css: maincontent fades out, wait for animation ends, after animation
  • can I have a feedback of my first plugin ..

    Hello, I've write my first plugin , a jQuery UI Widget - Carousel Carousel-Widget please take a look ! I appreciate any feedback .. thank's so much all the best Noel
  • input text lose value when window.location.href is called

    Hi,  I have an input text and button search, when a user type a text a script redirect the page with the text as parameter, but after the redirect (in the same page) the input text lose the value, I tried to reload value from paramters with no luck Help please ? this is my code : <script type="text/javascript"> function RedirectUrlSearch() { var tb = document.getElementById("tbSearch").value; if((tb != null)) { window.location.href="?FilterName=SalesforceCaseNumber&FilterMultiValue=*"+tb+"*"; if
  • JQuery code not working??

    I'm new to JQuery so i might be missing something really basic.  I'm using JQuery 3.1.1  My code works fine with Chrome(Version 53.0.2785.143 m) and Firefox (44.0) but does not work with the IE 11 or Edge.  code snippet included below.  HTML: <!DOCTYPE html> <html lang="en">   <head>     <meta charset="utf-8">     <title>A Christmas Carol</title>     <link rel="stylesheet" href="03.css" type="text/css" />          <script src="./scripts/jquery.js"></script>     <script src="./scripts/Jq03.js"></script>
  • jQuery Mobile 1.4.5 Table Reflow

    If I follow the example in the jQuery Mobile 1.4.5 demos for Table Reflow, but set up my table using thead: <table> <thead> <tr><th></th>...</tr> </thead> <tbody> <tr><td></td>...</tr> </tbody> </table> Then I don't get any column headers (labels) moved down in the reflow process. I only get data, when headers are supposed to be displayed left of the data. If I use a "old" table, then everything works: <table> <tr><th></th>...</tr> <tr><td></td>...</tr> </table> Isn't Table Reflow supposed to also
  • js.foundation

    Surprised there has been no announcement either in these forums or on the jQuery blog about this... Apparently, jQuery Foundation has morphed into (or been absorbed into newly-created... or something like that...) js.foundation. (I learned about the "apparent" equivalence only from a news article - you'd be hard-pressed to glean that from the official js.foundation website.) js.foundation has a broader vision, encompassing a good number of Javascript projects, which do include jQuery, jQuery Mobile,
  • how to store and use value of variable in jquery

    Hi, following is a working code for displaying the value in 2 div's disp and bus. $.ajax({ type: "POST", // url: "Busbooking.aspx/ConductorTable", url: "Busdetails.aspx/BindData1", data: "{}", contentType: "application/json; charset=utf-8", dataType: "json", success: function (msg) { var s = msg.d; var k = s.split("--"); $('#disp').html(k[0]); filter1(); $('#bus').html(k[1]);
  • Button not starting ajax call

    Hello, My button, when clicked is not start the ajax call, I cannot work out why. This is my button: <button class='btn btn-default pull-right cart-delete' onClick='event.stopPropagation();' id='$product_id'>X</button> The reason I added onClick='event.stopPropagation();' is because my button is in a bootstrap dropdown toggle and I need to keep the dropdown "down" even after the click in the cart. And this is my jquery code: dataType: 'json', <script> $(document).ready(function(){ $(".cart-delete").click(function(){
  • Contact Form is not sending all info

    Contact Form info is not sending from my PHP/jQuery contact form, only  name:  email: Here's the code: <form id="ajax-contact" method="post"> <table class="table10"> <tr> <td> <label for="name">Your Name:</label> <input id="contact-name" type="text" name="name" required> </td> </tr> </tr> <tr> <td> <label for="email">Your Email Address:</label> <input id="contact-email" type="email" name="email" required> </td> </tr> <tr> <td> <label for="message">Message:</label> <textarea id="contact-message" type="text"
  • $.ajax jsonp api SCRIPT1004: Expected ; request.php

    I am using Security Center's API http://static.tenable.com/prod_docs/SecurityCenter_4.8_API.pdf When using the URL in the browser I get a result; however, when trying to call it via jquery I get an error. SCRIPT10004: Expected ; request.php, line 1, character 8 which that line is {"type":"regular","request_id":"4666".....etc Here is the code: $.ajax({ url: 'https://ip/request.php?action=init&token=&module=system&input={}&request_id=4666', method: "GET", headers: { "Accept": "text/html, application/xhtml+xml,
  • Sliding a Range Slider with a Fixed Range

    I have a requirement for a range slider (a slider with two handles), such that: i)  the left and right handles can be position independently to specify a range ii) a handle (e.g. in the middle) can be grasped such that when it is moved both handles (and the range they specify) slide together either to the left or the right. This seems to me to be pretty basic functionality, but I have not been able to find any jquery sliders that provide it. Am I missing anything?
  • Insert data using Jquery

    I try to insert data using Jquery and I textbox and select options Html <input type="text" class="input-sm" id="txt_repeat" /> <select id="dura_values"> <option>da(s)</option> <option>We(s)</option> </select> JQUERY <script type="text/javascript"> $(function () { $('[ID*=btn_Add]').on('click', function () { debugger; var frequency = $('#txt_repeat').val(); var duration = $('#dura_values').val(); debugger; var obj = {}; obj. frequency= frequency; obj. duration= duration; insert(obj); }); }); }); $(function
  • Problem getting diagonal slider plugin to work in wordpress

    Howdy, i'm a complete newbie to js.  i'm trying to get this diagonal slider below to work in my wordpress website. http://www.jqueryscript.net/slider/jQuery-Skewed-Accordion-Slider-Plugin-Diagonal-Slider.html to work on this page http://www.deckpads.co.za/js/ i'm really struggling. i don't know if its the css that i need to change or here is something i'm not doing right with js. When i try to reduce the size of the images - they stop expanding/contracting on the rollover. I'm using Divi Theme from
  • Music player for Jquery Mobile?

    Hello, I would like to add a music player where I can add different playlist and have my songs playing one after the other or on a loop on Android devices. Do youi know if there is a clever jquery mobile plugin I could use please? Thank you.
  • Store update LINQ query and pass to json

    I am trying to create an update linq query & I generate table using jQuery so after update how do I save changes to data in the table? [WebMethod] public static string updateselect_data(int ServiceID, string frequency, string Freq_Du, string Freq_Mil) { try { Track_Data track = new Track_Data(); DataTable dt = new DataTable(); var update = from p in track.Serv where p.ServiceID == ServiceID select p; foreach (var q_update in update) { q_update.frequency= frequency; q_update.Freq_Du= Freq_Du; q_update.Freq_Mil=
  • Non-Profit School for autistic children slider button link

    Hello, I have inherited this site and I have been trying to edit a Button inside of a Slider. The slider was created using a slider called loopedslider. When I go to Slides from the WP admin site, the button is not available to be edited. There is a PHP file that I have access to from the ftp download that references this button, but the link for each slides button is not editable.  The slider was created using javascript. Url-  cflu.org 
  • Jquery Mobile

    hi can you help me how to make mobile apps in class record....?/?????
  • Understanding Javascript - Object Creation vs Lookup

    I have ANOTHER question about some javascript/jQuery code. It's probably not necessary, but here's where the code is from.   http://www.ryansouthgate.com/2016/03/15/adding-multiline-text-to-highcharts/ Why does this line create a chart... $('#container-speed').highcharts(Highcharts.merge(gaugeOptions,... And this one doesn't? var chart = $('#container-speed').highcharts(); Am I interpreting this correctly? If so, why? What are the rules?
  • Understanding Javascript Concepts

    I am reviewing some javascript/jQuery code and having trouble understanding a few lines of the code.  I'd like to ask about one here. It's probably not necessary, but here's where the code is from.   http://www.ryansouthgate.com/2016/03/15/adding-multiline-text-to-highcharts/ I cannot understand this bit of the code. Let's call it the 'original form'. var textEl = chart.renderer.text(text) // ensures our text is centered .css({ 'text-anchor': 'middle'})
  • POST and GET ajax jquery

    Hello, I am posting cart values in the database with ajax and would like to know if the GET function would work for update my cart. I have all the code in php working, just need to have a way to POST and then run my cartupdate.php Would the below code be the right way of doing this please? Thank you. <script> $("#form-items").submit(function(e) {     $.ajax({            type: "POST",            url: "resources/templates/frontend/cart.php",            data: $("#form-item").serialize(),            success:
  • Opening A Dialog Near Mouse Cursor

    I am trying to open a dialog near the mouse cursor when I click any where in a div with the ID of clickzone. The problem is the dialog opens at the bottom of the div and not near to where I clicked.  Please see my script and markup.  When the page opens, please click any where in the gray area to test my script.
  • Add charts to sliding window in dashboard template

    Hi, I have a dashboard template which contains a couple of images. Instead of those images I want to put in a pie chart or a bar chart. The values in these  charts are fetched from the DB. The values in the charts are changing values, they are not static. I have the charts ready in a .js file. But need the advice in calling the charts in UI.     
  • Uncaught ReferenceError: preventDefault is not defined

    Hello, I'm facing a strange issue but haven't been able to fix. I'm getting Uncaught ReferenceError: preventDefault is not defined error whenever I trigger the 'click' action. I found out that the issue is typically caused when jQuery isn't properly loaded. However, in my case, the jquery does load before my custom javaScript file. In fact, I'm able to execute it properly for another event that evokes the function just below the following snippet. That means, the file is actually being loaded fine
  • A regular expression turn to space tree view --ask for help

    Dear All,      We have been using Jquery for some time,Now we want to find a way to realize  regular expression  turn to a spacetree view for show up and edit   we need some help! for example: a regular expression as : IF(SUMIF(G3:H16,>20,G3:H16),B3,SUM(1,{1,2,3})) turn to spacetree or call mind-mapping view as:
  • Information about iterate through children In JQuery

    Hello everybody. I have an tag of type 'article' in my html page.  I want to iterate though all its child and grandchild nodes, and give them an ID if they lack one. So I tried this code as a test:  $(document).ready(function () {             $("#ArticleToHighlightRFS").find("*").each(function (i) {                 alert (this.id);              });         }) The idea is that 'find()' would get all descendant nodes that are not text nodes, and would list their ids.  If they don't have ids, I suppose
  • Fill parent div on drag 'n drop

    Hi, i am having a problem with making a div(.drag) take up all the space when dragged and dropped onto another div(#block)  http://codepen.io/benasl/pen/qaJBPd?editors=0110 . And when moved out of that #block i need the .drag div to be the size it was before. EDIT////////////// I found this simple example of drag and drop http://jsfiddle.net/wj4ak/5/ however still do not know how to make a div fill the parent div when dropped.
  • Problem about extend the goBack() Button

    Hello everyone! I created a custom "Back to previous page" button with the following function: function goBack() {     window.history.go(-1); } Clicking on the button, brings you to the previous page. However if the page was a form, the values in the form fields aren't there any more. How can I extend the goBack() function, so that if I go back to a form, the form field values are still there? Thank You! Ads: FPT Telecom hân hạnh mang đến cho khách hàng dịch vụ internet fpt hà nội sử dụng công nghệ
  • 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