I'm developing a Rails app and I've run into an issue that I can't seem to figure out.
I'm using the jQueryUI Accordion and I'm building the requisite structure by looping through an array I've got.
The HTML structure that the accordion needs is the following:
<div id="accordion">
<h3><a href="#">First header</a></h3>
<div>Fi...
when i set a custom yearRange for my datepicker (ie. +- 100 years), during the focusin event on the datepicker input field, a page flicker occurs. also, when changing the month/year inside the datepicker gui, the datepicker flickers.
i think it is because more than +-20 years in the datepicker yearRange is maybe too much DOM for the dat...
I have a main page with a js variable. I want to open a modal on that main page and load html content from a different page. I need to pass that variable to the modal that is opening and use it inside the loaded html content.
I have seen several questions similar to that in these forums but i don't see any that explain how I can tease t...
I am trying to use the jQuery plugin Img Notes (here), and I'm a little confused as to how to add notes. I don't know much about PHP and there is very little documentation on the plugin site itself. I want to be able to add notes to an image and have them show up on the image after submitting the form, preferably without going to a diffe...
I have two input fields. I want to force the focus on #area no matter where the user clicks unless it is on #input. I've tried something like this, but since input is part of document, it does not work.
$("#area").focus();
$(document).click(function() { $("#area").focus() };
$("#input").click(function() { $("#input").focus() };
Though...
I use the jQuery UI accordion widget, and between every item I have some space. The issue is that in IE 8 , when you slide an item, it slides fine, but it removes the space between it and the upward item. It works good in FF and other browsers, though.
When I over with the mouse on that item, though, it creates that space.
I use the H...
Original Question
I need to do a getJSON() request, but how do i pass authorisation and custom headers?
New Question
I am getting issues that by using your example that the request header are taking the name, but NOT the values and that the URL is being shown through a manual request in fiddler to being inserted in as options instead ...
Ok, so I wrote this function to be a change event applied to a checkbox. Now it is apparent I need to use it as a custom validator method, so it runs when you hit "Next" to step through the form. I have all that working, I just can't get the syntax of the rule right.
Here it is as a change event:
$('#MKDPT').change(function() {
if ($(...
Note: This relates to a previous question.
I have a Wicket page that has a form with some complex client-side interactions that I decided to use jQuery for instead of Wicket (long discussion, I know). Essentially I'm just building a JSON object, submitting it via AJAX, and performing some action on completion. The call works fine in Fir...
hi,
I am using jquery ajaxupload plugin to upload files .I have the following js on my default.aspx page
$(document).ready(function() {
/* Example 1 */
var button = $('#button1'), interval;
new AjaxUpload(button, {
action: 'upload.aspx',
name: 'myfile',
responseType:'json',
...
how can you get a GET variable with javascript?
i get it in php from the query string:
$idmessage = $_GET['id'];
then need to send it in $.ajax() jquery, how can i do this?
regards
...
Hi all,
I am trying to grab the ID of a DIV class referenced by its Class name using JQuery, but failed to do it.
$(".myClass").click(function(e){
alert($(this).id);
}
<DIV id="myTest1" class="myClass">
Helloworld I am new to JQuery 1
</DIV>
<DIV id="myTest2" class="myClass">
Helloworld I am new to JQuery 2
</DIV>
Could ...
The main goal of this code is to run throw all img tags and load the image to the client cache. During this, I've got and image that will appear by hiding div's above it...
Now, This are the answers I'm looking for:
Is this really caching the images ?
How to simulate the current animation with a less evasive code ?
Can this code be r...
Hi all,
I am using jQuery to grab the ID of a DIV Tag and then add some CSS style to the DIV
accordingly.
I am new to jQuery, and I am not sure if this is a good way to do it:
JavaScript:
$(".myClass").click(function(e){
var whatid = $(this).attr('id');
var whichDiv = "divName"+whatid;
("$(\"#"+whichDiv+"\")").addClass();
...
I've got a photo slideshow with thumbnails. Next/Previous buttons appear and disappear based on the size of the window; if the thumbnails overflow the window size, the buttons appear. If not, they disappear. My problem is that, at times, they won't come up, or they won't come up for a couple of seconds. At other times they won't disa...
Hi people,
How can you use JQuery to find URLs within some text and automatically convert them into an actual hyperlink?
Example text,
var TextMemo = "This is some random
paragraph text, but i mention a link to a
website here. www.stackoverflow.com
and another one here this time with
http (http://www.google.co.uk)"
Is th...
I'm having trouble with jQuery not recognising elements on my page and throwing an error saying the elements I'm trying to select are null.
We are inserting our content into the following wrapper, which is supplied by the client:
http://www.ft.com/global/mm0802/ag/wrapper
The wrapper contains the following string:
<!-- ftplchol id="c...
In the code below, I tried iterating over the JSON object string. However, I do not get the desired output. My output on the webpage looks something like:-
+item.temperature++item.temperature++item.temperature++item.temperature+
The alert that outputs the temperature works well. The part where I try accessing the value by iterating thr...
Hi,
I did be glad if someone could help me solve this
I have a user sign up page with username and password choice fields, I'm providing validation and availability asynchronously using event listeners,
//username
$("#username" ).bind('blur',function(e){
//ajax call
if (e.target == e.currentTarget) {
e.stopPropagation(); ...
I realized that on a webpage, when a form's UI (checkbox, dropdown list, etc) is changed programmatically, the event handler (onchanged) is not fired? Is this a standard rule -- that when a control is changed programmatically, the event handler will never get triggered? Is there any exception?
...