If jQuery is used then the element is hidden even when it shouldn't
The site www.jaanavuola.com is using simple jQuery code for hiding and showing mobile menu. jQuery(document).ready(function($){ // $(".site-header")site.hide(); // $(".open-close-mob-nav").show(); $('.open-close-mob-nav').click(function(){ $(".site-header").fadeToggle(400); }); }); The button (upper right corner - two lines and text "Valikko") appears when the windows is max 860px wide. The site has normally a side bar navigation panel which
Insert data in DataBase - Using jQuey Seat Chart plugin
I use an adaptation of this plugin jQuery Seat Chart Here it is some lines: click: function () { //Click event if (this.status() == 'available') { //optional seat var maxSeats = 3; var ms = sc.find('selected').length; //alert(ms); if (ms < maxSeats) { price = this.settings.data.price; $('<option selected>R'+(this.settings.row+1)+' S'+this.settings.label+'</option>') .attr('id', 'cart-item-'+this.settings.id)
input field on "link-field"
Hello, is it possible to place an Input-Field (type=number) on an "link-field" (<a href="...)? If yes, how to achieve this? Thanks in advance, Afox PS: I already tried something like this: http://stackoverflow.com/questions/796087/make-a-div-into-a-link The problem is that if I try to click into the input-field to change its value, it´s like i clicked the link.
Read value only
Hi, I have these: [12] [7] [345] How can I using JQuery to read the numbers only without te brackets? Thanks, Jassim
Jquery Ajax using Spring 2.5.6 MVC Controller
I have done an ajax call as below in my jsp - $(document).ready(function () { $('#alarmsDetailsWebModel').submit( function(event) { $.ajax({ url : "/ratp-ssi-project-web/ui/project/modules/alarmmanagement/alarmdetails", type : "GET", dataType:"json", success : function(data) { /* data = $.parseJSON(data); alert(data); for (i = 0; i < data.responseHTML.length; i++){ alert(data.responseHTML[i]); } */ }, error : function(xhr, status, error) { alert(xhr.responseText); } }); return false;
attaching associated attributes from populated select options
So I've got a select element A that populates select element B with lists of classes, and whatever option of B is chosen changes some CSS. What I want is for that class option chosen in select element B to also populate multiple text boxes with data also associated with that class. I know that in a single select element i can list multiple values for each option, like: <option value="abc" someothervalue="def">whatever</option> I also know that I could set up some PHP code that connects to a
datatable order european data
HI i have a datatable this is the html : <div class='table-responsive'> <table id='datatable' class='table table-striped table-bordered table-advance table-hover'> <thead> <tr> <th>Cliente</th> <th>Data</th> <th>Ora Partenza</th> <th>Ora Arrivo</th> <th>Luogo Partenza</th> <th>Luogo Arrivo</th> <th>Note</th> </tr> </thead> <tbody> <tr> <td> Hotel Baglioni </td> <td> 13-02-2017</td> <td> 04:00</td> <td> 04:30</td> <td> Barberino Di Mugello</td> <td> Trani</td> <td> pto</td> </tr> <tr>
binding dynamic javascript array on simple-datagrid jquery plugin
Hi, I am using simple-datagrid plugin, and i try to bind my source data like an array to it. i create an html table <table id="tbl"> i loop from objects retrieved from sdk.REST.Retrievemultiple. the result is stocked on a table var tab =[]; for(var i=0; i<results.length;i++){ tab["id"]= results[i].id; tab["domaine"]=resutls[i].domaine; $('#tbl').simple-datagrid('loadData', tab); not working i have no rows. thanks for your help Regards }
Online radio streaming delay
On urbansunsets.com I am streaming online radio from radio.co. It does work, but after a period of continuous playing, there is a delay at the part that shows what is currently playing. <div class="col-lg-12 col-sm-12"> <div id="radio_player"> <div class="default-player"> <audio width="320" height="240" controls playsinline id="audio_player"> <source src="http://stream.radio.co/sedf8bacc9/listen" type="audio/mpeg"> </audio> </div> <div id="audioplayer"> <button id="pButton" class="pause"></button>
Dr Simon Andrew casey - How to handle jQuery conflicts problem using multiple jQuery versions on the same page ??
1 <script src="http://ajax.aspnetcdn.com/ajax/jquery.ui/1.9.2/jquery-ui.min.js" type="text/javascript"></script> Please there is a conflit between the jquery above and the one below, the one above only works for AutoComplete while the one below only works for other controls in my page like dropdown and other controls. The issues is this, if i place the Jquery above on the page for AutoComplete it will cause other controls using jquery to stop working while only Autocomplete textbox will be working,
how to place blackground dinamic a button?
my code is this: <!DOCTYPE html> <html> <head> <title>FirstApp</title> <script src="lib/jquery.js"></script> </head> <body> <div id="divTest1"></div> <script type="text/javascript"> function createRefreshButton() { return $('<button/>', { text: 'Refresh Data', id: 'btn_refresh', click: ClickRefresh }); } $('body').append(createRefreshButton()) function ClickRefresh() { alert('refresh'); } </script> </body> </html> sorry i am novate and for my english :(
How do I use the jquery autocomplete to read a specific column of a *.xls file?
I'm trying to find a way to build a "script writer" in order to more easily write executable scripts if I can download the document, but not put anything on the server as far as code goes so far. What do you recommend for having the JavaScript read the *.xls, and populate the autocomplete from the data available?
filter() + match() does not work
Assume I have a webpage with lots of lines similar to <tr> <td> </td> </tr> The tags avove could be spread over multiple lines. Between them could be zero, one or more whitespaces. I want to get rid of them all. Therefore I coded the following two jQuery statements: $("td").filter( function(){ return $(this).html().match(/^\s*$/) }).remove(); $("tr").filter( function(){ return $(this).html().match(/^\s*$/) }).remove(); The first should remove all inner <td> </td> occurencies. The last then
DataTables: When scroll bar of tbody is hidden, fixed column gets messed up
I've got a table which includes: first Column is fixed tfoot horizontal scroll bar of tfoot have hidden horizontal scroll bar of tbody. Fiddle:https://jsfiddle.net/jbeteta/6sxh3gbk/12/ $(function() { $('#example').DataTable({ "fnInitComplete": function () { // Disable scrolling in Head $('.dataTables_scrollHead').css({ 'overflow-y': 'hidden !important'
Why don't any of the demos work?
None of the demos at http://jqueryui.com/demos/ seem to work. Apparently the pages can't find jQuery (among other things). Sure would be nice if I could see how jQuery-ui stuff works before I try to use it!
Creating a (very simple) drag and drop list maker?
I am desperately looking for a simple bit of code/script/witchcraft that could help me create simple unformatted text lists. Looking at jQuery, it looks very likely this function has already been developed somewhere. Which would be great as I've never written a line of code in my life and I have no clue where to start. Ideally, i'd like to be able to drag and drop items from a list of predefined "rooms", "actions" and "items" to quickly assemble a list in text format. E.g.: Bedroom1 (room) Specify
Juery hover menu content
When I hover my menu content of the menu (single page template) will appear in the below. othe menu content are hide. how its going to achieve in jquery? <aside class="main-sidebar"> <section class="sidebar"> <ul class="sidebar-menu"> <li class="header">MAIN NAVIGATION</li> <li class="active1 treeview"> <a href="#menu1"> <i class="fa fa-link"></i> <span>menu1</span> <span class="pull-right-container">
debug a promise
I have some old code I am trying to get to work. The debugger stops where it can't load the user template on the error line below with asterisks. I'm guessing the problem is in the promise. Can I just take out some lines on the promise to force it to work for a demo to make it more straightforward? I don't have any data just a default user in the model. Don't need it to be in a promise. One thing I haven't figured out is this line " if(debug && window.console) " I don't know if debug is on
Max value in a selector
Dear friends, Good Afternoon i need your help to find the maximum value and to add +10 of maximum value of the below image Id is line_no. is it possible ??? if yes please share the code friends. Thanks & Regards Thamarai
Facing Issue after migratting jquery to 3.1.1
Hello, Change ,blur,Focus events are not working for contenteeditable div , please find code below : $(".editForm :input, div[contenteditable=true]").on('change', function (i, e) { if ($(i.target).hasClass("ignorePreventRedirection")) { $(i.target).removeClass('ignorePreventRedirection'); return true; } anyFormElementModified = true; }); $(".editForm :input, div[contenteditable=true]").on('focus',
How can I attach two different callbacks to one jQuery UI widget?
With custom jQuery Ui widget, you can attach your own callback functions to it by passing options to the plugin. However, if I want to attach one callback to "generate_img" event and later on another different but not mutually exclusive behaviour to the same widget event "generate_img", the later one will replace, instead of adding to the existing behaviour. Is there a way to solve this problem? Thanks.
Select option not toggling CSS properly..
I'm trying to change the css of different SVG polygons based on select options that target their classes, but the toggle isn't working properly. Here's the select element: <select id="option1" onchange="myfunctionA(this,event)"> <option SELECTED VALUE="gray">Option 1</option> <option value="A">A</option> <option value="B">B</option> <option value="C">C</option> </select> And the jquery code that almost works is: $(document).ready(function(){
"Uncaught TypeError: base is not a constructor" with custom download
Hey, I have create a custom download http://jqueryui.com/download/#!version=1.12.1&components=111100010101000010100010110010001000000000000000 /*! jQuery UI - v1.12.1 - 2017-03-13 * http://jqueryui.com * Includes: widget.js, position.js, data.js, disable-selection.js, keycode.js, scroll-parent.js, unique-id.js, widgets/sortable.js, widgets/autocomplete.js, widgets/datepicker.js, widgets/menu.js, widgets/mouse.js, widgets/slider.js, effect.js * Copyright jQuery Foundation and other contributors; Licensed
How to select last child that is even number except for second?
How can I select the last child of a div that is an even number and for this to apply to all last children except if the last child also happens to be the second of its type? if ($this.is(':last-child')) {
$this.addClass('end');
$("<div class='clearfix'></div>").insertBefore(this);
}
job schedule
I have a job schedule that is two weeks längd. I want to make Sempel html page with a datapicker and three labels LABEL1 view selected DatePicker week No label2 view selected DatePicker day name lable3 show selected DatePicker if I work that day or I'm off. LABEL3 has 14 different cases: case1 label3.text = "work" // Monday 1 Case2 label3.text = "off" // Tuesday 1 Case3 label3.text = "off" // Wednesday 1 case4 label3.text = "work" // Thursday 1 case5 label3.text = "work" // Friday 1 case6 label3.text
Jquery datepicker different colors BeforeShowDay
down vote favorite Hello, I have a question about the BeforeShowDay function. I have 2 types of data. Once red and yellow. I would like both to be marked in the calendar on a specific date. Only the date "yellow" is displayed and this works as well. How can I extend the function, that red and yellow are displayed. A date, which either in Array eventDatesyellow and eventDatesred should stay grey (-->default). Here is my Script: <script type="text/javascript"> $(function() { var eventDatesyellow =
where i can get "jqnav.js" file.
which makes me to allow use this, class="navbox navbox2" Quick reply please
Keep original url for pushstate
I use the following function: $( document ).ajaxComplete(function() { var currenturl = window.location.href; var decodedUri = decodeURIComponent(currenturl); var decodedUri2 =decodedUri.replace("&manufacturer[]=","/").replace("&page=","/").replace("&sort=","/").replace("&order=","/"); history.pushState("", "", decodedUri2); }); I need somehow at each ajax completion to change original url and not previously changed url through pushState. With the function above at first ajax completion pushState
How do I present a summary page after user has completed his/her form?
Greetings experts, I hope this is the correct forum for this question. I have a code that dynamically creates additional table rows. What is unique about this is that it has several Add More Rows buttons that it makes it extremely difficult to present summary page for the user. Per our requirements, once user completes filling out the boxes, s/he needs to be presented with summary page to review data entered. If everything goes well, user submits records to the database. If not, user goes back, makes
Jstree load partial page after button click. Not working
I'm working with Jstree to load partial page, here is JSFiddle I want to transfer checkbox states to a php page, and get the output to be loaded into the "second" div. But nothing displayed there, and got error# 0. Please help me find the problems, thanks
Jquery Deferred
Hi, I have below snippet that uses promise. Could someone help me how can i convert this into jquery deferred ? Do not want to use promise, instead want to use $.Deferred(). Any help would be appreciated? return new Promise(function(resolve, reject) { if (!self.CheckCustomerAccount(accountNumber)) { reject(self._handleError(self._createError(null, "INVALID_account_number", self.messages.invalidAccount))); } else { if (DEBUG)
Connect to DocumentDB using JQuery
Hi, Is there any way to connect directly to DocumentDB from JQuery or it can only be through a web service call? Thanks, Jassim
jquery autocomplete - Render Item contains space Issue
Hi All, I am using below jquery autocomplete plugin <link rel="stylesheet" href="https://ajax.googleapis.com/ajax/libs/jqueryui/1.12.1/themes/smoothness/jquery-ui.css"> <script src="https://ajax.googleapis.com/ajax/libs/jqueryui/1.12.1/jquery-ui.min.js"></script> <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.12.4/jquery.min.js"></script> I have around 3 autocomplete functionality in a page. Every works perfectly except of items which returns spaces like words( "abc
wait for multiple $.ajax calls with post load animations to finish
I had a function that called a few $.ajax posts using $.when which was working, but since I added some load delay animations to the success return of the $.ajax asyn call it isn't waiting for those in the $.when <script> function tableOne() { $.ajax({ url: "/cont/_ActionOne", type: "GET", }) .done(function (partialViewResult) { var degree = 90; $(".type1").css("transform", "rotateY("
jQuery mobile, range slider and slidestop event
Good day, I was trying for a while to get the slidestop event to fire with HTML code like so: <label for="tempslider">Temperature</label> <input type="range" name="tempslider" id="tempslider" value="95" min="90" max="135" /> and JS like: $("#tempslider").on("slidestop", function(event) {console.log("temp value stop at " + $(this).val() );});But it simply would not fire. Finally I found a sample code snippet that used a variation of 'on' which attached to a parent object, like so:
jQuery mobile used into Bootstrap 4 template won't work properly
Hello, I use jQuery Mobile v1.4.5 into Bootstrap 4 the "offcanvas" template example. Here is the page i'm working on : http://s529471052.onlinehome.fr/1.2/sensors/sensors8.html It looks jquery mobile is not getting my small table responsive, the table reflow won't work. Would you please tell what is wrong ? I'm newbie with jquery and really don't know how i could fix it.
How can I disable jquery animations on smaller screens ie mobile phones.
Hi all, I have some jQuery animations running on my application but don't want them displaying on smaller screen ie mobiles. How can I disable jquery animations on smaller screens. If anyone can point me in the right direction it will be greatly appreciated. Tony
Do jQuery objects stored in a local variable cause detached dom nodes
From my understanding, any memory allocated for a local variable is released at the end of the function. The only time this memory release does not occur (and a detached DOM node or memory leak occurs) is when that variable is referenced in a closure created within that local scope, and not properly nulled out inside the closure. For example, the variable detached below (source - https://developer.chrome.com/devtools/docs/heap-profiling-dom-leaks): function start() { var p = document.getElementById("p");
jQuery Mobile sites who pass render-blocking JavaScript & CSS in above-the-fold content tests
You know any? Below are several prominent jQuery Mobile sites that fail: Here's some that fail: https://developers.google.com/speed/pagespeed/insights/?url=http://www.menshealth.com/ https://developers.google.com/speed/pagespeed/insights/?url=http://www.cbssports.com/ https://developers.google.com/speed/pagespeed/insights/?url=http://streaming-unlimited.com/ Here's sites which may use jQuery Mobile: https://publicwww.com/websites/%22ajax.googleapis.com%2Fajax%2Flibs%2Fjquerymobile%2F1.4.5%2Fjquery.mobile.min.js%22/
Fixed! Need help w/ toggling anchor + button
How can i make a jQuery script that toggles visibility of a div and at the same time toggles anchor text of a button? function toggle(user_id) { e = document.getElementById('toggleUserinfo_' + user_id); a = document.getElementById('displayUserinfo_' + user_id); if (e.style.display == 'block') { e.style.display = 'none'; a.innerHTML = ‘Open'; } else { e.style.display = 'block'; a.innerHTML = ‘Close'; } } I tried to search for it and came up with the following.
Next Page