Jump to content

Problem with datepicker from rainforest.net


larissahn

Recommended Posts

hello, I created a php form. http://www.utilaecology.org/research/lionfish_contact.php

I want the user to be able to select the date from a calendar, but I've had so many problems. http://www.rainforestnet.com/datetimepicker.htm

this is the code for the form up until the date text field.

<?php include('../includes/core.php'); layout_start(true); ?>
<style type="text/css">
<!--
.Estilo3 {font-size: 12px}
-->
</style>

<script type="text/javascript" src="datetimepicker_css.js"></script>

<table width="599" border="0" cellspacing="4" cellpadding="5">
                    <tr>
                      <td width="567" height="28" background="../assets/images/section-bkgd_long.gif" class="SectionText">Report lionfish sighting</td>
                    </tr>
                    <tr>
                      <td><p align="justify">Please fill in the form below if you would like to report a lionfish sighting and we will get back to you as soon as possible. </p>
                      <hr size="1" noshade="noshade" /></td>
                    </tr>
                    <tr>
                      <td><form name="LionfishContactForm" method="post" action="sendmail.php">
                        <table width="100%"  border="0">
                          <tr>
                            <td><div align="left">
                                <label>Name:</label>
                             </div></td>
                            <td><input name="name" type="text" id="name" size="60" maxlength="30"></td>
                          </tr>
                          <tr>
                            <td><div align="left">
                                <label>Email:</label>
                             </div></td>
                            <td><input name="email" type="text" id="email" size="60" maxlength="30"></td>
                          </tr>
                          <tr>
                            <td><label>Date:</label> </td>
                            <td><input name="date" type="text" id="date" size="35">
                              <img src="../assets/images/cal.gif" alt="Pick a date">
                          </tr> 

i think you need to read the documentation a tad more in detail...try this...

 

<?php include('../includes/core.php'); layout_start(true); ?>
<style type="text/css">
<!--
.Estilo3 {font-size: 12px}
-->
</style>

<script type="text/javascript" src="datetimepicker_css.js"></script>

<table width="599" border="0" cellspacing="4" cellpadding="5">
                    <tr>
                      <td width="567" height="28" background="../assets/images/section-bkgd_long.gif" class="SectionText">Report lionfish sighting</td>
                    </tr>
                    <tr>
                      <td><p align="justify">Please fill in the form below if you would like to report a lionfish sighting and we will get back to you as soon as possible. </p>
                      <hr size="1" noshade="noshade" /></td>
                    </tr>
                    <tr>
                      <td><form name="LionfishContactForm" method="post" action="sendmail.php">
                        <table width="100%"  border="0">
                          <tr>
                            <td><div align="left">
                                <label>Name:</label>
                             </div></td>
                            <td><input name="name" type="text" id="name" size="60" maxlength="30"></td>
                          </tr>
                          <tr>
                            <td><div align="left">
                                <label>Email:</label>
                             </div></td>
                            <td><input name="email" type="text" id="email" size="60" maxlength="30"></td>
                          </tr>
                          <tr>
                            <td><label>Date:</label> </td>
                            <td><input name="date" type="text" id="date" size="35">
                              <a href="javascript:NewCssCal('demo1')"> 
                              <img src="../assets/images/cal.gif" alt="Pick a date"></a>
                          </tr> 

 

looks like you are including the js file required..should all work out fine now...

 

Cheers!

hi, I made the changes you suggested, but it still doesn't work. there is no popup, just an error. this is the new code:

 <?php include('../includes/core.php'); layout_start(true); ?>
<style type="text/css">
<!--
.Estilo3 {font-size: 12px}
-->
</style>

<script type="text/javascript" src="datetimepicker_css.js"></script>

<table width="599" border="0" cellspacing="4" cellpadding="5">
                    <tr>
                      <td width="567" height="28" background="../assets/images/section-bkgd_long.gif" class="SectionText">Report lionfish sighting</td>
                    </tr>
                    <tr>
                      <td><p align="justify">Please fill in the form below if you would like to report a lionfish sighting and we will get back to you as soon as possible. </p>
                      <hr size="1" noshade="noshade" /></td>
                    </tr>
                    <tr>
                      <td><form name="LionfishContactForm" method="post" action="sendmail.php">
                        <table width="100%"  border="0">
                          <tr>
                            <td><div align="left">
                                <label>Name:</label>
                             </div></td>
                            <td><input name="name" type="text" id="name" size="60" maxlength="30"></td>
                          </tr>
                          <tr>
                            <td><div align="left">
                                <label>Email:</label>
                             </div></td>
                            <td><input name="email" type="text" id="email" size="60" maxlength="30"></td>
                          </tr>
                          <tr>
                            <td><label>Date:</label> </td>
                            <td><input name="date" type="text" id="date" size="35">
                              <a href="javascript:NewCssCal('demo1')"> 
                              <img src="../assets/images/cal.gif" alt="Pick a date"></a>
                          </tr> 
                          <tr>
                            <td><div align="left"> 

of course, there are other fiels after the date. but they are not important, I think? I have uploaded all the files needed to the server. there is no html head, because I'm calling a function that stores the template of my site. I'm really not sure where the problem is. thanks!

<?php include('../includes/core.php'); layout_start(true); ?>
<style type="text/css">
<!--
.Estilo3 {font-size: 12px}
-->
</style>

<script type="text/javascript" src="datetimepicker_css.js"></script>

<table width="599" border="0" cellspacing="4" cellpadding="5">
                    <tr>
                      <td width="567" height="28" background="../assets/images/section-bkgd_long.gif" class="SectionText">Report lionfish sighting</td>
                    </tr>
                    <tr>
                      <td><p align="justify">Please fill in the form below if you would like to report a lionfish sighting and we will get back to you as soon as possible. </p>
                      <hr size="1" noshade="noshade" /></td>
                    </tr>
                    <tr>
                      <td><form name="LionfishContactForm" method="post" action="sendmail.php">
                        <table width="100%"  border="0">
                          <tr>
                            <td><div align="left">
                                <label>Name:</label>
                             </div></td>
                            <td><input name="name" type="text" id="name" size="60" maxlength="30"></td>
                          </tr>
                          <tr>
                            <td><div align="left">
                                <label>Email:</label>
                             </div></td>
                            <td><input name="email" type="text" id="email" size="60" maxlength="30"></td>
                          </tr>
                          <tr>
                            <td><label>Date:</label> </td>
                            <td><input name="date" type="text" id="date" size="35">
                              <a href="javascript:NewCssCal('date')"> <!--change this line-->
                              <img src="../assets/images/cal.gif" alt="Pick a date"></a>
                          </tr> 
                          <tr>
                            <td><div align="left">

 

ooops....forgot one small change...try now... :-)

Archived

This topic is now archived and is closed to further replies.

×
×
  • 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.