jquery

jQuery addition of multiple text box values

Hi all, I have a new task to do and im not sure the best way to approach it with jQuery. Basically a client wants 'x' amount of text boxes (for quantity) each with a plus/minus button/icon to the side of it and as you click on each one, all the relative fields update. e.g. (if there were 3 options in a page) qty [ 0 ] + - qty [ 0 ] +...

Jquery - How do I start a function when div content is changed

Hi, I searched for a solution like: if( content from $('#div') is change -> start function test(); ) I change the content with $('#div').html('blub'); Thanks in advance! Peter PS: I know, it is possible with setTimeout, but this is a really dirty solution :/ ...

non Gregorian calendars with jquery fullcalendar

Hi all, Does anyone know how can one add a non Gregorian calendar support to jquery fullcalendar i don't know where to start the customization and what exact classes and scripts are affected by such a feature... i have implemented conversion script in js. I think that there isn't any built-in support. I'm looking for solution so that...

Spring Webflow and JQuery

Hi Everyone, I am now working in a Spring project using the Spring webflow. The JavaScript library I would like to use JQuery. How to integrate JQuery project in Spring and Spring webflow? Thanks in advance ...

CakePHP cancel redirect to view after submitting ajax add action

I'm trying to submit a form via AJAX and prevent a redirect after the form is submitted. I don't understand why I'm having this issue since I set autoRender to false. Controller Code function add() { $this->autoRender = false; if (!empty($this->data)) { $this->data['Comment']['user_id'] = $this->Auth->user('id'); ...

Dynamically adding parameters to jQuery

Hi all, I'm using a plugin called jQuery image map emulator which takes parameters like so: $('#example').imagemap([ { top_x: 0, top_y: 0, bottom_x: 75, bottom_y:65, callback: alertCallback} ]) with multiple arrays possible: $('#example').imagemap([ // One image map {top_x: 0,top_y: 0,bottom_x: 75,bottom_y:65,call...

Superfish Menu inside WordPress Queries

Hi, I am using jQuery Superfish Menu inside my WordPress theme, where I have the following setup inside my sidebar.php file: <div id="sidebar"> <ul id="themenu" class="sf-menu sf-vertical"> <li><a href="index.html" class="topm currentMenu nosub">Home</a></li> <li><a href="about-us.html" class="...

Frameset sharing a javascript library.

My website is currently using a frameset, and two frames use AJAX, and one other frame uses jQuery (just for animation). I'd like all the frames to have access to the jQuery library. But i feel it's really in-efficient to hotlink to googlecode on each frame. is there a way of giving all frames access to the jQuery library by only linkin...

jQuery display image title in span tag

Hi, I have a unordered list being shown - each li tag contains an image with an empty span tag under it. I want the title attribute of the image to display in the span tag. I am using this below and it works, but it shows the titles from ALL images in the first span tag... I need to somehow make sure the title from the image goes in it...

Retrive submit label using jQuery

Hi all i have the html as follows <div class="element-container" id="div_3"> <div id="submit_submit" class="element"> <div class="fleft"> <input type="submit" value="Click me!" name="submit" id="submit"/> </div> <div class="clr"/> </div> </div> When i click on element-container i want the ...

Writing to a file on a server with jQuery?

I am developing an application which requires the reading and writing of XML files. Reading I've got covered, but is writing possible at all? The layout of my webapp is like this: ../includes/ (irrelevant) ../content.xml (xml to be written to) ../index.html (irrelevant) ../admin.html (file to write with) Any help appreciated, thanks. ...

Get the value of a variable in a loop

I have a loop that when it is called, creates a div with some form elements in them. Each div is based on a variable, "i" to give unique names to the fields and divs. Is there a way I can store what the variable was at the point of creating the div? For example, div1 is created and everything in it has 1 (the variable) attached to the n...

jQuery variable scope?

Why can’t I assign ajaxResult to result? console.log(result); works correctly which is inside the success option and appears second in the console. but result of the last of console.log(result); is undefined and first appears in the console. what is wrong with this? $(function () { var result; $.ajax({ type:...

jQuery: How to get ID of dynamically generated element?

Here's the rundown: I am creating a table dynamically from the results of an AJAX call. To add the rows, I am using the "after" function, seeing as there are certain rows in the table that function as headers. After I add these rows, I have a quantity box that I would like to make editable. I am able to add an event to it, however I ...

jQuery fullcalendar: Fadeout deleted Event

Heyhou, I want to fadeOut the "eventbar" in the calendar I have deleted. What should I do? eventClick: function(calEvent, jsEvent, view) { // $(this).animate({ opacity: 0 }, 1000); <- ??? $('#kal').fullCalendar('removeEvents', calEvent.id); } Thanks for ur answers! ...

Can I control different progressbars for different ajax events?

Hello all, I have a form with two places that use ajax to submit the information to server. $("#loading img").ajaxStart(function(){ // this progress bar is used by both ajax submission. $(this).show(); }).ajaxStop(function(){ $(this).hide(); }); <div id="loading"> <img src="loading4.gif" border="0" /> </div> $('#countyForm...

jquery set height AFTER load

I am having a little trouble setting the height of an element that I am loading in dynamically. I use the jquery load function to load an external (dynamic) page into a div (#cbox) on my current page. Because this subpage is dynamic, I can't know beforehand what the height of the content is. I want to get the height, once content is loa...

Autocomplete error, null is not an object, IE only.

Hi, the following code works well in Chrome/FireFox, but error in IE. The error shows the message. Message: 'name' is null or not an object I know there are quite a few questions related. But they seem to be different in some way. So, please help. Thanks. (The error is occurred at line 7) $("#keywords").autocomplete('downloa...

Get select values and radio values using jquery

Hi all, I have the following set of html for both radio and select box i want to get the value with comma seperated FOR RADIO BUTTON <div class="element" id="radio_gender"> <div class="fleft"> <label for="gender">Gender</label> </div> <div class="fleft"> <input type="radio" value="Male" name="gender" />...

Why use CakePhp AJAX helper instead of jQuery?

Hello, I'm just starting using cakePHP and I saw on that there was an AJAX Helper in it. My question is simple : should I rather use this helper or should I keep doing AJAX with jQuery? Are there any changes I should perform in existing jQuery AJAX calls? Thanks ...