searls03 Posted March 21, 2011 Share Posted March 21, 2011 Can you help me set up a way for a calendar to show up when a textfield is clicked on........ <td width="100">Start Date</td> <td><input name="startdate" type="text"></td> </tr> <tr> <td>End Date</td> <td><label for="enddate"></label> <input type="text" name="enddate" id="enddate" /> Quote Link to comment Share on other sites More sharing options...
gizmola Posted March 21, 2011 Share Posted March 21, 2011 Take a look at jqueryui datepicker. http://jqueryui.com/demos/datepicker/ Quote Link to comment Share on other sites More sharing options...
searls03 Posted March 21, 2011 Author Share Posted March 21, 2011 I have, and I can't seem to get it to work when you click in the box, it just shows up on page load Quote Link to comment Share on other sites More sharing options...
gizmola Posted March 21, 2011 Share Posted March 21, 2011 Let's see your code then. Quote Link to comment Share on other sites More sharing options...
searls03 Posted March 21, 2011 Author Share Posted March 21, 2011 here is what I have for now...... <script> $(function() { $( "#datepicker" ).datepicker(); }); </script> <div class="demo"> <td width="100">Start Date</td> <td><input name="startdate" type="text" id="datepicker"></td> </div><!-- End demo --> Quote Link to comment Share on other sites More sharing options...
searls03 Posted March 21, 2011 Author Share Posted March 21, 2011 ok, so I sorta have it working now, but It is behind all other text fields...........can you help me fix this. <div id="apDiv23"> <form action="addevent.php" method="post"> <table width="830" border="0" cellpadding="2" cellspacing="1" align="center"> <tr> <td width="100">Event Name </td> <td><input name="event" type="text"></td> </tr> <tr><script> $(function() { $( "#datepicker" ).datepicker(); }); </script> <td width="100">Start Date</td> <td><input name="startdate" type="text" id="datepicker"></td> <script type="text/javascript"> // BeginOAWidget_Instance_2137022: #datepicker_2 $(function() { $("#datepicker").datepicker({ showOtherMonths: false }); }); // EndOAWidget_Instance_2137022 </script> </tr> <tr> <td>End Date</td> <td><label for="enddate"></label> <input type="text" name="enddate" id="enddate" /></td> </tr> <tr> <td width="100" height="92">Description</td> <td><script type="text/javascript"> // BeginOAWidget_Instance_2204022: #postContent tinyMCE.init({ // General options mode : "exact", elements : "description", theme : "advanced", skin : "default", plugins : "pagebreak,style,layer,table,save,advhr,advimage,advlink,emotions,iespell,inlinepopups,insertdatetime,preview,media,searchreplace,print,contextmenu,paste,directionality,fullscreen,noneditable,visualchars,nonbreaking,xhtmlxtras,template,wordcount,advlist,autosave", // Theme options theme_advanced_buttons1 : "save,newdocument,print,bold,italic,underline,strikethrough,justifyleft,justifycenter,justifyright,justifyfull,styleselect,formatselect,fontselect,fontsizeselect,", theme_advanced_buttons2 : "cut,copy,paste,pastetext,pasteword,|,search,replace,bullist,numlist,|,outdent,indent,blockquote,|,undo,redo,|,link,unlink,anchor,|,image,media,|,forecolor,backcolor,|,insertdate,inserttime,", theme_advanced_buttons3 : "hr,cite,abbr,acronym,del,ins,sub,sup,visualchars,nonbreaking,charmap,emotions,ltr,rtl,|,code,preview,fullscreen,help,cleanup,removeformat,|,styleprops,attribs,", theme_advanced_buttons4 : "tablecontrols,visualaid,|,insertlayer,moveforward,movebackward,absolute,visualaid,|,template,pagebreak,restoredraft,", theme_advanced_toolbar_location : "top", theme_advanced_toolbar_align : "left", theme_advanced_statusbar_location : "bottom", theme_advanced_resizing : true, // Example content CSS (should be your site CSS) content_css : "/css/editor_styles.css", // Drop lists for link/image/media/template dialogs, You shouldn't need to touch this template_external_list_url : "/lists/template_list.js", external_link_list_url : "/lists/link_list.js", external_image_list_url : "/lists/image_list.js", media_external_list_url : "/lists/media_list.js", // Style formats: You must add here all the inline styles and css classes exposed to the end user in the styles menus style_formats : [ {title : 'Bold text', inline : 'b'}, {title : 'Red text', inline : 'span', styles : {color : '#ff0000'}}, {title : 'Red header', block : 'h1', styles : {color : '#ff0000'}}, {title : 'Example 1', inline : 'span', classes : 'example1'}, {title : 'Example 2', inline : 'span', classes : 'example2'}, {title : 'Table styles'}, {title : 'Table row 1', selector : 'tr', classes : 'tablerow1'} ] }); // EndOAWidget_Instance_2204022 </script> <!-- Textarea gets replaced with TinyMCE, remember HTML in a textarea should be encoded --> <textarea id="description" name="description" rows="15" style="width:80%"></textarea></td> </tr> <tr> <td width="100">Price</td> <td><input name="price" type="text"></td> </tr> <tr> <td width="100">Location</td> <td><label for="location"></label> <input type="text" name="location" id="location" /></td> </tr> <tr> <td colspan="2" align="left"><input name="save" type="submit" value="Save Article"></td> </tr> </table> </form> Quote Link to comment Share on other sites More sharing options...
nogray Posted March 21, 2011 Share Posted March 21, 2011 Try my calendar =) http://www.nogray.com/calendar.php Quote Link to comment Share on other sites More sharing options...
searls03 Posted March 23, 2011 Author Share Posted March 23, 2011 can you please help me fix the issue? Quote Link to comment Share on other sites More sharing options...
searls03 Posted March 27, 2011 Author Share Posted March 27, 2011 any help on making it stay in front of other fields? Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.