diff options
author | friendica <info@friendica.com> | 2015-02-05 21:01:02 -0800 |
---|---|---|
committer | friendica <info@friendica.com> | 2015-02-05 21:01:02 -0800 |
commit | e7a68eaef002a9263d20076bcbe6b4c93378255f (patch) | |
tree | 12abda2f0f54e4bef46113d5385f595d257432af | |
parent | abcc70722c3577e63b53fcd3acf19d2916d810df (diff) | |
download | volse-hubzilla-e7a68eaef002a9263d20076bcbe6b4c93378255f.tar.gz volse-hubzilla-e7a68eaef002a9263d20076bcbe6b4c93378255f.tar.bz2 volse-hubzilla-e7a68eaef002a9263d20076bcbe6b4c93378255f.zip |
style the checkboxes in the event form
-rwxr-xr-x | mod/events.php | 2 | ||||
-rw-r--r-- | view/js/mod_events.js | 2 | ||||
-rwxr-xr-x | view/tpl/event_form.tpl | 10 |
3 files changed, 9 insertions, 5 deletions
diff --git a/mod/events.php b/mod/events.php index 7143963f4..233447cb1 100755 --- a/mod/events.php +++ b/mod/events.php @@ -588,8 +588,8 @@ function events_content(&$a) { '$n_checked' => $n_checked, '$f_text' => t('Event Finishes:'), '$f_dsel' => datetimesel($f,new DateTime(),DateTime::createFromFormat('Y',$fyear+5),DateTime::createFromFormat('Y-m-d H:i',"$fyear-$fmonth-$fday $fhour:$fminute"),'finish_text',true,true,'start_text'), + '$adjust' => array('adjust', t('Adjust for viewer timezone'), $a_checked), '$a_text' => t('Adjust for viewer timezone'), - '$a_checked' => $a_checked, '$d_text' => t('Description:'), '$d_orig' => $d_orig, '$l_text' => t('Location:'), diff --git a/view/js/mod_events.js b/view/js/mod_events.js index 0ce128fcc..d4dc9b585 100644 --- a/view/js/mod_events.js +++ b/view/js/mod_events.js @@ -2,7 +2,7 @@ $(document).ready( function() { showHideFinishDate(); }); function showHideFinishDate() { - if( $('#event-nofinish-checkbox').is(':checked')) + if( $('#id_nofinish').is(':checked')) $('#event-finish-wrapper').hide(); else $('#event-finish-wrapper').show(); diff --git a/view/tpl/event_form.tpl b/view/tpl/event_form.tpl index 1cea156dd..444e77df7 100755 --- a/view/tpl/event_form.tpl +++ b/view/tpl/event_form.tpl @@ -24,7 +24,12 @@ <div class="clear"></div><br /> -<input type="checkbox" name="nofinish" value="1" id="event-nofinish-checkbox" {{$n_checked}} onclick="showHideFinishDate(); return true;" /> <div id="event-nofinish-text">{{$n_text}}</div> + <div class='field checkbox'> + <label class="mainlabel" for='id_nofinish'>{{$n_text}}</label> + <div><input type="checkbox" name='nofinish' id='id_nofinish' value="1" {{$n_checked}} onclick="showHideFinishDate(); return true;" > + <label class="switchlabel" for='id_nofinish'> <span class="onoffswitch-inner" data-on='' data-off='' ></span> + <span class="onoffswitch-switch"></span> </label></div><span class='field_help'></span> + </div> <div id="event-nofinish-break"></div> @@ -35,8 +40,7 @@ <div id="event-datetime-break"></div> - -<input type="checkbox" name="adjust" value="1" id="event-adjust-checkbox" {{$a_checked}} /> <div id="event-adjust-text">{{$a_text}}</div> +{{include file="field_checkbox.tpl" field=$adjust}} <div id="event-adjust-break"></div> |