ad_page_contract_filter_proc_clock (public)
ad_page_contract_filter_proc_clock name value_varname [ formats ]
Defined in packages/acs-tcl/tcl/tcl-documentation-procs.tcl
Ensures the supplied date string is in one of the specified clock formats.
- Parameters:
- name
value_varname
formats (defaults to"%Y-%m-%d"
)
- Author:
- Antonio Pisano
- See Also:
- clock
- Partial Call Graph (max 5 caller/called nodes):
- Testcases:
- ad_page_contract_filters
Source code: upvar $value_varname value set valid_p 0 foreach format $formats { if { ![catch { clock scan $value -format $format } errmsg] } { set valid_p 1 break } } if {!$valid_p} { set time(time) [ns_quotehtml $value] ad_complain [_ acs-tcl.lt_Invalid_time_timetime_2] } return $valid_pXQL Not present: Generic, PostgreSQL, Oracle