Applies to: String Object
The fixed method places HTML <TT> tags around text in a String object.
Syntax
strVariable.fixed( )
"String Literal".fixed( )
Return value
None
Example
The following example demonstrates how the fixed method works:
<HEAD> <SCRIPT LANGUAGE="JavaScript"> function fixedTag() { var strVariable = "This is a test"; strVariable = strVariable.fixed( ); return strVariable } </SCRIPT></HEAD> <BODY> <P> See how it work in Html <SCRIPT LANGUAGE="JavaScript"> document.write(fixedTag());</SCRIPT> </P> </BODY>
|
To run the code, paste it into JavaScript Editor, save as htm file format and click the Show Internal View button.
See also: String Object methods, String Object properties |