- Publicity: Public Only All
deprecated-procs.tcl
Provides a collection of deprecated procs to provide backward compatibility for sites who have not yet removed calls to the deprecated functions. In order to skip loading of deprecated code, use the following snippet in your config file ns_section ns/server/${server}/acs ns_param WithDeprecatedCode 0
- Location:
- packages/acs-templating/tcl/deprecated-procs.tcl
- CVS Identification:
$Id: deprecated-procs.tcl,v 1.12 2024/11/14 12:02:03 antoniop Exp $
Procedures in this file
- template::form::export (public, deprecated)
- template::get_resource_path (public, deprecated)
- template::query::iterate (public, deprecated)
- template::util::clear_cookie (public, deprecated)
- template::util::get_cookie (public, deprecated)
- template::util::get_param (public, deprecated)
- template::util::list_opts (public, deprecated)
- template::util::multirow_foreach (public, deprecated)
- template::util::quote_html (public, deprecated)
- template::util::set_cookie (public, deprecated)
- template::util::set_param (public, deprecated)
- template::util::set_to_list (public, deprecated)
- template::util::set_to_vars (public, deprecated)
- template::util::tcl_to_sql_list (public, deprecated)
- template::widget::richtext_htmlarea (public, deprecated)
Detailed information
template::form::export (public, deprecated)
template::form::export
Deprecated. Invoking this procedure generates a warning.
Generates hidden input tags for all values in a form submission. Typically used to create a confirmation page following an initial submission. DEPRECATED: this proc has been superseded by export_vars, which also offers additional features.
- Returns:
- A string containing hidden input tags for inclusion in a form.
- See Also:
- Testcases:
- No testcase defined.
template::get_resource_path (public, deprecated)
template::get_resource_path
Deprecated. Invoking this procedure generates a warning.
Get the template directory The body is doublequoted, so it is interpreted when this file is read
- See Also:
- Testcases:
- No testcase defined.
template::query::iterate (public, deprecated)
template::query::iterate statement_name sql body
Deprecated. Invoking this procedure generates a warning.
- Parameters:
- statement_name (required)
- Standard db_api statement name used to hook into query dispatcher
- sql (required)
- Query to use when processing this command
- body (required)
- Code body to be execute for each result row of the returned query
- See Also:
- Testcases:
- No testcase defined.
template::util::clear_cookie (public, deprecated)
template::util::clear_cookie name [ domain ]
Deprecated. Invoking this procedure generates a warning.
Expires an existing cookie.
- Parameters:
- name (required)
- domain (optional)
- See Also:
- Testcases:
- No testcase defined.
template::util::get_cookie (public, deprecated)
template::util::get_cookie name [ default_value ]
Deprecated. Invoking this procedure generates a warning.
Retrieve the value of a cookie and return it Return the default if no such cookie exists
- Parameters:
- name (required)
- default_value (optional)
- See Also:
- Testcases:
- No testcase defined.
template::util::get_param (public, deprecated)
template::util::get_param name [ section ] [ key ]
Deprecated. Invoking this procedure generates a warning.
Retrieve a stored parameter, or "" if no such parameter If section/key are present, read the parameter from the specified section.key in the INI file, and cache them under the given name
- Parameters:
- name (required)
- section (optional)
- key (optional)
- Testcases:
- No testcase defined.
template::util::list_opts (public, deprecated)
template::util::list_opts [ array_ref ]
Deprecated. Invoking this procedure generates a warning.
Converts an array to an option list DEPRECATED: this proc can be replaced by simple tcl idioms
- Parameters:
- array_ref (optional, defaults to
"opts")- The name of the array in the calling frame containing option-value pairs. Defaults to "opts".
- Returns:
- A list of option-value pairs suitable for appending to a command.
- See Also:
- plain tcl
- Testcases:
- No testcase defined.
template::util::multirow_foreach (public, deprecated)
template::util::multirow_foreach name code_text
Deprecated. Invoking this procedure generates a warning.
runs a block of code foreach row in a multirow. Using "template::multirow foreach" is recommended over this routine.
- Parameters:
- name (required)
- the name of the multirow over which the block of code is iterated
- code_text (required)
- the block of code in the for loop; this block can reference any of the columns belonging to the multirow specified; with the multirow named "fake_multirow" containing columns named "spanky" and "foobar",to set the column spanky to the value of column foobar use:
set fake_multirow.spanky @fake_multirow.foobar@note: this block of code is evaluated in the same scope as the .tcl page that uses this procedure
- Author:
- simon
- See Also:
- Testcases:
- No testcase defined.
template::util::quote_html (public, deprecated)
template::util::quote_html html
Deprecated. Invoking this procedure generates a warning.
Quote possible HTML tags in the contents of the html parameter.
- Parameters:
- html (required)
- See Also:
- ns_quotehtml
- Testcases:
- No testcase defined.
template::util::set_cookie (public, deprecated)
template::util::set_cookie expire_state name value [ domain ]
Deprecated. Invoking this procedure generates a warning.
Create a cookie with specified parameters. The expiration state may be persistent, session, or a number of minutes from the current time.
- Parameters:
- expire_state (required)
- name (required)
- value (required)
- domain (optional)
- See Also:
- Testcases:
- No testcase defined.
template::util::set_param (public, deprecated)
template::util::set_param name value
Deprecated. Invoking this procedure generates a warning.
Set a stored parameter
- Parameters:
- name (required)
- value (required)
- Testcases:
- No testcase defined.
template::util::set_to_list (public, deprecated)
template::util::set_to_list set [ args... ]
Deprecated. Invoking this procedure generates a warning.
Turns an ns_set into a key-value list, excluding any number of specified keys. Useful for turning the contents on an ns_set into a form that may be cached or manipulated as a native Tcl data structure. DEPRECATED: this proc can be replaced with trivial ns_set and plain tcl idioms
- Parameters:
- set (required)
- A reference to an ns_set.
- Returns:
- A list in the form { key value key value key value ... }
- See Also:
- ns_set
- Testcases:
- No testcase defined.
template::util::set_to_vars (public, deprecated)
template::util::set_to_vars set [ args... ]
Deprecated. Invoking this procedure generates a warning.
Declare local variables for set values DEPRECATED: this proc can be replaced with trivial ns_set and plain tcl idioms
- Parameters:
- set (required)
- A reference to an ns_set.
- See Also:
- ns_set
- Testcases:
- No testcase defined.
template::util::tcl_to_sql_list (public, deprecated)
template::util::tcl_to_sql_list lst
Deprecated. Invoking this procedure generates a warning.
Convert a Tcl list to a SQL list, for use with the "in" statement. Uses double single quotes to escape single quotes in values. DEPRECATED: NaviServer now provides a native API ns_dbquotelist for this; a tcl-implemented fallback for older NaviServer versions exists in current OpenACS code.
- Parameters:
- lst (required)
- See Also:
- Testcases:
- No testcase defined.
template::widget::richtext_htmlarea (public, deprecated)
template::widget::richtext_htmlarea element_reference tag_attributes
Deprecated. Invoking this procedure generates a warning.
Implements the richtext widget, which offers rich text editing options. If the acs-templating.UseHtmlAreaForRichtextP parameter is set to true (1), this will use the htmlArea WYSIWYG editor widget. Otherwise, it will use a normal textarea, with a drop-down to select a format. The available formats are:
You can also parameterize the richtext widget with a 'htmlarea_p' attribute, which can be true or false, and which will override the parameter setting.
- Enhanced text = Allows HTML, but automatically inserts line and paragraph breaks.
- Plain text = Automatically inserts line and paragraph breaks, and quotes all HTML-specific characters, such as less-than, greater-than, etc.
- Fixed-width text = Same as plain text, but conserves spacing; useful for tabular data.
- HTML = normal HTML.
- Parameters:
- element_reference (required)
- tag_attributes (required)
- See Also:
- Testcases:
- No testcase defined.