function jsmarty_function_html_select_time(T,K){var d=JSmarty.Plugin;var G=d.get("php.range"),a=d.get("php.strftime");var p=d.get("function.html_options",K.plugins_dir);var w,Q,P,j=new JSmarty.Classes.Buffer(),x;var b,h,S,W,D,A=[];var z=new Date().getTime();var u="Time_";var U=null;var R=null;var H=null;var y=null;var B=null;var Z=true;var o=true;var f=null;var r=true;var q=true;var X=1;var s=1;var C=true;for(P in T){v=T[P];switch(P){case "time":z=v;break;case "prefix":u=v;break;case "all_extra":U=v;break;case "hour_extra":R=v;break;case "field_array":H=v;break;case "use_24_hours":Z=v;break;case "minute_extra":y=v;break;case "second_extra":B=v;break;case "display_hours":o=v;break;case "display_hours":o=v;break;case "meridian_extra":f=v;break;case "display_minutes":r=v;break;case "display_meridian":C=v;break;case "minute_interval":X=parseInt(v);break;case "second_interval":s=parseInt(v);break;default:K.trigger_error("html_select_time: unknown parameter "+P,"info");break;}}if(o){b=Z?G(0,23):G(0,12);h=Z?"%H":"%I";for(Q=0,S=b.length;Q<S;Q++){b[Q]=(b[Q]<10)?"0"+b[Q]:b[Q];}x=p({output:b,values:b,selected:a(h,z)},K);j.append("<select name=\"");j.appendIf(H)(H,"[",u,"Hour]\"");j.appendIf(!H)(u,"Hour\"");j.appendIf(R)(" ",R);j.appendIf(U)(" ",U);j.append(">\n",x,"</select>\n");}if(r){W=G(0,59);for(Q=0,w=0,S=W.length;Q<S;Q+=X){A[w++]=(W[Q]<10)?"0"+W[Q]:W[Q];}D=parseInt(Math.floor(a("%M",z)/X)*X);x=p({output:A,values:A,selected:(D<10)?"0"+D:D},K);j.append("<select name=\"");j.appendIf(H)(H,"[",u,"Minute]\"");j.appendIf(!H)("\"",u,"Minute\"");j.appendIf(y)(" ",y);j.appendIf(U)(" ",U);j.append(">\n",x,"</select>\n");}if(C&&!Z){x=p({output:["AM","PM"],values:["AM","PM"],selected:a("%p",z).toUpperCase(),print_result:false},K);j.append("<select name=\"");j.appendIf(H)(H,"[",u,"Meridian]\"");j.appendIf(!H)(u,"Meridian\"");j.appendIf(f)(" ",f);j.appendIf(U)(" ",U);j.append(">\n",x,"</select>\n");}return j.toString();}