[ Table Of Contents | Keyword Index ]

ns_tagelementset(n) 4.99 "NaviServer Built-in Commands"

NAME

ns_tagelementset - Set the value of the value attribute in an HTML element

TABLE OF CONTENTS

    TABLE OF CONTENTS
    SYNOPSIS
    DESCRIPTION
    COMMANDS
    EXAMPLES
    SEE ALSO
    KEYWORDS

SYNOPSIS

ns_tagelementset tagvar attribute value

DESCRIPTION

This command takes a variable name to upvar, tagvar. The variable should exist in the calling environment and should contain an HTML element that has had its closing ">" removed. The string is searched for the attribute attribute, which will be removed if found. A value attribute will be added to the end of the string with value value, which will be surrounded with double quotes. This procedure does not close the tag with a ">".

COMMANDS

ns_tagelementset tagvar attribute value

EXAMPLES

 
   % set tag {<input type="hidden" name="myfield" value="100"}
   <input type="hidden" name="myfield" value="100"

 
   % ns_tagelementset tag value 250
   <input type="hidden" name="myfield"  value="250"

NOTES I believe using "value" as the attribute name in the output instead of the passed in attribute may be a bug.

SEE ALSO

nsd

KEYWORDS

ns_tagelement