Win a copy of Five Lines of Code this week in the OO, Patterns, UML and Refactoring forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Bear Bibeault
  • Ron McLeod
  • Jeanne Boyarsky
  • Paul Clapham
Sheriffs:
  • Tim Cooke
  • Liutauras Vilda
  • Junilu Lacar
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • fred rosenberger
  • salvin francis
Bartenders:
  • Piet Souris
  • Frits Walraven
  • Carey Brown

creating a pop up calendar within a form

 
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
I am working to create a pop up calendar which puts the selected date as an input to a form. I can do this when the only "select" in the form is this date. But now, I need to do two things.Firsrt, there's a drop down list that allows user to enter a date "before", "after" or "between" and Second, depending on which of the three the user selected, pop up one or two (for "between" )form field ( as a part of the same form ) where the user can now use the calendar to enter the date.
Any advice would help.
thanks.
 
trisha west
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks Eric. But I do have the pop up calendar. What's not working is the second part where I have:
<FORM name='theForm'>
Enter a date
<SELECT name="date" onchange='popupCalendar()'>
<OPTION value = 'before' type=text >before</OPTION>
<OPTION value = 'after' type=text >after</OPTION>
<OPTION value = 'between' type=text >between</OPTION>
</SELECT>
</FORM>
What I want popupCalendar() to do is,
if user selected 'before', pop an input field with an icon similar to one of those in the links you gave.
The final aim is that I can make a sql stmt of the order
WHERE startDatevalue = 'before', Date = <user Selection from calendar>.
If the user selected "between", the same stmt would change to
.....WHERE startDateValue= 'between', earlyDate=<earlier of the two Dates>, laterDate=<later of the two Dates>.....
Thus if user selected 'between' I have to pop up two such objects (each consisting of an input field and an icon for calendar).
I can use 'switch' to do that. But I dont know how to have this input field without using html in the script itself.
Hope this clarifies the problem.
 
Eric Pascarello
author
Posts: 15385
6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
This is just a dynamic sql statement. I currently have something like this in effect at my work. Are you doing this in jsp or asp?
 
trisha west
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
JSP
 
Don't get me started about those stupid light bulbs.
    Bookmark Topic Watch Topic
  • New Topic