Adobe Extending Dreamweaver CS4 Uživatelský manuál Strana 211

  • Stažení
  • Přidat do mých příruček
  • Tisk
  • Strana
    / 387
  • Tabulka s obsahem
  • KNIHY
  • Hodnocené. / 5. Na základě hodnocení zákazníků
Zobrazit stránku 210
205
EXTENDING DREAMWEAVER CS4
Tag libraries and editors
To define tags, Dreamweaver uses a modified version of the VTML file format. The following example demonstrates
all the elements that Dreamweaver must use to define an individual tag:
<tag name="input" bind="value" casesensitive="no" endtag="no">
<tagformat indentcontents="yes" formatcontents="yes" nlbeforetag nlbeforecontents=0
nlaftercontents=0 nlaftertag=1 />
<tagdialog file = "input.HTM"/>
<attributes>
<attrib name="name"/>
<attrib name="wrap" type="Enumerated">
<attriboption value="off"/>
<attriboption value="soft"/>
<attriboption value="hard"/>
/attrib>
<attrib name="onFocus" casesensitive="yes"/>
<event name="onFocus"/>
</attributes>
</tag>
The following table lists the attributes that define tags:
Attribute Description Mandatory/optional
tag.bind Used by the Data Binding panel. When you select
a tag of this type, the
bind attribute indicates the
default attribute for data binding.
Optional
tag.casesensitive Specifies whether the tag name is case-sensitive.
If the tag is case-sensitive, it is inserted into the
user’s document using exactly the case that the
tag library specifies. If the tag is not case-
sensitive, it is inserted using the default case that
is specified in the Code Format tab in the
Preferences dialog box. If
casesensitive is
omitted, the tag is assumed to be
case-insensitive.
Optional
tag.endtag Specifies whether the tag has both an opening
and a closing tag. For example, the
input tag has
no closing tag; there is no matching
/input tag.
If the closing tag is optional, the
ENDTAG attribute
should be set to
Yes.tag. Specify xml to enforce
XML syntax for an empty tag. For example,
<tag
name="foo" endtag="xml"
tagtype="empty">
inserts <foo/>.
Optional
tagformat Specifies the tag’s formatting rules. In
Dreamweaver versions before Dreamweaver MX,
these rules were stored in the SourceFormat.txt
file.
Optional
tagformat.indentcontents Specifies whether the contents of this tag should
be indented.
Optional
tagformat.formatcontents Specifies whether the contents of this tag should
be parsed. This attribute is set to
No for tags such
as
SCRIPT and STYLE, for which content is
something other than HTML.
Optional
tagformat.nlbeforetag Specifies whether to insert a newline character
before this tag. The value
0 indicates no, and the
value
1 indicates yes.
Optional
Zobrazit stránku 210
1 2 ... 206 207 208 209 210 211 212 213 214 215 216 ... 386 387

Komentáře k této Příručce

Žádné komentáře