Click Event Not Firing on Dynamic Table Row w/ Button
I have a table that loads just fine. Each row has an ID matching the database. The last row in the table is there to insert a new row. When the user clicks the Add button the data is added to the database and the row is displayed in the table. Each row in the table contains a button for deleting that row. Here is the button markup: <button class="btn btn-default delete-increment" aria-label="Delete" data-id="1"> <span class="glyphicon glyphicon-trash" aria-hidden="true"></span> <span class="sr-only">Delete</span>
How to only show toggle when More Clicked and not any links nested in <li>
When I click anything nested in the li it toggle opens. How do I make it so only when I click "More"? url: http://198.12.124.155/meixicn/test/ $('.ajax-filters-li ul').each(function(){ var $this = $(this), lis = $this.find('li:gt(7)').hide(); if(lis.length>0){ $this.append($('<a class="more">').text('More').click(function(){ lis.slideToggle();$(this).text($(this).text() === 'More' ? 'Less' : 'More'); }));}});
Returning from href
Hi ... I have a multipage web application, in which I utilise Jquery. The first page (index) specifies all javascript libraries I am using. Variables are passed between pages utilising "window.xxxxx"). all works fine. Now, when I click on an href, which directs me to a different site, and want to return, using the browser back button, all my definitions of javascript libraries are lost, and all window.xxx variables. It looks like I am returning to a new window. I have tried the _self, _parent etc
Jquery help on div
Hi, I am trying to build client side Grid. i will be pulling the values from db and making it on the div box. . let us take an example of i have 1000 records in my backend and on the grid i will diaply 1000 boxes by filling it's values. I just gven one box detail on this post. Am struggling to create dynamic box and add it to the grid shows in the example link along with pagination. Can you please help on creating the box dynamically and addding to the placeholder using client side code. Any
Banner Fixed Floating in the sidebar through the footer
Hello everybody , I'm doing a floating banner for my blog in the sidebar , the more the banner is exceeding the footer , the blog is : http://www.aisenhor.com.br My Code JS: jQuery(document).ready(function ($) { $('[data-toggle="tooltip"]').tooltip(); $('ul.nav li.dropdown, ul.nav li.dropdown-submenu').hover(function() { $(this).find(' > .dropdown-menu').stop(true, true).delay(200).fadeIn(); }, function() { $(this).find(' > .dropdown-menu').stop(true, true).delay(200).fadeOut(); });
Show/hide Div
Hello, i have downloaded the new jQuery 1.11.3 so i can use the show/hide effect on my webpage, but it doesn't work, this is codes i used. <html> <head> <title>test</title> <link href="styles.css" type="text/css" rel="stylesheet" media="screen"> </head> <body> <Div id="buttons"><input type="button" id="hide" value="hide"> <input type="button" id="show" value="show"> </Div> <Div id="content"> <h2> This is the text i want to Show/hide by clicking on the hide show
Load Image from another URL
Hello, i want to ask if it is possible to load a image from another URL with jquery? My Problem is, i have a picture on my index page, and if i wan't to show this image, i need to klick on it and it loads in another page. If don't want it so, i want to have a popup and load the popup with jquery. Now i need to load the image url from the another page, it is possible? If yes, how? Best Regards Slexout
jQuery Validation Form span not working
am using a online blog form validation which is done in jQuery, The problem I have with this file is when I reuse the input code for a different id, the span alert is not showing up. I have done the jsFiddle . http://jsfiddle.net/chetanmani/11wedxrq/1/ Please look into it and help me out. Thank you
did not understand this code
Hi, I found this code : http://jsfiddle.net/mlotfi/91w82bLf/ , I did not understand this line : (text.indexOf(valThis) == 0) ? $(this).parent().show() : $(this).parent().hide(); Thanks, your help is appreciated.
Why must I click the anchor element twice for the function to run?
////////////////////////// the jQuery in my nav.js file ///////////////////////////// (function($) { $('a.toggle-menu-icon').click(function() { $('nav.page-nav').addClass('open').toggle(); }); }(jQuery)); /////////////////////////// the HTML //////////////////////////////////// <div> <nav class="page-nav top-nav" role="navigation"> <?php wp_nav_menu( array( ) ); ?> </nav> <a class="toggle-menu-icon toggle-main-navigation"> <span class="screen-reader-text">Toggle Main Navigation</span> </a>
I want to search the item from my menu. If search content available in child
<script> $(document).ready(function() { $('.s').keyup(function(){ var valThis = $(this).val().toLowerCase(); $('.countryList>li').each(function(){ $('.countryList1>li').hide(); var text = $(this).text().toLowerCase(); (text.indexOf(valThis) == 0) ? $(this).show() : $(this).hide('.countryList1>li'); }); }); }); </script> <input placeholder="Search..." class="s" type="text" /> <ul class="countryList"> <li><a href="#3"><span class="title">India</span></a> <span class="arrow"></span> <ul class="countryList1">
Is the jQuery version I can use limited by the .NET version I am using (in Sharepoint apps)?
Very soon (starting next week), I am going to be doing Sharepoint 2010 development, which uses .NET 3.5 JavaScript / jQuery is part of this world, or can be. But are there limitations on which versions of jQuery can be used with particular versions of .NET? IOW, is there a chart somewhere that shows which jQuery versions are compatible with the various versions of .NET? Or can I use the latest jQuery version regardless of the .NET version in play?
filter by checkbox
I am trying to filter an array by checkboxed, but the console.log did not display anything. http://jsfiddle.net/mlotfi/jxnyscLc/ Thanks.
Hi. Creating Hangman game with Jquery, need help
Hallo gaiz. I will not paste all of code that I have used, I will show where I am stacking : ********** this.wrd = this.randomWord(), ***** randomWord: function(){ return this._wordData(this.words[ Math.floor(Math.random() * this.words.length)].word ); }, ^^^ this is a random word generator. ^^^^ then i am creating 2 object : var wordList = [ { word: "book", hint: "this is my book hint" }, { word: "room", hint: "this is my room hint" } ]; s and now when I am using for example
out of stack space error in jquery-min.js
hello , I use jquery in a SharePoint publishing page and i get a popup window only in IE8 64 bits with "stack overflow at line 5" message , when i see in the console of IE , i see the message "out of stack space jquery.mins.js at line 9531". Anyone have seen this message before ? How to know the jquery code that cause this error ? Any help will be appreciated. Thanks
prop not working ie
I'm using version 2.1.3 of JQuery and IE 11. These calls were working in IE 8 with JQuery 1.11.2, but the company is moving everyone to IE 11 and we are tying to get our site ready for the change. Here's my HTML: < span class ="elemObject"> < select name ="EditArea" id ="EditArea" elementnumid ="" size ="15" elementid ="EditArea" issearchable ="True" initvalue ="" ismulti ="False" fieldtype ="Dropdown" validationErr ="" parentnumid ="0" permission ="R/W"> < option value ="crap"> Stuff </ option
Sidebar not fixing properly with jquery ".css" function. #solved
Hi, in search for a fixed sidebar jQuery code, I found this tutorial , which has this fiddle example . The html , css and js codes are very simple, and while kept simple it works fine. Though, when I tried to insert it in my sandbox project , something goes wrong. Within my project selectors specifications, the js script goes like this: jQuery(document).ready(function () { var length = jQuery('.product-shop').height() - jQuery('#sidebar').height() + jQuery('.product-shop').offset().top; jQuery(window).scroll(function
How can i filter select box with appended values?
Hi guys, I created a view with two filter box and two selectbox. When user type a value in the filter box it will filter the related selectbox. And when user clicks on an element in the select box it will transfer the item to the other selectbox, vice verse. Problem is the 2nd filter is not working.. Please take a look at my code here. http://plnkr.co/edit/9ZgUVxfIqk1uHUxaLjPz?p=preview PS: please expand the view screen alittle. My UI is quite wide. Thanks in advance!
Need help with JQ Countdown please
Hi I'm a NUB when it comes to JQ and trying to learn. I'm using the LWTJQ countdown... it's seems kinda simple, I just can't find where to set the date for it to actually countdown to a specific time. I want the countdown to stop on April 1, 2015 If someone can please help it would be much appreciated... Here's the code (function($){ $.fn.countDown = function (options) { config = {}; $.extend(config, options); diffSecs = this.setCountDown(config); if (config.onComplete)
Obtaining key, value from $.each - json OBJECT; NOT array
Below is returned from my firebug. From console.dir(pData); and console.log("type ... "+typeof(pData))= 'object'; pData is returned from AJAX call to .PHP file. I'm trying to use $.each to obtain key, value pairs from pData. Does pData have to be converted to an array first since this doesn't seem to work? $.each(pData, function(key, value) { document.write(this.key+"..."+this.value+"<br />"); }); Gives me undefined 44 times. (length of pData). Appreciate help in fixing this. 0 Object
Problem with appending strings + vars
Okay so I need to append <li data-rel="close" data-gmapping='{"id":"m_1","latlng":{"lat":50.708664,"lng":-1.286839},"tags":"drupal"}'> That to my HTML I know all the code for that already. The problem is I need to add to variables in <li data-rel="close" data-gmapping='{"id":"m_1","latlng":{"lat":ONE HERE,"lng":THE OTHER HERE},"tags":"drupal"}'> And when I try do it I just get errors and can't the problem is I can't work with all the ' s and "s that already exist in there but they need to be there
Pop up
How to create a effective pop up when hovered on an image
Ajax / JQuery insert into MySql failed
Hello to everybody! I am total lost. What is wrong? I try to INSERT INTO mysql. It add a row in MySQL , but no data. I am sitting sin ce some days on it and dont understand it. I checked houndreds of web pages. I need help!!! ... Here is the full code: //+++++++++++++++++++++++++++++++++++++++++++++++++ Javascript: //+++++++++++++++++++++++++++++++++++++++++++++++++ function jsRecordInsertWrite() { var jsObject = { "ID": document.form_articles.ID.value, "Item":
pieces plug in
http://www.megalocode.com/pieces/animations i tried this one $(document).ready(function(){ $("#pieces").pieces({ onClick:{ animation:"pieces70", speed:20, stagger:20 } });}); but it is not animating.iwant plug in of pieces.
Dynamically setting child DIV height to parent DIV height
I would like to dynamically set a child DIV height to the parent's DIV height, minus the height of another child element. Something like this: HTML <div id="intro"> <div id="top-bar"></div> <div class="title">sdasfas</div> </div> CSS #intro { height: 600px; } #top-bar { height: 180px; } jQuery placed at very bottom of document right before </body> (jQuery library is loaded earlier in the document) <script type="text/javascript"> $(window).resize(function() { var intro_height = $("#intro").height();
Jquery empty bug?
The following code will trigger alert twice. Looks like empty() does not remove events as promised. Looks like remove works(see commented code). Is it a Jquery bug? or it's only me. <div id = 'cc'> <div id="div1"> <button class="this2">button 2</button> </div> </div> <script>var c = $('#div1'); var cc=0; c.on('click','.this2', function() { cc++; alert(cc);}); c.empty().off("*"); c.append('<button class="this2">button 2</button>'); c.on('click','.this2', function() { cc++; alert(cc);}); /*
Internet Explorer breaks all/most of my Jquery :(
In a wordpress site, I just upgraded to the latest version then started tidying up the theme... it used a lot of older jquery plugins - so to keep it working as is, I didn't upgrade to the latest versions. Everything works fine in all browsers except internet explorer (9 & 10 tested) - I get these errors in the Debugger: SCRIPT1003: Expected ':' File: jquery.js, Line: 2, Column: 2453 SCRIPT1006: Expected ')' File: jquery-migrate.min.js, Line: 2, Column: 1840 SCRIPT1004: Expected ';' File: domain.com,
in array
hey guys im having a slight probelm with the in array function (obviously my fault)...but what im trying to do is if a category isnt in the count array then for it to be added to array with a value of 1. if category exists in array increase value by 1. here is my code which keps just running this line below even if in array count[item.category] = 1; var count = []; // loop start if ($.inArray(item.category, count) === -1){ count[item.category] = 1; } else
jQuery.confirm title default
Hi I have a confirm popup that appears as expected, is there a simple / quick & dirty way to change the label at the top? At the moment it just gives the full URL in the address bar as the title. $(document).ready(function (event) { $(document).submit(function (event) { if (!confirm("Are you sure you wish to submit?")) { event.preventDefault(); }
Problem retriving the value in php from jquery.
Hi, i have populate one dropdownlist from database and now i want to send the data to the php code. i have used following functions but it doesn't working. <!DOCTYPE html> <!-- To change this license header, choose License Headers in Project Properties. To change this template file, choose Tools | Templates and open the template in the editor. --> <html> <head> <meta charset="UTF-8"> <title></title> <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.11.2/jquery.min.js"></script>
JQuery accordion scroll to top
Hi, I am using this recommended approach to scroll to the top of the accordion when it is expanded. But our developers mentioned that they are not using JQuery UI. Only JQuery. How can this be done for JQuery ? <link rel="stylesheet" href="//code.jquery.com/ui/1.11.3/themes/smoothness/jquery-ui.css"> <script type="text/javascript" src="https://ajax.googleapis.com/ajax/libs/jquery/1.7.2/jquery.min.js"></script> <script type="text/javascript" src="https://ajax.googleapis.com/ajax/libs/jqueryui/1.8.21/jquery-ui.min.js"></script>
taking array number
Hi, i have a input form in array, I'm wondering if it possible to take the array number of form name, let say <input type="text" name="text[33]"> is there a way to take the 33 from that form name? thanks a lot
I want to scroll a div on my website from any point of the window without seeing a seperate scrollbar.
Hi jQuery experts! I'm working on a website where I want a div with text in it to scroll down/up whenever I scroll down/up from any point of the window. The website is made in such a way that the user never has to scroll the page down. All information can be found in that div so I want that to go down/up when they want to read more. I have been using jQuery on regular bases. I know the syntax but I'm not an advanced user. So the objective that I want to achieve: From any point of the window a div
Element.scrollTop - what Im a doing wrong
I'm new to jQuery so this may be a stupid question, but why doesnt my code work? I'm trying to do something when the user scrolls down the page. $(window).scroll(function () { var w = $(window).scrollTop; if (w > 10) { alert("test"); } });
data attribute
hey guys im trying to get the value of a data attribute now ive tried different way but im not having no luck. can you please tell me where im going wrong $(document).ready(function() { var specific_count = 0; var specific_id = 0 $('#add_specific').click(function(){ $('#specifics').append('<li id="specific_' + specific_id + '"><input type="text" class="code" name="SpecificLabel[]" value="" placeholder="Label" /> <input type="text" class="code" name="SpecificData[]" value=""
return false on parent item click event disables child anchors?
I am trying to disable the default behavior of an anchor tag with # as the href where it returns the screen to the top of the page. Typically, that's done with return false in the javascript. In this case, I am using the following code on a parent element of a WordPress nav menu to display a submenu. It works great to stop the page from jumping, but none of the links in the sub menu work! Is there a way to have my cake and eat it too? Thanks! $('.menu-item-68').click( function () { $(this).addClass('parentHighlight');
jquery Ajax Request Queue - jump to front
I have a list of text boxes with a jquery .each() cycling an independent Ajax GET request for each one (they need to be independent and can't all be done at once) Once a user clicks on a button on the page, this is set to send a different ajax request without reloading the page. The problem I'm having is that clicking this button queues that ajax request until the .each() function has finished - then completes. Is there a way to run the click() ajax query at the samee time as the each() query is
array push
hey guys i'm having difficulty when it comes to adding a value to a array key...i've tried to push array and also looked on the internet but i've had no joy. var arr = {'words' : 'hello'}; i want to be able to add another value to the key so i get this result {'words' : ['hello', 'hey']}; i've tried arr.push("{'words':' 'hey'}"); and other variations...thank you
Auto Scroll with scrollTop()
I am trying to make a page scroll to a certain point as soon as it loads. The endgame is actually to have it delay scrolling for 2 seconds and then use an animation to scroll to this point, but right now, I will be happy to just get the scrolling working at all. Here are the two configurations I've tried. $(window).scrollTop($("#anchor").offset().top); I have also tried "body", document, "html", "html, body", etc. where window is above, as well as many different selectors where the "#anchor" is.
How to used auto tabbing in Dialog box ?
Hello everyone. I am newly on jquery and javascript. I have been working on the dialog box. when customer click on the link the dialog box open and display some data this used json. and on the dialog box has text box SSN for customer to type in SSN number and submit button. everything work great but i have only one problem that i can't figure out how to make it work, my boss wanted when customer filled in SSN number that allowed 9 digits when typing the last digits they wanted auto tabbing
Next Page