Store settings (selected index) in a text file
I have a web project in Visual Studio and I have had some problems with page postback when it comes to my drop down list, so using JQuery instead and the select change function is a smoother solution. Now I don't just want to play around with the drop down list, but I need to be able to store the selected index as well. So I have a save button and whatever option the user selects, I need to store in a text file. The point is that the next time the page is loaded I need to load the text file and retrieve the
Not sure how to make use of cache?
if (!sessionStorage.getItem('GotTags')) { $.ajax({ url: "Search/GetTags", method: "GET", datatype: "json", success: function (data) { sessionStorage.setItem("tags", JSON.stringify(data.songTags.concat(data.albumTags, data.artistTags))); sessionStorage.setItem('GotTags', 'true'); } }); } $("#searchString").autocomplete({ source: function (request, response) { var
fotorama resize issue
I've set up a responsive Fotorama page with several different Fotorama divs. Idealy i would like the Fotorama pane to display a different size for iPads portrait / landscape modes and for desktop I'd like it to scale according to the users browser window size. Using the responsive data-width, data-height styles as shown below works more or less perfectly: <div id="fotos1" class="fotorama" data-width="100%" data-ratio="1000/640"> <img src="img/sA1a.jpg"> <img src="img/sA1b.jpg"> <img src="img/sA1c.jpg">
preload
I've been experimenting with several preloads found in this forum and am not sure which is most effective. I've been testing with: $.fn.preload = function() { this.each(function(){ $('<img/>')[0].src = this; }); } then: $(["images/IMG_00000.jpg", "images/hip1_00001.png", "images/hip1_00002.png",...etc.... ']).preload(); You will notice my images are in folder called 'images'. Totally naive question, but does the preload function code above $('<img/>') refer to a folder called 'img' or does
No records displaying with JQuery & HTML output question
I am having issues with my code. Index.html < !DOCTYPE html > < html lang = "en" > < head > < script type = 'text/javascript' src = 'http://ajax.googleapis.com/ajax/libs/jquery/1.6.1/jquery.min.js' ></ script > </head> <body> <!-- Side Menu --!> < ul id = "sidemenu" class = "acc-menu" ></ ul > <!-- Show Categories --> < script type = 'text/javascript' > $ ( document ) .ready ( function (){ /* call the php that has the php array which is json_encoded */ $.getJSON
When is a .data content released (its lifespan)?
When is a .data content released (its lifespan)? Is it when the HTML disappears from the DOM?
Create a compressed file of multiple files
Hi All I am working in the SharePoint task and created a table which will show all the task items and having an Attachment column which will show the attachments related to the task item.If i click the attchment icon it will download the file.. But if in case that task item contains multiple attachment i want to download it as zip file. JsZip example showing about creating a file and zipping it. var zip = new JSZip(); zip.file("Hello.txt", "Hello World\n"); var img = zip.folder("images"); img.file("smile.gif",
Why does this not convert inputted vals to floats?
I had this code, which added inputted vals and put them in a "totals" box: 'change .payments': function(event) { var paymentTot = $('#paymenttotal').val(); paymentTot = parseInt(paymentTot) || 0; var targetVal = $(event.target).val(); targetVal = parseInt(targetVal); paymentTot = paymentTot + targetVal; $('#paymenttotal').val(paymentTot); }, ...but then I realized I wanted "dollar amounts" and interspersed what I hoped would convert the vals to floats (I naively
Time is not set and displays computer time
<html> <head> <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.11.3/jquery.min.js"></script> <script> var ser_hours, ser_minutes, ser_seconds; var ser_date = new Date(); function updateClock ( ) { //var currentTime = new Date ( ); var currentHours = ser_date.getHours ( ); var currentMinutes = ser_date.getMinutes ( ); var currentSeconds = ser_date.getSeconds ( ); // Pad the minutes and seconds with leading zeros, if required currentMinutes = ( currentMinutes < 10 ? "0" : ""
Howto - run "c" executable from html page using jquery
I want to access a "c" executable from my html page. ie: I want to call "helloworld" through a "javascript" function such as: ....... <head> <script type="text/javascript"> function runHelloWorld() { CODE TO CALL => /$PATH/helloworld } </script> </head> <body> <a href="javascript:runHelloWorld()">Run Hello World </a> </body ....... I have seen discussions re: "network.protocol-handler.app" but all the talk and examples are regarding "Windows" with
firing document ready of second loaded page
hi, i have 2 aspx pages, from one i load the second with $('#mydiv').load('Resultats.aspx', function () { // some code }); the resultats.aspx page have a jquery document.ready function code but the problem that it is not fired . how to fire the document.ready code of the loaded page please ?
I am trying to get my jQuery functions to work on IE8.
I am trying to get my jQuery functions to work on IE8. I am loading the library from google's servers (http://ajax.googleapis.com/ajax/libs/jquery/1.3/jquery.min.js ). The $(function(){}) is never called. Instead, I get an error "Object expected". I opened the developer and ran "typeof $" in the console, and it came up as "undefined". I have tried going to other sites that I know use jQuery (jquery.com), and those all work, is there something I might be missing here? Thanks Tauqeer
scrollTop: $(window.location.hash).offset().top scrolling to the end of the element?
Hi jQuery forum, im pretty new to jQuery and usually just doing PHP/HTML/CSS things. I´ve googled and tried this many many hours in the last 2 days but i cant get it working. What i want to do: SmoothScrolling on same-page-links (working) and SmoothScrolling on new-page-links ("half-working"). My Code for same-page-links: $(document).ready(function() { $('a[href*=#]').click(function() { if (location.pathname.replace(/^\//,'') == this.pathname.replace(/^\//,'') &&location.hostname
jquery calculations
i have almost done my work but there is problem in calculation i want to write expanse value that will be add to current bill and show in total bill section i dont know how to do that here is my code.i have attached the picture of output. <!doctype html> <html> <head> <meta charset="utf-8"> <title>Untitled Document</title> <script type="text/javascript" src="jquery_1.9.1.min.js"></script> <script> $(document).ready(function(){ $('.inv-detail').delegate('.qty,.price','keyup',function(){ var tr=$(this).parent().parent();
Anybody uses Docker here ?
Hello guys, anybody here who uses DOCKER ? . off topic i know , but just had to ask :) just had a few basic questions , nothing much .
Inconveniente con ".val()" en una sentencia FOR
Hola gente linda. Mi problema es que no puedo extraer el valor (.val) en un bucle For, sin embargo extrae el primer valor cuando se escribe en un campo de texto de la lista del carro de compras. Aquí los códigos: js: $(document).ready(function () { $('#cant_prod').keyup(function () { var cantProd = $(this).closest('.prueba2').find('#cant_prod').val();//Extraemos la cantidad tipeada var numCantProd = parseInt(cantProd);//Convertimos la variable en entero alert(numCantProd);
div play button onclick not working with ajax super filter
Hi Guys, Need your support! I have one problem with my play button which works fine until i use super filter (Ajax content) to refine the list of products. Button style shows fine but when i press it nothing happens, which should call and send a mp3 link, name and thumb for my music player (jquery) to read, which is sticked on the bottom of the page. 1.This is how it looks like HTML:(code generates multiple products on one page depends on how many products) <div class="audioplayer-song-changer" data-target="#ap1"
[jQuery] Don't add ".html" in URL - Please help!!
Hello everybody! Up front, I excuse me for my bad English! I develop a website and found this fancy animated sidebar-menu: Codyhouse Furthermore, I specialized on PHP and MySQL, so actually I'm not able to develop jQuery! But I have a problem! I have the menu like this: <nav class="cd-side-navigation"> <ul> <li> <a href="#0" class="selected" data-menu="/index.php?site=0"> <svg class="nc-icon outline"><!--SVG ICON STUFF--></svg> Home </a> </li> <--! More entries... --> So in the end,
Rework image slider
Hello, i found a simple slideshow scipt on this page, wich works nice for me. The only problem is, i can´t add descriptions/caption for pictures. This way i need help for a rework. The creater has written in the comments the easiest way should be to use a div for each image and a span with text in it. I tried and changed in the Jquery the img tags with div tags, but i dont get it to run (im a beginner :(). I added the Code on JSFiddle Click. And here the updated Code i tried, but the images are´nt
How to upload images also change whole div
Hello guys, i need to create upload images look like above, my script is here http://codepen.io/sidaurukfreddy/pen/rOVYMv , my question is Is the CSS script avaiable can be like that How to make when images is uploading not more than div Thanks for respond
Found find flaw
I use jQuery a lot, especially the find method which is why this little quirk threw me. I've thought of find to be an extension to a selector string. It allows some use of arbitrary methods after the selector string and then continues to find even more. But using it with a finite selector (:first, :last, :eq, etc) causes it to search within each element. This isn't a problem for classes or elements within the selection, as find will return any number of those. But using it to retrieve the first element
Showing json data from wcf service
Hello, first timer here, and I really hope and pray you can help me, as I have had not much luck trying to figure things out on my own. I am trying to create an app using Devextreme My code looks like the following - db.js (function () { var dbImpl = { url: 'http://localhost/service/GetCustomers';, _sendRequest: function (type, params) { var deferred = new $.Deferred(); var requestSettings = { url: $.trim(dbImpl.url), type: type,
Chrome crushed when I code like this 'jQuery(jQuery).append(5)' or "jQuery('2').appendTo(jQuery)"
Tested with version 1.9 and 1.11. Is it a bug? I do not know it until our student tell us!
Looking for pluging for sype like effect.
http://www.shyp.com/ Please scroll through these website and you will see that the background image scrolls normally, while the screen shot changes in the phone to it place how I can do it please suggest. Do we have any plugin for that in Jquery. Other URLs http://yougotthenod.com/ http://www.aims-app.com/ http://kimd.cc/ http://beardswipe.me/ http://www.pomodrone.com/ http://mymail.my.com/ Thank you.
How to change style of a included html file inside <object> tag ?
I want to change the style of a html file I get from the web when including it inside <Object> tag. My purpose is to hange the display of web page such as https://clients3.google.com/cast/chromecast/home to make it full screen and discard the dark veil, so on .... Then my file could be : <html> <body> <object id="file" data="https://clients3.google.com/cast/chromecast/home" type="text/html" style="width: 100%; height: 100%"> </body> </html> How can I get inside the code to restyle the page as I want
Error in changing background color of cell in html
Hi All, In my application there is an html table this is the code for my requirement <script type="text/javascript" language="javascript"> $(document).ready(function() { $('body').on('click', '.anchor3', function() { $("a.anchor3:contains('B')").each(function() { var pcolor = $(this).parent().css("background-color"); if(pcolor != "rgb(218, 112, 214)") { $(this).parent().css("background-color", "red"); } else {
what is selector ?
Hello guys , was just going through the source on fancyinput.js and came across the following line (see it on git HERE. ) var selector = inputs.selector; so if i console.log selector , i get the selector i initially used to initilize the plugin , i.e. "div :input" is inputs.selector a Javascript method/property or a jQuery method/property ?
ReAdding Event Handler After Dynamically Removing and ReAdding Element
Hello everyone, I think the title should be pretty clear in terms of describing the issue. Basically, I'm trying to create a reset() method where I can remove then immediate readd the element and it's event handler. Right now, it removes the element (which is initially built into the HTML) and readds the element. So that works, but the original events that were tied to that element are not added. Any idea as to why? Any help is appreciated. Here is the code I have: function resetAllOverlays()
ajax call to php with redirect
Hi I am creating a site where make a ajax call to php that saves my data to mysql then uses some api to paypal and then redirects to paypal to make the payment. when I built my test php and referenced direct all works great. Now I am using ajax to post the data to the file I get a 302 header response and the redirect doesn't happen. I believe this is down to how ajax is behaving but no idea what, is there away I can make this work? here is my ajax call and response fromm php. $.ajax( {
Desperately need help with jQuery
Hello all. I am in way over my head with this and I would love some help. I program PHP, MySQL, HTML and others, but I never could get down jQuery and javascript. Anyways, I am working on a navigation menu and on mouseover the menu comes out, however, when I go to next area where the menu pops out to a sub, it goes over the other one and so on! Here is what I have: $(function(x){ $('a.link-sub').mouseover(function(e) { // Add active class to section title $(this).addClass('active');
Animation: Function Inside "Done" Still Executes
Hello community, I am having an issue trying to stop a function from executing in the done property when using jquery animate method. Basically the first part of the animation is a color overlay when the user mouses over the element. Once that color overlay completes, then some text is suppose to appear (which is a css text animation itself) . But if the user hovers over the element and quickly mouses out, then the text shouldn't appear but it still is. Here is my code. $(".grid1, .grid2,
JQuery add Tab Index to Accordion
Good Morning, I need to add this jQuery in order to Keyboard Tab through my Accordion list but I am not sure where in my file to add it. Attached is the file in question. $(‘#uniqueid of the element”).attr(‘tabIndex’,’0’); Thanks for your help!
Megawhite- I want to learn and use jqurey for my college project.
Hi Guys, I know some sort of programming languages and now wanted to learn Jquery. Can you guys suggest me some resources or the online links from where I can learn jquery. I am waiting for your suggestions. Thanks -Bryan
understanding a LTR function regex
Hey guys , have a look at the function HERE . I believe its to detect weather a character is left to right(LTR) or right to left (RTL). var ltrChars = 'A-Za-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02B8\u0300-\u0590\u0800-\u1FFF'+'\u2C00-\uFB1C\uFDFE-\uFE6F\uFEFD-\uFFFF', rtlChars = '\u0591-\u07FF\uFB1D-\uFDFD\uFE70-\uFEFC', rtlDirCheck = new RegExp('^[^'+ltrChars+']*['+rtlChars+']'); I am still confused whats the real purpose of this function , the other question
Howto call events after loading new html-elements by Ajax? | .live("load") .load() .on("load") ??
I have a page with dropdowns of class "chooseObjectType " which is part of a set of form-elements. There is also a button which loads more of those form sets. On my dropdown, live("change") calls the correct event and gives me "Test 0 ". By clicking on the button which loads more of those dropdowns (.chooseObjectType), it does not call the onchange event as expected, so I wanted to use an "onload" event. Deseperately none of those Test1..3 works :( $(function(){ $(".chooseObjectType").live("load",
Convert a form script from jquery 1.4 to 1.5
I would like to convert a script I found ... But I can not. It works with Jquery 1.5. But it no longer works with Jquery 1.6. Yet I tried jquery -migrate ( Migrate older jQuery code to jQuery 1.9+ ) . But without result ... The script : $.post('', form.serialize(), function(msg) { submitFlag = false; overlay.hide(); $('span.errorIcon').remove(); if (msg.success) { $('#formContainer, #mdiv, #contactboxfloat').fadeOut(function() { form.get(0).reset();
Error in odata ajax call
I have an $.ajax call in one of my html page: var query = ODATA QUERY jQuery.ajax({ dataType: 'jsonp', url: query, jsonpCallback: 'callback', success: callback, ajaxError : errore }); function callback(result) { } function errore() {console.log("errore"); } but if the query fails i get an errore in console (NetworkError: 400 Bad Request) but does not enter in the error function. Why?
Jquery ajax call in function return value is #document with result
I need to remove #document tag from this resiult
Jquery min without vulnerabilities
I need to know wich is the latest version of jquery min without vulnerabilities for upload to the latest version. I have this versions: 1.4.4.min.js 1.3.2.min.js 1.4.2.min.js 1.7.1.min.js Please. THANKS!!!!!!!!!!!!!!
jquery commas
hi i have numeric values in textbox like 1000 but i want to write it in currency format like 1,000 please help me out
Next Page