Table of Contents
Introduction
Information Tags
String Tags
Variable Tags
URL Tags
If Tags
Graphics Tags
Database Tags
Programming Tags
Supports System
SSI
htaccess
Image Maps
Appendix
|
<define> ... </define>
|
 |
<define> is defined in the Main RXML parser module.
Defines new tags, container tags or defines.
|
|
Attributes
- container=name
-
Define a new RXML container tag, or override a previous definition.
- name
-
Sets the specified define. Can be inserted later by the
<insert> tag.
- tag
-
Defines a new RXML tag, or overrides a previous definition.
- default_attribute=value
-
Set a default value for an attribute, that will be used when the
attribute is not specified when the defined tag is used.
You can use a few special tokens in the definition of tags and
container tags:
- #args#
- All arguments sent to the tag. Useful when
defining a new tag that is more or less only an alias for an old one.
- &attribute;
- Inserts the value of that attribute.
Example
source code
|
<define container=h1>
<gtext fg=blue #args#><contents></gtext>
</define>
<h1>Hello</h1>
|
 |
|
result
|
|
|
source code
|
<define tag=test default_foo=foo
default_bar=bar>
The test tag: Testing testing.
Foo is &foo;, bar is &bar;
</define>
<test foo=Hello bar=World>
<br><test foo=Hello>
|
 |
|
result
|
The test tag: Testing testing.
Foo is Hello, bar is World
The test tag: Testing testing.
Foo is Hello, bar is bar
|
|
|