Solved

How to trigger an event with jquery?

Posted on 2012-03-28
2
316 Views
Last Modified: 2012-03-28
I have two text boxes as a date fields and I need that after altering the first one, the second one automatically shows a new date (a month after the previous date)

The second field can be modified manually, the event only must be triggered after altering the first text box / date.

Regards.
0
Comment
Question by:dimensionav
2 Comments
 
LVL 40

Accepted Solution

by:
gurvinder372 earned 250 total points
ID: 37776573
you can bind the blur event to first textbox

$("#textbox1").bind("blur", function(){

 $("#textbox2").val(calculateNextDate());
});

function calculateNextDate()
{
}
0
 
LVL 108

Assisted Solution

by:Ray Paseur
Ray Paseur earned 250 total points
ID: 37776728
You might make a Google search for "jQuery Date Picker" - there are a lot of solutions that will work for this sort of thing.  Not exactly what you want but a good demonstration of the principles is available here:
http://jqueryui.com/demos/datepicker/
0

Featured Post

What Is Threat Intelligence?

Threat intelligence is often discussed, but rarely understood. Starting with a precise definition, along with clear business goals, is essential.

Join & Write a Comment

Introduction HyperText Transfer Protocol (http://www.ietf.org/rfc/rfc2616.txt) or "HTTP" is the underpinning of internet communication.  As a teacher of web development I have heard many questions, mostly from my younger students who have come to t…
Introduction Got endorsements from your clients?  Great!  There is almost nothing better than word-of-mouth advertising.  But how can you do that on the internet?  Sure you can make a page for endorsement quotations and list them all, but who is …
The viewer will learn how to dynamically set the form action using jQuery.
This tutorial will teach you the core code needed to finalize the addition of a watermark to your image. The viewer will use a small PHP class to learn and create a watermark.

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

23 Experts available now in Live!

Get 1:1 Help Now