acs_messaging_format_as_html (private)

 acs_messaging_format_as_html mime_type content

Defined in packages/acs-messaging/tcl/acs-messaging-procs.tcl

Returns a string of HTML which appropriately renders the content given its mime content-type. This function supports three content types, "text/plain", "text/plain; format=flowed", and "text/html"

Parameters:
mime_type - MIME content-type of content
content - Text to view

Partial Call Graph (max 5 caller/called nodes):
%3 test_acs_messaging_format_as_html acs_messaging_format_as_html (test acs-messaging) acs_messaging_format_as_html acs_messaging_format_as_html test_acs_messaging_format_as_html->acs_messaging_format_as_html ad_text_to_html ad_text_to_html (public) acs_messaging_format_as_html->ad_text_to_html

Testcases:
acs_messaging_format_as_html
Source code:
    if {$mime_type eq "text/plain"} {
    set result "<pre>[ns_quotehtml $content]</pre>"
    } elseif {$mime_type eq "text/plain; format=flowed"} {
    set result [ad_text_to_html -- $content]
    } elseif {$mime_type eq "text/html"} {
    set result $content
    } else {
    set result "<i>content type undecipherable</i>"
    }
    return $result
Generic XQL file:
packages/acs-messaging/tcl/acs-messaging-procs.xql

PostgreSQL XQL file:
packages/acs-messaging/tcl/acs-messaging-procs-postgresql.xql

Oracle XQL file:
packages/acs-messaging/tcl/acs-messaging-procs-oracle.xql

[ hide source ] | [ make this the default ]
Show another procedure: