Jump to content

Form Input Arrays


cesarcesar

Recommended Posts

Im using this Calendar, http://www.calendarxp.net/, on my page. It works great as exampled on the site. My problem comes in when i use the calendar in a form textfield that is an array. I think my *document.this_form.example[]* call is incorrect, but my novice JS knowledge is preventing me from getting it right.

 

Please explain how i can get the calendar to work in the following example. The first textfield call works since it is not in an array.

 

Thanks much.

 

<form method="POST" action="example.php" name="this_form">
<input type="text" id="example_working" name="example_working" onfocus="if(self.gfPop)gfPop.fPopCalendar(document.this_form.example_working);return false;">
<input type="text" id="example[]" name="example[]" onfocus="if(self.gfPop)gfPop.fPopCalendar(document.this_form.example[]);return false;">
<input type="text" id="example[]" name="example[]" onfocus="if(self.gfPop)gfPop.fPopCalendar(document.this_form.example[]);return false;">
<input type="text" id="example[]" name="example[]" onfocus="if(self.gfPop)gfPop.fPopCalendar(document.this_form.example[]);return false;">
<input type="text" id="example[]" name="example[]" onfocus="if(self.gfPop)gfPop.fPopCalendar(document.this_form.example[]);return false;">
<input type="text" id="example[]" name="example[]" onfocus="if(self.gfPop)gfPop.fPopCalendar(document.this_form.example[]);return false;">
</form>

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.