tagUrn property
Sets or gets the Uniform Resource Name (URN) specified in the namespace declaration.
This property is not supported for Windows apps using JavaScript.
Syntax
| JavaScript | |
|---|
Property values
Type: String
the URN in the namespace declaration, or the value in Possible Values.
Remarks
To declare the namespace in the document, use the XMLNS attribute of the html element.
Download the HTC for the sample below: simple.htc
Examples
This example uses the values returned by the scopeName and tagUrn properties to create a simple HelloWorld custom tag.
The browser's status bar displays the property values.
Code example: http://samples.msdn.microsoft.com/workshop/samples/author/dhtml/refs/tagUrn.htm
<html xmlns:inetsdk="http://msdn.microsoft.com/workshop"> <style> @media all { InetSDK\:HelloWorld { behavior: url(simple.htc); } } </style> <script type="text/javascript"> function window.onload() { window.status = 'scopeName = ' + hello.scopeName + '; tagUrn = ' + hello.tagUrn; } </script> <body> <InetSDK:HelloWorld ID='hello'></InetSDK:HelloWorld> </body> </html>
An alternative call to the HTC can also be made as an attribute, as shown in the following code example.
<html xmlns:inetsdk="http://msdn.microsoft.com/workshop"> <script type="text/javascript"> function window.onload() { window.status = 'scopeName = ' + hello.scopeName + '; tagUrn = ' + hello.tagUrn; } </script> <body> <InetSDK:HelloWorld ID='hello' style="behavior:url(simple.htc)"></InetSDK:HelloWorld> </body> </html>
See also
- a
- abbr
- acronym
- address
- applet
- area
- article
- aside
- b
- base
- baseFont
- bgSound
- big
- blockQuote
- body
- br
- button
- caption
- center
- cite
- code
- col
- colGroup
- comment
- custom
- dd
- del
- dfn
- dir
- div
- dl
- dt
- em
- embed
- fieldSet
- figcaption
- figure
- font
- footer
- form
- frame
- frameSet
- head
- header
- hgroup
- hn
- hr
- html
- i
- iframe
- img
- input type=button
- input type=checkbox
- input type=email
- input type=file
- input type=hidden
- input type=image
- input type=number
- input type=password
- input type=radio
- input type=range
- input type=reset
- input type=search
- input type=submit
- input type=tel
- input type=text
- input type=url
- ins
- isIndex
- kbd
- label
- legend
- li
- link
- listing
- map
- mark
- marquee
- menu
- nav
- nextID
- noBR
- noFrames
- noScript
- object
- ol
- option
- p
- plainText
- pre
- q
- rt
- ruby
- s
- samp
- script
- section
- select
- small
- span
- strike
- strong
- style
- sub
- sup
- table
- tBody
- td
- textArea
- tFoot
- th
- tHead
- title
- tr
- tt
- u
- ul
- var
- wbr
- xml
- xmp
- Using Custom Tags in Internet Explorer