xo::ical proc text_to_ical (public)

 xo::ical[i] text_to_ical [ -remove_tags on|off ] text

Defined in packages/xotcl-core/tcl/01-debug-procs.tcl

Transform arbitrary text to the escaped ical text format (see rfc 2445)

Switches:
-remove_tags (optional, boolean, defaults to "false")
Parameters:
text (required)

Testcases:
No testcase defined.
Source code:
#
# Transform arbitrary text to the escaped ical text format
# (see rfc 2445)
#

if {$remove_tags} {
  regsub -all {<[^>]+>} $text "" text
}
regsub -all {(\\|\;|\,)} $text {\\\1} text
regsub -all \n $text {\\n} text
return $text
XQL Not present:
Generic, PostgreSQL, Oracle
[ hide source ] | [ make this the default ]
Show another procedure: