Posted by Matt
2014-04-28

Hello Tom,
I am adding a datepicker function to a dateofbirth field.I am editing tpl.addresses.detail.inc to incorporate that using jquery.I am calling the #rs:def:date_of_birth value in jquery.How do I modify the following code to make a calendar popup when the dob field is clicked?
<td class='column_caption'>
<?php if ( $b_reg || $b_edit ) { ?><span class="required"></span><?php } ?>
<?php echo RSTR_DATE_OF_BIRTH; ?> :
</td>
<td class='column_value'><?php echo $hm->Zb('rs:def:date_of_birth'); ?>
</td>
Posted by Tom
2014-04-28

Hi Matt,

I assume you already know how to setup the date picker on a regular input box like
<input id='some-id' type='text' name='some-name' />
If you don't know, please read a manual of the datepicker.

So, you need to assign an id to the input box. You can do it like this:
<?php echo $hm->Zb('rs:def:def:date_of_birth', ZB_ATTR, array( "id" => "enter-your-id-here" ) ); ?>