etp::get_attribute_desc (public)

 etp::get_attribute_desc name content_type

Defined in packages/edit-this-page/tcl/etp-procs.tcl

returns the attribute descriptor for the given attribute. works for extended attributes defined by the given content_type as well as for the standard attributes (title, description, and content). (the documentation for etp_make_content_type explains what's in an attribute descriptor contains)

Parameters:
name (required)
content_type (required)

Partial Call Graph (max 5 caller/called nodes):
%3 etp::get_content_items etp::get_content_items (public) etp::get_attribute_desc etp::get_attribute_desc etp::get_content_items->etp::get_attribute_desc packages/edit-this-page/www/etp-edit.tcl packages/edit-this-page/ www/etp-edit.tcl packages/edit-this-page/www/etp-edit.tcl->etp::get_attribute_desc

Testcases:
No testcase defined.
Source code:
        # check for standard attributes first

        variable standard_attributes

        foreach std_desc $standard_attributes {
            if { $name == [lindex $std_desc 0] } {
                return $std_desc
            }
        }

        variable content_types
        if {[info exists content_types($content_type)]} {
            set extended_attributes $content_types($content_type)
            foreach ext_desc $extended_attributes {
                if { $name == [lindex $ext_desc 0] } {
                    return $ext_desc
                }
            }
        }

        return ""
Generic XQL file:
packages/edit-this-page/tcl/etp-procs.xql

PostgreSQL XQL file:
packages/edit-this-page/tcl/etp-procs-postgresql.xql

Oracle XQL file:
packages/edit-this-page/tcl/etp-procs-oracle.xql

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