Position the tooltip
Here is my code that implements tooltips in my website: var changeTooltipPosition = function(event) { var tooltipX = event.pageX - 8; var tooltipY = event.pageY + 8; jQuery('div.tooltip').css({top: tooltipY, left: tooltipX,'z-index': '120000'}); }; This works fine and displays the tooltip as a popup window bellow and to the right of the cursor while hoovering the button. I'd like to modify the code so that the tooltip will appear just above the cursor(and the button, no change to the x dimension).
Strange results with autocomplete
I plopped an input box with auto-complete turned on and a search button on my page. My friend created some JS code to allow the auto-complete to access an array of kit names. Well, it works perfectly except for the list it generates. The list is correct and clickable but the text itself is just floating over the page content (in this case the search button). It looks kinda bazaar and is transparent in terms of the search button is clickable through the floating text. What are we missing here? Here
json not populating fields
Hello sir This might be silly question. I can populate the form fields using JSON I select a client from dropdown and based on its value (id) i call JSON and populate the respective fields what if the the client id selected from dropdown is zero (normally starting item with id=0 like pleases select) ) My Json where to put the initialization code so as to blank the fields populated earlier $('#clientid').change( function() { //change ID when selected from dropdown alert( $('#clientid').val());
J Query Date Picker Condition
Hi All, I need to display a j Query Date Picker where we have to show today and tomorrow date but if today is Saturday then i have to show Monday date also Please suggest
Number of jquery errors
Hi all, Been building a wordpress website using alot of jQuery and parts aren't working, I have tried to diagnose but had no success. I get the following errors; Can anyone else?
Datepicker prev / next buttons appearing distorted.
I just created a custom jquery ui package and tweaked few colors, but now when I implement datepicker (with no options), the previous and next buttons appear to clumsily overlap each other. Is there some css tweak I need to use to get them to appear neatly? I've used this before plenty of time and it never required anymore than choosing colors, dropping links to the css and js on the page and using the default constructor with no arguments. Please help. Trying to wrap up a project, thanks!
Going Crazy - Trying to populate Multi-Select with JSON from Ajax
I'm completely stumped. If I use returned data from a JQ object, my multi-select will not select the current options: SO THIS DOES NOT WORK: $("#truck_type").val(data.truck_type); If I hard code, it works and it's exactly the same as the value of data.truck_type $("#truck_type").val(["Tandem","Van Trailer"]); Anyone have any idea?
How do I make header bar opaque
I have a page with a header bar that contains the HTML title and a Home button. On a long page that scrolls, the header stays in the same place and the text scrolls under it, which is what I want. But the header is transparent and the text is visible under the header as it scrolls past. I want an opaque header, what do I need to change in CSS? I'm using JQM 1.4.5. The top part of my HTML looks like this: <!DOCTYPE html SYSTEM "about:legacy-compat"> <html> <head> <meta http-equiv="Content-Type" content="text/html;
Autofocus for input text field, Urgent
I want autofus for text field which i am using for search. This is coming in desktop and android browsers, but it's not working in ios app and safari browser. Help me. Thank you.
Draggable widget/function in jQueryMobile
Is there such draggable api in jQueryMobile, similar withe the draggable in jQueryUI. As below sample code: $(function() { $( "#draggable" ).draggable(); });
Posistion of window on postback
I'm using ASP.NET forms to create my pages. When I use dynamic data the data is created below the button submitted. Filling a gridview for example. I would like to re-position the window at the top of new data not the top of the page. I have ajax turned off for the page. I have tried Javascript, A anchors, and the MaintainScrollPositionOnPostback in the header. Any help would be appreciated.
Jquery Menu disable depending on User Permission
I have Jquery menu which should disabled depending upon user permission. In the below menu I get the Permission value in label and depending on 0 Stockentry.aspx,Internalsale.aspx,Vehiclesale.aspx should be disabled and value if 1 all menu should be enabled. Thanks <ul class="nav"> <li> <a href="Home.aspx">Home</a> </li> <li> <a href="VehicleEnquiry.aspx">Vehicle Enquiry</a> </li> <li> <a href="StockEntry.aspx">Purchase Vehicle</a> </li> <li> <a href="InternalSale.aspx">Internal Sale</a> </li> <li>
How do i know what script running in element
title say it, long version: my blog using template which contain script for shorting post content (summary), im trying to edit one by one script to increase summary length on my blog but nothing change. I found almost similar script that contain 'summary' on my blog but every time i change the summary var larger than before, nothing change in the page, the summary of my post still too short. so here im wondering is there any way to know what/which script that according from an element of my blog?
Countdown Timer add class at specific time
Hi - i'm currently using a countdown timer plugin (http://hilios.github.io/jQuery.countdown/) and what i want to achieve is a simple class which is added to a div based on how much time is left. if the time left is greater than 10 minutes change div to the color green. if the time left is between 1-10 minutes change div to orange and finally. if the time left is under 1 minute change div to red. I've created a fiddle of how it currently looks https://jsfiddle.net/uokqjn0r/1/ there's 3 class which
Help; .map to call array and .replace issue (auto tag text to url)
The title says it, i got an issue here while im using map of array to replace text to url. 1. The First question is, if the array has same text one of them have a space, e.g. <head> <script> $(document).ready(function () { var p = $("div .post-body"); var arr = ["Bandai Entertainment", "Bandai", "etc... up to 50 or more maybe]; $.map(arr, function (e) { return p.html(p.html().replace(e, '<a href="/search/?q='+e+'">'+e+'</a>')) }); }); </script></head>
Jquery Date calculation not working on clone
Currently working on calculating the expeerience using jquery date picker from date and to date. For example ( if user select the date 01/05/2010 (from) - (To) 31 / 07 / 2013 -- result will be 3years and 3 months ) the result will be shown in label format. Again when the user click add more button one more row will be generated here also the user enter the from date and to date. The resule will be both the two rows ( if user select the date 01/05/2010 (from) - (To) 31 / 07 / 2013 -- result will be
Click botton no response
Hello. I would like to figure out what im doing wrong as i do not get any results when click the button: My script: ************************************************ HTML: <button> procurar</button> <div id="data"></div> ************************************************ JAVASCRIPT $(document).ready(function(){ var url="https://api.instagram.com/v1/tags/trail/media/recent?access_token=2111826929.467ede5.8a3ee686a532449995fc05a8c0b06365&callback=?"; $("button").click(function(){
Simple issue: why has this suddenly stopped working going from 1.10 to 1.11?
I'm not totally new to jQuery, but I'm not an expert, and I don't keep up on all the changes from one version to another. I have one site that was originally designed using jQuery 1.10.2, and a couple pieces of simple, straightforward inline javascript have suddenly stopped working when jQuery was updated to 1.11.3. They are these: onclick="$('#login').slideDown('fast'); return false;" and onclick="$('#bannerBar').fadeOut('fast'); return false;" I imagine it must be something as simple as a change
JQuery UI Tabs
Hello everyone, I'm new to this and I love the product!! I just added the Tabs plugin to my asp.net app. Simple, working well,. However I got a requirement that from C# code behind I need to set an active tab based on a boatload of logical events thru the app Example: My control has 3 tabs C# code: tab3.selected = true /// this is just to help you understand my issue. I've tried some JavaScript / JQuery methods, no luck. anyone have any methods / tricks to do this? Thanks in advance
jQuery Dropdown select
hi, first of all i'm new to this forum and thats my first post so please tell me if there are other information you need to help me here. In my recent project i'm trying to use this plugin to improve the look of my select box. But when i'm calling the function to start the plugin I can't get the .change() of the select box. Here's my code: $(function(){ $('#cd-dropdown').on('change', function() { alert( this.value ); }); $( '#cd-dropdown' ).dropdown(); });
Creating Draggable and Droppable App
Hi all I am trying to create an app where users can drag and drop icons on to a design surface to create objects on a web page. The following are what I have attempted and the problems I am facing: - I have a list of icons at the top of my page in a panel called Tools where each icon represents a function. This panel will not be apart of the web page when it is published. - Each icon when dragged and dropped on to the design surface, will create an HTML element. I have been able to drag
jQuery UI Tabs - SharePoint 2007 Page Viewer Web Part
Hi Guys I've created a simple html page using jQuery UI Tabs which works perfectly on it's own using IE8. The problem is that when I add the page on SharePoint using a Page Viewer Web Part, the tabs don't work on IE8. They do however work using Chrome. Any ideas?
Best way to implement questionnaire with radio buttons
I have to implement a questionnaire with 9 rows and 7 columns. Each field should contain 5 radio buttons (see picture). What is the best way to implement this, so that the form has enough space and is clear when shown on (small) mobile devices?
Date picker placement issue in mobile
Hello, i used multiple date-picker in horizontal line same page. when i click date icon but different place open date picker popup calendar is different place.
jQuery If Statement and get time
Hi i am using a script which is a countdown timer - how in jQuery do i watch the countdown timer and check whether is over, in between or under a certain amount of milliseconds? Based on the documentation and the author (the author wasn't very helpfull and refuses to help). i have came up with this. what i want to achieve is a simple class which is added to a div based on how much time is left. if the time left is greater than 10 minutes change div to the color green. if the time left is between
datepicker field not working on jquery clone
I am working on jquery datepicker Where when the user click add new more button With the help of clone my entire div was duplicating so when i click date field I am not getting the datepicker in the duplicate row.I have search in stack overflow some of the link which i tired for example remove hassclass in datepicker but still not working kindly guide me. Here is my jquery code var i=1; $(document).on("click", ".edu_add_button", function () { var i=$('.cloned-row1').length; $(".cloned-row1:last").clone().insertAfter(".cloned-row1:last").attr({
Create html tag
Hi, I need your helphow to dynamically create an anchor/href in jquery. I use a jquery dialog and I would like to create an anchor when I click on button. Thanks in advance. Tegatti
CDN from code.jquery.com vs ajax.googleapis.com
Recently I had a web app stop working because of a problem loading the jquery mobile (and jquery) libraries from code.jquery.com but only in chrome and firefox (but not safari which loaded fine)... I switched to ajax.googleapis.com and everything is back to being AOK. I clearly don't quite understand what is going on.... can someone enlighten me? Sorry if this is the wrong forum...
Can't sign in to Facebook using code and IE11
Hi, It might be the wrong forum for this question but since I don't find a solution I will ask anyway. I sign in to Facebook using the following code - FB.login(function (response) { console.log('Welcome! Fetching your information.... '); if (response.authResponse) { FB.api('/me', function (response) { console.log('Good to see you, ' + response.name + '.'); }); } else { console.log('User cancelled login or did not fully authorize.'); } }, { scope: 'email, public_profile' }); When I use this code
jQuery Datepicker range
I am creating a small booking system and I need a datepicker range plugin. Do you guys know if there is a plugin that lets you have multiple date ranges and disable all other dates that is not in the specified ranges? For example a user should be able to select a range: From: 1/5/2015 to 10/5/2015 and a range from 20/5/2015 to 25/5/2015. All other dates out of those ranges should be inactive :) I am getting the dates from a database, so i can't specify them manually :) Regards Simon
How to use: beforeunload but NOT for button: id="btnSave" and..
really work fine: $(window).bind('beforeunload', function() { return 'Really want leave the page?' ; }); but i have a button with id btnSave when user press this button i want not display the message 'Really want leave the page?' And how to Personalize the messages(translate to Spanish) thanks
exit button
i'm making an android app using html/jQuery/jQuerymobile and phonegap. and now i want to add a exit button on my app's home page.i tried diffrent codes but it does'nt work. what should i do now? what's your advice?
Sortable: dragged and dropped items refresh positions only
Hi! My problem is in attached files. There are 2 versions of example "Sorting": Flash(swf) and jQuery Sortable(html). I need that jQuery Sortable algorithm works like to Flash(swf) - dragged and dropped item positions refresh only, other items stay in their placeholders (without shifting). Help me please. Yuri http://filetonet.com/AAB3261d5fdacfe74d18927de7249fe2cbb
jQuery fade between images.
I'm a student learning javascript and jQuery. I have a javascript gallery that is fully functional, but am required to put a jQuery fade inbetween the images as they flick through. I can not figure out how to select my javascript images through jquery. Any help would be appreciated. this is my java script var images = $([]); var x = $(0); //reference to pictures, that i want to show and giving them an order number images[0] = "images/1.jpg"; images[1] = "images/2.jpg"; images[2] = "images/3.jpg";
Can jQuery simulate a keyup event that will trigger keyup eventlisteners?
Hey everyone. I'm writing a Chrome Extension that will work with a particular website. On that website, there is a function listening for keyup events in a specific input field and I need to trigger that function and give it a specific keyup event. In other word, when you're actually typing in the input field, a function is called after you release each key with the information of the key that was pressed. Unfortunately, I've had no luck with jQuery's trigger function. Here's a bit of my code: function
Function to imitate JS callback window.onBeforeUnload
I have a script on my site that will set the window.onbeforeunload whenever an input is changed, and when the form is submitted, disable the alert, and submit the form. Current JS: // If any inputs are changed, enable the alert if they change pages (Unless its a .trivial form) // Wait til the page is fully loaded to do so, since some inputs are changed via JS $(window ).load(function(){ $('form:not(.trivial)').find( 'input, :checkbox, :radio, textarea' ).change( function (){ template.nav_alert(true);
jquery.duplicate.js plugin problem, please somene help me
pluging link: jquery duplicate Plugin I am trying to use this but the form gets submitted every time when I click on one of the buttons. what shoud i do now. plugin code: /** https://github.com/ReallyGood/jQuery.duplicate */ $.duplicate = function(){ var body = $('body'); body.off('duplicate'); var templates = {}; var settings = {}; var init = function(){ $('[data-duplicate]').each(function(){ var name = $(this).data('duplicate'); var template = $('<div>').html(
jquery to add tr & td to table is not working.
Hello, I'm trying to add tr & td elements to my table which isn't working. am I missing something here ? Thank you. <table id="my_tbl"> <tr id="row1"> <td id="chart0"></td> <td id="chart1"></td> </tr> <tr> <td id="chart2"></td> <td id="chart3"></td> </tr> </table> $('#my_tbl tr:last').after('<tr><td> </td><td> </td></tr>');
How can i check that it is the last record in database table?
<script type=text/javascript src="jquery-1.11.3.js"></script> <input type="button" id="id_load_more" name="nm_load_more" value="Load More" /> <script type="text/javascript"> $(document).ready(function() { var limit = 1; console.log("ready!"); $( "input#id_load_more" ).on( "click", function( event ) { //event.stopPropagation(); $.ajax({ method: "POST", url: "load_more.php", data: {"page":
What does ' + next + ' do??
I have come across the following functions that use the scrollTo plugin to move to a random image but don't understand the part of the line: .scrollTo('#pic_scroller>img:eq(' + next + ')', {duration: 1000}); that I have highlighted. - the ' + next + ' part. The full function is below. Can do a full jsfiddle if really necessary but hoping someone will know what the parameter is doing without needing to do that. $(document).ready(function(){ $('#pic_container').click(function(){ var numberOfPics
Next Page