redirect dynamic to parent site
Hi I wanted to create a link that is dynmaic in my site. The name could be 'Go Back', but it should not use go back history, I want the link to get up one level strict according to the nuber of slashes in the URL, e.g. in the structure of sites and pages I got, For example: If the I click such link on this page: https://forum.jquery.com/using-jquery/newtopic (I should be redirected to.. ) https://forum.jquery.com/using-jquery Or.. If I'm at this level.. https://forum.jquery.com/using-jquer (I should
Flexslider not rotating
My Flexslider is not rotating when the browser is not on focus. If the browser is on focus, then the flexslider works fine. However, if i open up a notepad on top of the browser, then the flexslider is no longer rotating. How can i make the flexslider to continue rotate even though the browser is not on focus? My code used is as below. $('#home-flexslider .flexslider').flexslider({ animation: "fade", slideshow: true, pauseOnHover: true, smoothHeight: false, start: function (slider) { slider.removeClass('loading');
Bug in QJueryUI TAB widget
Hi all, I just found out a bug in JQuery TAB widget. The bug occurs when you invoke the page which contains the widget with a different URL. For Example: OK: http://localhost/page_with_tab_widget.html NOK: http://myseleniumuser:password@localhost/page_with_tab_widget.html Both URL are actually the same, the first URL is normally used by human beings, because the browser knows automatically when basic-auth is required, shows a dialog, and then continues with the basic-auth header. But when you want
Simultaneous action
Hello, How to make that all happened together? $('div').animate({
backgroundColor:'black'
});
$('div').slideUp();
FullCalender plugin length description error.
Hey guys, I have problem with FullCalender plugin. My description is too long,thus plugin is not working? How can I solve this problem ?
How to combine 'document' and a class selector?
The manual describes the use of "Multiple Selectors" here: https://api.jquery.com/multiple-selector/ It says that one can simply combine them like this "sel1, sel2, ...". But if one of the selectors happens to be document (no quotes), then this combining doesn't work. Consider the following code which works perfectly fine: $(document).bind('keydown', 'f1', function() { $('#help_button').trigger("click"); return false; }); $('.entry_fields').bind('keydown', 'f1', function() { $('#help_button').trigger("click");
Selection of div with title
I've got a div with a complex title <div title=" 00:00 - 23:55 [Holiday] and some more text">...</div> which I need to filter on the keyword e.g. [Holiday] or just Holiday and set a css property. This dosn't filter the right div: $("div[title$='\\[Holiday\\]']").css('background-color','red'); Any idea?
Sorting items in a list - in need of help.
I have a list that this time has seven rows. On some you will see "EXC" next to them (see fiddle). What I would like to do is sort these so from the bottom they fill the required rows - in this case it would be the last three - but depending on the settings it could be more or it could be less. https://jsfiddle.net/a4poster/ysyxvtyp/322/ Thanks in advance.
swipe gestures, compatibility
Hi i'm using jquery v1.11.1. Now I'd like to enable swipe-gestures. Is it correct that - swipe gestures are only supported in jquery mobile? - only version 1 of jquery supports IE6 to IE8? I tried implementing jquery mobile (latest stable version), but I experienced problems like huge breaks in the page, a "loading" bar on bottom of the page and when I used links, the page to follow was loaded below the current site. So I guess there are compatibility issues with v1.11.1 and jquery mobile. Is this
Passing php to jquery
I have a PHP variable called $successSent I have this bit of jquery $(document).ready(function(){ var success = '<?php echo $successSent; ?>'; alert(success); }); But alert(success); says <?php echo $successSent; ?> not the value of $successSent. I though you could pass PHP to query that way? What am I doing wrong? Thanks
Using jQuery to force div to reload
Good day all, Currently, I am working on a project where you arrive on a page that has a list of Annual Reports. The user has an option to add to this list. If they click the Add Annual Report(s) button, a modal window will appear. Within it, you pick a status of the Annual Report (only two statuses: Projected and Actual). 1.) Projected: picking this status causes another div to be set to show(), which contains a date picker for a Start Date, and a dropdownlist for End Year. 2.) Actual: picking
JQuery progress bar or box waiting for user input
Hi All,I am trying to show a progress bar that really emulates close to the shake methodology. I want to display a progress bar that continually moves to the left and then slides to the right. Image attached. Does anybody have any suggestions? Thanks, Tom
Convert syntax .live() to .on()
I have been given a web site by our organization to maintain that uses jQuery 1.7.2 and would like to remove a deprecated function .live() so I can move forward with later versions of jQuery. I have searched the web for changes to the syntax and thought I had figured out the changes I needed(that worked elsewhere) until I came to this line of code. This code is part of a form where input is verified before moving to submission of the form to PayPal. The characters in red have a VS 2013 warning "Variable
$(":mobile-pagecontainer").pagecontainer() not working as expected
HI I have an HTML page with two JQM pages <div data-role="page" id="page1"> . . . </div> ...and <div data- role="page"id="page2"> . . .</div> From "page1" I have an <a> link to page 2 and it works fine href="#page2" I also have a <button> with a onclick() function which calls the pagecontainer change method, page 2 shows briefly then page1 returns Why does page 2 show permanently ? Any help would be useful Thanks Nigel
Check if user selected Time has expired
Hi, I want to check if date is today, then user should not be able to pick expired time. However, if the date selected is tomorrow, then any time can be selected. I am trying to do a check in jquery, but not sure how to check. The date is in the format of "MM/DD/YYYY", and the time is in format of "hh:mm a". Expired time of 5 minutes is allowed Below is the code which I have tried: var targetTime = new Date().setMinutes(-5).valueOf(); var today = new Date(); var dd = today.getDate(); var mm = today.getMonth()
Start a function delayed after in "ready(function.."
hello, I successfully made a slideout menu. working fine if somebody clicks on the menubutton. $(document).ready(function () { $('#displaymenu').click(function () { $('#showmenu').toggle('slow'); }); }); but now I want it to slide out automatically after 30 seconds IF the menubutton wasn't pressed before. I want to show that there is a menu for people who don't know where to click. This menu should then automatically close after 5 seconds. But I don't really know which function could
Uncaught ReferenceError: jquery is not defined at index:19
<!DOCTYPE html> <html lang="en"> <head> <meta http-equiv="X-UA-Compatible" content="IE=edge"> <meta charset="utf-8"> <meta name="viewport" content="width=device-width, initial-scale=1" /> <meta name="description" content="Neon Admin Panel" /> <meta name="author" content="" /> <link rel="icon" href="<?php echo base_url();?>assets2/images/favicon.ico"> <title> ADMIN </title> <script type="text/javascript"> var $ = jquery.noConflict(); //line 19 $(document).ready(function() { $('.fancybox').fancybox();
MouseMove Drag con coordinate del livello e.pageX, e.pageY
Buongiorno Ho questo codice js, vorrei mostrare le coordinate X e Y considerando come 0,0 il livello div.contenitore-mappa anziché tutta la finestra. Come posso operare? Grazie $("div.contenitore-mappa").ready(function () { var $dragging = null; $("div.contenitore-mappa").on("mousemove", function (e) { if ($dragging) { $dragging.offset({ top: e.pageY, left: e.pageX
Where is .attr('style') documented?
I've run into a function that uses $(el).attr('style'), that seems to bring back all the styles for $(el): function findStyle(el, attr){ // attr = 'color' var styles, style, color; try { styles = $(el).attr('style'); if (typeof styles !== typeof undefined && styles !== false) { styles.split(";").forEach(function (e) { style = e.split(":"); if ($.trim(style[0]) === attr) { color = $(el).css(attr); } }); } } catch(err) {} return color; } Does anyone know where this is documented? Thanks.
(function($){...})(jQuery)
(function($){ ... })(jQuery) Can someone explain all these wrappers? Is that the same with $(function(){...}) ?
datePicker changeMonth and changeYear selectors need title text (Accessibility)
A compliance checking tool such as Wave http://wave.webaim.org/ reports an error on the month and year selectors, because they have neither label nor title text. The easiest solution would be to add title text, which should of course accommodate localization.
Autocomplete with json call, suggest doesn't work
Hi, I am using jquery ui autocomplete. When use this with a call to json, I can't get that suggest feature works properly. I attach a link with code http://codepen.io/anon/pen/oBMyrO Thanks in advance!
opened slide in panel
Hello guys ive downloaded this http://jquerymobile.com/ I am using this demo http://demos.jquerymobile.com/1.4.2/panel-fixed/ I would like to have the panel first opened and then if someone wants to close it. How can i achieve that? Thank you!
About google map and to show location in map based on latitude and longitude.
Hello Everyone I want to display one particular location in map based on longitude and latitude , And I want to show the direction arrows for the street in which it will automatically when users move here and there. please anyone can help me how to achieve this!!. Can We do it by using jquery? Thanks in advance
Variable Scope in document.ready() function
Dear Friends, I following codes where I have setup a global variable but its value is not getting updated within the flow. Code is below. Please guide me to find a solution: var flgBtnBold; $(document).ready(function() { flgBtnBold=0; $('#btnBold').click(function() { if(flgBtnBold==1) { alert('within if block when true'); $(this).css("color","#000"); flgBtnBold=0; alert(flgBtnBold); } else { alert('within if block when false'); $(this).css("color","#f00"); flgBtnBold=1; alert(flgBtnBold); // It is
How to assign values to dynamically generated hidden item
I have a modal dialog where table rows are generated dynamically on button click. First column is an autocomplete text box .when user select an item this value must be assigned to the hidden element. The problem is multiple row will have multiple columns. I dont know how to sync with each element which is created on every button click and assign the selected value to hidden item every time Following is the code of autocomplete box $('body').on('focus', "#dataTable #pname", function (e) {
Upgrading code from jQuery UI 1.7 to 1.8 failing
I have some old jquery (UI) code that I want to upgrade to todays standards. Since my code was written for jQuery UI 1.7.3 I've decided to upgrade the code release by release. A release list is found here: https://jqueryui.com/upgrade-guide/ So if I open 1.8 Upgrade Guide I can see what was changed. So far so good. As far as I can see, the following changes apply to my code: Renamed _init() to _create() Renamed _setData() to _setOption() Removed _getData() since it should never be overridden $.widget()
iterate focus with keyboard arrows on images in different div’s
hi all, i want to be able to move focus on images that has the same class, with the keyboard arrows (in a thumbnail scroller). this is what i have: html: <div class="swiper-wrapper" id="swiper-wrapper" > <div class="swiper-slide" tabindex="0"><img src="cards/jpeg1.jpg" alt="" class="thumb"></div> <div class="swiper-slide" tabindex="-1"><img src="cards/jpeg2.jpg" alt="" class="thumb"></div> </div> jquery: var parent = document.getElementById("swiper-wrapper"); var children = document.getElementById("swiper-wrapper").children;
Drop if content matches
Hey, i am currently working on a jquery math game project where some tasks are in div elements on the rights side and the results are in divs on the left side. The divs with the tasks also contain a hidden div wich contains the result of the task. The users have to drag the result divs on the task divs. My question now is How can i check if the content of the two divs match? I would appreciate any help
disabling controls ?
I have to make a presentation to a group of older folks, and will likely do it as a webpage: it will be displayed via a medium-size tv screen (Sony Bravia). Navigation down through the layers would be by strategically-placed transparent gifs, and colored markers like those on googlemaps. I have this idea that those who want to could bring their iPads, and follow along, if they're in the back row or nearsighted: but wouldn't want them to navigate for themselves. So...would there be a way to disable
Executing two functions in the correct sequence
Hello all, I am a jQuerie newbie. Have spent hours on the net and still unable to fix a problem and now totally confused. I have two jquery functions. Function one has to be executed before function two. When I run the script function two is always executed first. Hope someone is able to assist and wish to thank them in advance. <!DOCTYPE html> <html> <head> <meta charset="UTF-8"> <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.1.1/jquery.min.js"></script> <script> $(document).ready(function(){
Jquery Nestable plugin error with php
Hey guys, I have a problem with Nestable plugin,The first thing I want to say,I know normal jquery sortable plugin but I don't understand Nestable. My Code is apperead in above images; * http://i.hizliresim.com/yNQ2o9.png * http://i.hizliresim.com/6rOYqE.png Now, I want to send output to ajax.php file via post method.How can do it ? What variables should I send ?
Help with saving a JQuery Sortable Grid to a cookie.
I am new to jQuery, and coding in general. I have made a sortable grid that contains images with links that can be rearranged by dragging/dropping them, but i want the user to be able to save the order they have chosen. After refreshing the page the order returns back to normal, so i was wondering how the order could be saved , and retrieved from a cookie. Here's my code so far: <!doctype html> <html lang="en"> <meta charset="utf-8"> <meta name="viewport" content="width=device-width, initial-scale=1">
Am I over complicating my form validation?
I am trying to make my booking form a little more user friendly... I have three sections... First is a first/last name, email and phone number. Second is a calendar to pick your date Finally there is a dropdown select that shows a list of different time slots that are available. It looks like this: I am using tzjs to get the users time zone, and I am using moment.js to compare dates and times. The reason this form is complex is because I am only showing dates and times that are one hour in the future
How to toggle button on click?
Hi everyone! The issue I face is that I have identical "button-checkboxes", but once of of them is clicked, I only want the closest private class to change. <span class="button-checkbox"> <button type="button" onclick="privateClick()" class="btn btn-sm btn-default"> <i class="fa fa-square-o private"></i> <button> <input name="private" type="checkbox" class="hidden" /> </span> <span class="button-checkbox"> <button type="button" onclick="privateClick()"
Add a new method to a jQuery UI widget
The technique described in the docs for extending UI widgets works for me when extending an existing method, but not when trying to add a new one. Rather than repeat the details here, here's my SO question in full: http://stackoverflow.com/questions/42024327/add-a-new-method-to-a-jquery-ui-widget Thanks in advance for any ideas.
Change the content of the scr attribute of the img tag from a variable retrieved from a local file by the jquery load command
Hello, I have a big worry for me but small for you: I want to change the content of the attribute src of the tag img by a variable filter by the command load of jquery. This variable must have the value "node.png" as shown in my work at the attached address: <Div id = "tutu"> </ div> gives me the screen in the div: node.png. It is this value that I want to put in the attribute src of the tag img. Address of my work: http://plnkr.co/edit/pKSd7srxCCYGSRZonlQf Can you help me? Thanks for your help,
CDN page
The copy button doesn't seem to be working in Chrome for the minified 2.2.4 jQuery. Also, PLEASE get rid of the diagonal stripes once copy has been clicked. They provide absolutely no value and are extremely annoying.
How to stop adding the same words, that <element> already has
Well, I start from gathering 7 values from 7 <tr>'s: name 1 name 2 name 3 name 4 name 4 name 5 name 6 var names = $("tbody tr").map(function(ind, obj){ return $(this).children().eq(3).text(); }); But I need to remove duplicates, such as name 4 How can I do that? This code doesn't work for preventing text duplicates: $("span#complex").text( $.map(names, function(obj, ind){ if( $("span#complex").is(":contains(names[ind])") ) return; else return names[ind];
screen.orientation not working
Hi, I am trying to use https://github.com/apache/cordova-plugin-screen-orientation in my app but it's not working and no error.. I tried: screen.orientation.unlock(); screen.orientation.lock('landscape'); but: alert("Orientation type is " + screen.orientation.type); is working and showing the orientation type so it's installed succesfully but then why it's not changing the orientation of the device? Thanks, Jassim
Next Page