change in cell content of salary or bonus or deduction in table cells automatically affect in total
Hi i have table have 5 comnun Name Salary Bonus Deduction Total ahmed 500 500 100 900 calculation of total is Total=Salary+Bonus-Deduction and total in red color according to my code what i need actually if i changed in Salary cell or Bonus cell or Deduction cell affect in total cell suppose i added row above then edit salary from 500 to 2000 meaning in this time row will be as bellow ahmed 2000 500 100 2400 total will be 2400 with green color i can do by button but
Shifting List Items Positions
On my web page I have a horizontal unordered list with three list items. Below the unordered list are left and right arrows. I would like to move a list item by selecting it then clicking the left or right arrow to move it left or right. That also means the siblings of the selected list item will also have to move to new locations. I was able to select a list item then click the left or right arrow to change it's index value. However that does not move the list items to where they need to be. Please
After adding row cell in table not converted to textbox issue
Hi I need after i add row convert all cell found in row converted to text box in code below i can add row success but i cannot converted all celles in row to text box i try to make row added as text box but not got my code as below @{ Layout = null; } <!DOCTYPE html> <html> <head> <meta name="viewport" content="width=device-width" /> <title>Index</title> <script src="~/Scripts/jquery-1.10.2.js"></script> <script> $(function () { $("#btn").click(function ()
Want a nice library other than jQuery only for Ajax
Hey guys just had a weird question , has any one of you ever used a stand alone JS Ajax library that ? something other than jQuery. I just want to know a good up to date library that i can use , it should be AJAX only and no other functionality.
How to create independent test report?
I need to send page with QUnit report to another person, who doesn't have access to specific environment, so can't just rerun tests. But we need him to be able to filter results, collapse/extend tests and so on for analysis/review. How one can do that?
how to set height vs window size
So I have a dialog which pops up and contains a random amount of data pushing the container down below the window. The main page contains a random amount of information. A fix of this is to fix the dialog and have it set to 80% height of the window. The problem is, when the data is smaller than 80%, there is empty space between the last line of data and the bottom of the dialog. My question is, is there a way to set the dialog height to auto, but if the data pushes the container to within 20% of
Smooth scrolling when using resizable
Hi there all i the new guy hoping i can get some feedback on my code and how to make it work. So what I want to know is how can I scroll the page down smoothly as I resize a div past the bottom of the browser. So far what I have set up is that when you resize the div and it gets to the last 30px of of the browser, it starts to scroll the page down. That part works, but it's jerky when doing so. My code: // $maxHeight is set above this, it just takes all the elements within the div and and get's
Find and add class for menu.
I'm working on a simple full width menu whereby the list items are in one div and the inner menu is somewhere else. i have done a fiddle - https://jsfiddle.net/szrqwL9h/ Basically i need to link each navigation item to the dropdown but this needs to be done in a way if more top level categories are added the menu will open for a new category. Any help would be appreciated. i did try $(".MastHead").find("NavDropdown").addClass('open');But didnt seem to work
Some icons in Jquery UI 1.12 have changed slightly their position?
I'm upgrading from version 1.11 to 1.12 and I noticed that in the stylesheet definition some icons changed their location on the sprite 1 pixel. For example: Now: .ui-icon-triangle-1-s { background-position: -65px -16px; } Before: .ui-icon-triangle-1-s { background-position: -64px -16px; } Now: .ui-icon-arrow-1-s { background-position: -65px -32px; } Before: .ui-icon-arrow-1-s { background-position: -64px -32px; } Other position changes involve ".ui-icon-caret-1-s" and ".ui-icon-arrowthick-1-n"
AJAX: Sync faster than than Async?
You wouldn't think so, but in Chromes Developer Tools Network tab, I can see Async: false returning results faster then Async : true. I want to use Async:true, but is it slower... (and wont lock the browser). These are NOT time intensive calls.. Async avg = 800ms, Sync avg 300ms. I'm running 9 requests simultaneously, because of the 6 simultaneous connects limit, I see 3 are queued when running Async. FYI: jquery-1.6.2 Any explanation why Async:true is slower? I can publish snapshots of the
select menu widgets does not reset selectedIndex when recreated.
Hi, In our JQM application, we recreate option lists for a select menu widgets, but the selected index does not reset to -1 when options are recreated. there is demo http://1.zgwphpt.applinzi.com/zgjs_test.html <div data-role="content"> <input type="button" value="click to test" onclick="test();"> </input> <select id="sel-test"> </select> </div> function test(){ $("#sel-test").empty(); for(var i = 1;i <10; i++){ var opt
dropdown selected value is not firing in IE and working in chrome
<script type="text/javascript" src="jquery.js"></script> <script> $(document).live('dblclick', function(event){ var $target = $(event.target); if($target.is('select option:selected',this)){ alert('ok') } }); </script> </head> <body> <select name="select" id="select" size="10"> <option value="one">one</option> <option value="ert">ert</option> </select> //This code is working fine in chrome but not working in IE.I wanted to work this code I am I am double clicking on element only.My
Scroll is not working on ios9 using jquery mobile 1.4.5, Please help me.
Dear All, My website scroll is not working on ios9 using jquery mobile 1.4.5. I already added "style="overflow-y:scroll;-webkit-overflow-scrolling:touch;" but it won't changed. So, I changed -webkit-overflow-scrolling:auto. It is working well but no smooth. How to do to smooth the scroll. Please help me.
[SOLVED] Page not scrolling right while dragging ui draggables
I would like my page content to scroll right on smaller screen sizes while dragging draggables. How can I achieve this? You can see the issue here Login using user demo p/w demo99 Navigate to the menu planner under "menu planning" in the top dropdown menu. Reduce the browser width so that some of the menu planner is not visible Open the left menu, navigate to a recipe in the Recipes menu and try dragging it to somewhere on the menu planner that is not currently visible.
Autocomplete - Custom data and display
I cannot make it works. There is a Products table (codigo, descripcion, precio, cantidad), typing part of the codigo field should appear the other fields on the list, to select one. However, the list appears with the correct amount of records but with UNDEFINED on every value. Any idea about why the script is not taking properly the values sent by search.php ? Thank you ! INDEX.PHP <script> $( function() { $( "#codigo" ).autocomplete({ minLength: 0, source: 'search.php',
Having Issue on Simple Custom Plugin
Can you please take a look at this demo and let me know why I am not able to pass two different options into my plugin? $.fn.contact = function() { opt1: function() { this.append('<a >Hi</a>'); this.css("color", "red"); return this; }, opt1: function() { this.append('<a >Bye</a>'); this.css("color", "red"); return this; } }; $(".plug-txt").contact({ opt1 }); <div class="container"> <div class="plug-txt"> </div> </div>
advice please: unable to clone a row and dynamically change the second select value when changing the first select
I have dynamically added new row by cloning the last row. The row contains two select picker control. I made another function that dynamically change the value of the second select when changing the first select. This function is not working on the cloned rows. Any idea what I made wrong?? <html> <head> <script type="text/javascript" src="./include/jquery/jquery-1.2.6.min.js"></script> <script type="text/javascript"> $(document).ready(function () { $('#btnDel').attr('disabled', 'disabled');
Hellp with Jquery Argument / Statement
I have a custom piece of script that i am trying to modify. The function of this is to display a Pricing Table. One product may have hundreds of pricing tables depending on what attributes are chosen. As it stands, it will only show one at a time and only if attributes are selected. /** * VARIABLE PRODUCT PRICING TABLE */ function rp_wcdpd_switch_variable_pricing_tables(element_id) { jQuery('.rp_wcdpd_pricing_table_variation').hide(); jQuery(element_id).show(); } if (jQuery('.rp_wcdpd_pricing_table_variation').length)
How to use foreach loop in jquery?
How to loop in jquery? I am having 1 issue like: var current = 0; jQuery(".bod-item").each(function() { alert("#pi-"+current); jQuery("#pi-"+current).click(function(){ alert("#mob-"+current); jQuery("#mob-"+current).slideToggle("slow"); }); }); current++; Now what I want is I have 3 `bod-item` Each bod item has its separate id like: bod-item #pi-0 bod-item #pi-1 bod-item #pi-2 When #pi-0 gets clicked,
How to do this JQuery Menu effect?
i want my website can add this function or copy this function. How to do this? When i mouse hit the photo. The photo will display some word. the photo below: the website address: http://activtek.eu/ Thank you very much for your help.
Bend or Wind Effect
I'm hoping someone can help me, I want to apply a dynamics effect, wind to be exact whereas the image sways, left and right; as long as I have control over the pivot for the image, any suggestions, besides GSAP although great library, this it cannot do unless I go the HTML canvas route which is a bit much for this effect.
getting my 1st query to work
Hi, Trying to work out why this query wont work. Some background is that the site is a DNN site with a specific forms module. Its common practice for knowledgeable users to insert jquery but I just cant seem to get mine going. As a starting point, I just want to hide a field & label that sit in their own row. Thanks to a member I have determined that the page is running 1.9.1 Code I have used is (I think the system puts in (jQuery);). Below that is the row that is being referred to. </script> <script
Troubleshooting approach for my 1st script
Hi, I'm trying to get my 1st ever script going inside a page that I suspect already has Jquery loaded. 1st question before trying to work whit it wont work is how can I be sure that Jquery is in fact loaded to the page? Firebug shows JQuery under script tag in the watch section. There is no errors on the Console tab. (javascript errors enabled) Thank in advance Todd
Assign key value pair in each loop
I'm trying to assign key/value variable pairs to an array w/in an each loop, but keep getting undefined on line #6 on the second pass of the loop. My key (mylabel) & value (myvalue) are extracted from form inputs. I'm going to post this to a php file to send out the responses. var arck = 0; $('all my form targets').each(function() { var mylabel = some text; var myvalue = some text; if (arck == 0) {var post_data = new Array(); arck = 1} post_data[mylabel] = myvalue; }); Simple example of
Adding content to an iframe
Hi, Looking at these pen, I'm trying to add content to an iframe. Adding content to an iframe Another example What am I doing wrong? What is the best way to add content to an iframe? Thanks
how to generate dropdownlist dynamically without repeating the selected items in previous fields
Hi i need to avoid already selected option in dynamically generated fields. How to achive this. Please see the image. and updated link https://plnkr.co/edit/aQxytwuYldBzy1dzBQl5?p=preview
jQuery Syntax assistance filter function - wrap element according to condition
Using jQuery version: jquery-1.11.1.min.js I have code that shows or hides elements according to filter.I need help including a condition where if the browser is IE then according to the filter wrap the unmatching elements with a SPAN and hide them, and the other way around - unspan and show. I do not know the syntax and I failed repeatedly. I'm really stuck, please help (if you can by tweaking my code) My Code: <!--This is where I filter the ListBox (select) >> (option) elements via keystrokes -->
Running the datepicker library initialization code after loading in using getScript.
I'm running datepicker controls on several pages and I want to put as much of the datepicker management in one place/file as I can, so to this end I have created a wrapper for datepicker, that loads the datepicker library and contains several functions that patch datepicker features/functionality to work the way that I need. The wrapper file is loaded in each page using the normal <script src> tag, after the JQuery library is loaded. Inside the wrapper file the datepicker library is loaded using
Identifying string "No " causing great anquish
Hello. I am trying to hide an associated 'tr' when a value in a child 'td' == "No " in the html the No string is written No For the life of me I can't figure out how to specify this in an if statement so i can hide the row. If you would like, the fiddle is here: https://jsfiddle.net/vhabhsrosed/sj3pxc50/12/ my desperate attempts at code are as follows: HTML <table> <TR><TD width=190 class=ms-formlabel noWrap vAlign=top><NOBR>Request Expedited</NOBR></TD> <TD width=400 class=ms-formbody id=n17WPQ6
Jquery - Sortable : How to prevent the drag should not goes to below after a desied row.
Hi All, I have a query that , I am using jquery sortable http://jqueryui.com/sortable/#default Open the above link , My requirement is that if any user drag the item 1 in y direction and when the item 3 goes up the y direction drag should be stopped. Means dragging element should not drag below the item-3. Only possible drop area of item 1 is between item 2 and item 3 between item3 and item 4 help me to do this.
Targeting elements except $(this).children(element)
Hello, guys. Here is the code, which i am typing about http://codepen.io/Jacgues/pen/AXakkg As you can see, I ve used to methods to achieve proper funcionality of the menu. The problem is whenever you click Cart position, it doesn't show up. Seems like it is not targeted correctly, so all elements of this kind are "hide()" but no this particular one, which i would like to set as an exception. In case of clicking Account or Help, the toggle() doesn't work. My goal is to acheive toggling the child
jQuery start and stop in asynchronous code
Hi, I was able to stop and restart an animation with the following code. Could someone who has some understanding tell me if this is a good way? I have seen there is a way to pass a variable like “fx” to the queue dequeuer and clearQueue functions. I don’t know how to use it yet; could somebody show an example. I am thinking that it could be helpful here, so I can remove a queue for some time and pick it up later (e.g mouseover). This project has taught me about asynchronous code because it is underneath
Load menu from html file is not working
hi. i`m trying to load a menu from an other html page. (something simple, but it`s not working) My index.html: <script src="js/jquery.js"></script> <script src="https://oss.maxcdn.com/libs/html5shiv/3.7.0/html5shiv.js"></script> <script src="https://oss.maxcdn.com/libs/respond.js/1.4.2/respond.min.js"></script> <![endif]--> <script type="text/javascript"> $(document).ready(function() { $('#navbar').load('nav.html'); });
Checking if a selector and a method combination worked
I want to test if something was successfully appended because I do not know if the selector worked (actually selected anything or even was a valid selector). I read that you can test if a selector worked with if ( $('#someDiv').length ){ } But would this also work for if ( $('#someDiv').append('<p>appended</p>').length ){ } Or do I need to do a plain selection first without a chained function, and then append, as in the first example?
get the value of row before changing in table if cancel click jquery
in my code below i can edit row success without any error but if i need to cancel value edited in row OR get value before changed what i write to cancel edit in row in table by using jquery my code as following @{ Layout = null; } <!DOCTYPE html> <html> <head> <meta name="viewport" content="width=device-width" /> <title>Index</title> <script src="~/Scripts/jquery-1.10.2.js"></script> <script> $(function () { $("#btn").click(function () {
Getting contents of table cell
for(i=0; i<lotteries.length; i++){ document.write("\ \ \ <table id='lot"+[i]+"'><tr>\ \ <td>\ <table border='3'>\ \ <tr> <script language='javascript'> if(lotteries[i][5]=='') {document.write('<td width='+(lotteries[i][3]*7+12)+'
Append after element was created without reload
Hey! I have page. Then I create element like: <div id="element1></div> I need add something to this element without reload page... When I do something like: $(document).on('click', '...', function(){ $('#element1').append('...'); }); This doesn't work ( How I can do this ? pls help...
How to add a drop down menu to my webite
Hello everyone, I'm having trouble adding a drop down menu. After trying for hours to get it to work, I just finally restored my menu to the way it was and decided to ask for help. I can give you more code if needed but here is my HTML for my menu <div class="menu-wrapper"> <div class="menu"> <ul> <li><a href="index.html" class="active">Home</a></li> <li><a href="about.html">About Us</a></li> <li><a href="tutorials.html">Tutorials</a></li> <ul><li><a href="tutorials.html">Testing
draggable object is pushing divs out of the way instead of hovering over them
I have a draggable card. I have drop targets in a container div. If I drag the card over any other part of the page then then the card hovers over the page. If I try to hover the card over the drop box container it pushes it down the screen andrefuses to enter it. You can see it in action here: https://jqueryuiexperimentscratchpad-gedq.c9users.io/ Click on the card stack to generate a card. Why should a drag item refuse to enter one div but not another?
Use Ajax Object
I use a ajax in my js file. I want to use responseText to same js file. My code is : var colors = $.ajax({ url: "GetSession.php" }); console.log(colors.responseText); but it wont work! How I use from response text as a variable in the same js file?
Next Page