LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices


Reply
  Search this Thread
Old 08-16-2004, 11:38 AM   #1
agallant
Member
 
Registered: Oct 2003
Location: D.C USA
Distribution: Redhat 9. Thinking about Slackware
Posts: 166

Rep: Reputation: 30
Text Box popup


I have a form with a text box in it. when uses click on the text box i want it to pop up a new window with a calandar in it, the user selects the date by clicking on it, the calandar window closes and the date selected appears in the text box. I tried playing with a few java scripts to do this but i could not get any of them to work. It does nothing


-------------------------------------------------------------------------

<html>
<head>
<title>test</title>

<script language="JavaScript1.2">
function popcalendar() {

newWindow = window.open('calendar.php', 'myWindow2','width=570,height=400,directories=0,status=1,menuBar=0,scrollBars=1,resizable=1');
newWindow.focus()
}
</script>
<body>
<input type='text' size='13' name='displayDate' OnClick=\"javascriptopcalendar()>

</body>
</html>
-------------------------------------------------------------------------
 
Old 08-16-2004, 12:11 PM   #2
Cedrik
Senior Member
 
Registered: Jul 2004
Distribution: Slackware
Posts: 2,140

Rep: Reputation: 244Reputation: 244Reputation: 244
Try add in calendar.php :

function changeDisplayDateText( text ) {
window.opener.document.displayDate.value = text;
}

You call it with a onClick() on the calendar and give text value as argument
 
Old 08-16-2004, 12:56 PM   #3
agallant
Member
 
Registered: Oct 2003
Location: D.C USA
Distribution: Redhat 9. Thinking about Slackware
Posts: 166

Original Poster
Rep: Reputation: 30
OK, I'm lost can you explain it to me like i am an idiot? I am fairly new to Java.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
openoffice 2- how do i create a text box? lefty.crupps Linux - Software 2 11-02-2005 10:29 PM
C Xlib scrollable text box serbet Programming 0 09-22-2004 03:13 AM
Can I create a popup box that alerts me when someone logs in to my box remotely? davee Linux - Security 1 06-29-2004 03:00 PM
How do I make a message box popup for all users? Joey.Dale Linux - General 3 04-09-2004 12:49 AM
How to define Text box as numeric Linh Programming 1 09-24-2003 03:59 PM

LinuxQuestions.org > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 09:15 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration