Offset 1, 3 lines modified | Offset 1, 3 lines modified | ||
1 | ·2e55a02bc6e0210aca06440a22aa0273·58892·debug·optional·htp-dbgsym_1.19-8_i386.deb | 1 | ·2e55a02bc6e0210aca06440a22aa0273·58892·debug·optional·htp-dbgsym_1.19-8_i386.deb |
2 | · | 2 | ·47e30ef812cfac0ae0a0678107dccf12·120460·web·optional·htp_1.19-8_i386.deb |
Offset 1, 3 lines modified | Offset 1, 3 lines modified | ||
1 | -rw-r--r--···0········0········0········4·2020-06-14·23:21:19.000000·debian-binary | 1 | -rw-r--r--···0········0········0········4·2020-06-14·23:21:19.000000·debian-binary |
2 | -rw-r--r--···0········0········0·····36 | 2 | -rw-r--r--···0········0········0·····3620·2020-06-14·23:21:19.000000·control.tar.xz |
3 | -rw-r--r--···0········0········0···116 | 3 | -rw-r--r--···0········0········0···116648·2020-06-14·23:21:19.000000·data.tar.xz |
Offset 1, 12 lines modified | Offset 1, 12 lines modified | ||
1 | Package:·htp | 1 | Package:·htp |
2 | Version:·1.19-8 | 2 | Version:·1.19-8 |
3 | Architecture:·i386 | 3 | Architecture:·i386 |
4 | Maintainer:·Marcelo·Soares·Mota·<motasmarcelo@gmail.com> | 4 | Maintainer:·Marcelo·Soares·Mota·<motasmarcelo@gmail.com> |
5 | Installed-Size:·65 | 5 | Installed-Size:·652 |
6 | Depends:·libc6·(>=·2.34) | 6 | Depends:·libc6·(>=·2.34) |
7 | Section:·web | 7 | Section:·web |
8 | Priority:·optional | 8 | Priority:·optional |
9 | Homepage:·http://htp.sourceforge.net | 9 | Homepage:·http://htp.sourceforge.net |
10 | Description:·nice·HTML·pre-processor | 10 | Description:·nice·HTML·pre-processor |
11 | ·htp·is·an·HTML·pre-processor.·It·is·designed·to·be·a·flexible·authoring·tool | 11 | ·htp·is·an·HTML·pre-processor.·It·is·designed·to·be·a·flexible·authoring·tool |
12 | ·that·can·easily·be·integrated·into·the·HTML·design·process. | 12 | ·that·can·easily·be·integrated·into·the·HTML·design·process. |
Offset 1, 27 lines modified | Offset 1, 27 lines modified | ||
1 | drwxr-xr-x···0·root·········(0)·root·········(0)········0·2020-06-14·23:21:19.000000·./ | 1 | drwxr-xr-x···0·root·········(0)·root·········(0)········0·2020-06-14·23:21:19.000000·./ |
2 | drwxr-xr-x···0·root·········(0)·root·········(0)········0·2020-06-14·23:21:19.000000·./usr/ | 2 | drwxr-xr-x···0·root·········(0)·root·········(0)········0·2020-06-14·23:21:19.000000·./usr/ |
3 | drwxr-xr-x···0·root·········(0)·root·········(0)········0·2020-06-14·23:21:19.000000·./usr/bin/ | 3 | drwxr-xr-x···0·root·········(0)·root·········(0)········0·2020-06-14·23:21:19.000000·./usr/bin/ |
4 | -rwxr-xr-x···0·root·········(0)·root·········(0)····75284·2020-06-14·23:21:19.000000·./usr/bin/htp | 4 | -rwxr-xr-x···0·root·········(0)·root·········(0)····75284·2020-06-14·23:21:19.000000·./usr/bin/htp |
5 | drwxr-xr-x···0·root·········(0)·root·········(0)········0·2020-06-14·23:21:19.000000·./usr/share/ | 5 | drwxr-xr-x···0·root·········(0)·root·········(0)········0·2020-06-14·23:21:19.000000·./usr/share/ |
6 | drwxr-xr-x···0·root·········(0)·root·········(0)········0·2020-06-14·23:21:19.000000·./usr/share/doc/ | 6 | drwxr-xr-x···0·root·········(0)·root·········(0)········0·2020-06-14·23:21:19.000000·./usr/share/doc/ |
7 | drwxr-xr-x···0·root·········(0)·root·········(0)········0·2020-06-14·23:21:19.000000·./usr/share/doc/htp/ | 7 | drwxr-xr-x···0·root·········(0)·root·········(0)········0·2020-06-14·23:21:19.000000·./usr/share/doc/htp/ |
8 | -rw-r--r--···0·root·········(0)·root·········(0)···· | 8 | -rw-r--r--···0·root·········(0)·root·········(0)·····8935·2020-06-14·23:21:19.000000·./usr/share/doc/htp/alttext.html |
9 | -rw-r--r--···0·root·········(0)·root·········(0)·····1418·2020-06-14·23:21:19.000000·./usr/share/doc/htp/alttext.htp | 9 | -rw-r--r--···0·root·········(0)·root·········(0)·····1418·2020-06-14·23:21:19.000000·./usr/share/doc/htp/alttext.htp |
10 | -rw-r--r--···0·root·········(0)·root·········(0)····14129·2020-06-14·23:21:19.000000·./usr/share/doc/htp/block.html | 10 | -rw-r--r--···0·root·········(0)·root·········(0)····14129·2020-06-14·23:21:19.000000·./usr/share/doc/htp/block.html |
11 | -rw-r--r--···0·root·········(0)·root·········(0)······781·2020-06-14·23:21:19.000000·./usr/share/doc/htp/block.htp | 11 | -rw-r--r--···0·root·········(0)·root·········(0)······781·2020-06-14·23:21:19.000000·./usr/share/doc/htp/block.htp |
12 | -rw-r--r--···0·root·········(0)·root·········(0)···· | 12 | -rw-r--r--···0·root·········(0)·root·········(0)·····9493·2020-06-14·23:21:19.000000·./usr/share/doc/htp/blockdef.html |
13 | -rw-r--r--···0·root·········(0)·root·········(0)·····1075·2020-06-14·23:21:19.000000·./usr/share/doc/htp/blockdef.htp | 13 | -rw-r--r--···0·root·········(0)·root·········(0)·····1075·2020-06-14·23:21:19.000000·./usr/share/doc/htp/blockdef.htp |
14 | -rw-r--r--···0·root·········(0)·root·········(0)·····4763·2020-06-14·23:21:19.000000·./usr/share/doc/htp/bugs.html | 14 | -rw-r--r--···0·root·········(0)·root·········(0)·····4763·2020-06-14·23:21:19.000000·./usr/share/doc/htp/bugs.html |
15 | -rw-r--r--···0·root·········(0)·root·········(0)······737·2020-06-14·23:21:19.000000·./usr/share/doc/htp/bugs.htp | 15 | -rw-r--r--···0·root·········(0)·root·········(0)······737·2020-06-14·23:21:19.000000·./usr/share/doc/htp/bugs.htp |
16 | -rw-r--r--···0·root·········(0)·root·········(0)······878·2020-06-14·23:21:19.000000·./usr/share/doc/htp/changelog.Debian.gz | 16 | -rw-r--r--···0·root·········(0)·root·········(0)······878·2020-06-14·23:21:19.000000·./usr/share/doc/htp/changelog.Debian.gz |
17 | -rw-r--r--···0·root·········(0)·root·········(0)···· | 17 | -rw-r--r--···0·root·········(0)·root·········(0)·····9544·2020-06-14·23:21:19.000000·./usr/share/doc/htp/comment.html |
18 | -rw-r--r--···0·root·········(0)·root·········(0)······676·2020-06-14·23:21:19.000000·./usr/share/doc/htp/comment.htp | 18 | -rw-r--r--···0·root·········(0)·root·········(0)······676·2020-06-14·23:21:19.000000·./usr/share/doc/htp/comment.htp |
19 | -rw-r--r--···0·root·········(0)·root·········(0)····13083·2020-06-14·23:16:46.000000·./usr/share/doc/htp/copyright | 19 | -rw-r--r--···0·root·········(0)·root·········(0)····13083·2020-06-14·23:16:46.000000·./usr/share/doc/htp/copyright |
20 | -rw-r--r--···0·root·········(0)·root·········(0)····1 | 20 | -rw-r--r--···0·root·········(0)·root·········(0)····11531·2020-06-14·23:21:19.000000·./usr/share/doc/htp/def.html |
21 | -rw-r--r--···0·root·········(0)·root·········(0)·····3601·2020-06-14·23:21:19.000000·./usr/share/doc/htp/def.htp | 21 | -rw-r--r--···0·root·········(0)·root·········(0)·····3601·2020-06-14·23:21:19.000000·./usr/share/doc/htp/def.htp |
22 | -rw-r--r--···0·root·········(0)·root·········(0)·····8030·2020-06-14·23:21:19.000000·./usr/share/doc/htp/default.html | 22 | -rw-r--r--···0·root·········(0)·root·········(0)·····8030·2020-06-14·23:21:19.000000·./usr/share/doc/htp/default.html |
23 | -rw-r--r--···0·root·········(0)·root·········(0)·····3149·2020-06-14·23:21:19.000000·./usr/share/doc/htp/default.htp | 23 | -rw-r--r--···0·root·········(0)·root·········(0)·····3149·2020-06-14·23:21:19.000000·./usr/share/doc/htp/default.htp |
24 | drwxr-xr-x···0·root·········(0)·root·········(0)········0·2020-06-14·23:21:19.000000·./usr/share/doc/htp/examples/ | 24 | drwxr-xr-x···0·root·········(0)·root·········(0)········0·2020-06-14·23:21:19.000000·./usr/share/doc/htp/examples/ |
25 | -rw-r--r--···0·root·········(0)·root·········(0)······536·2015-05-16·17:04:11.000000·./usr/share/doc/htp/examples/Makefile.sub | 25 | -rw-r--r--···0·root·········(0)·root·········(0)······536·2015-05-16·17:04:11.000000·./usr/share/doc/htp/examples/Makefile.sub |
26 | -rw-r--r--···0·root·········(0)·root·········(0)·····2404·2015-05-16·17:04:11.000000·./usr/share/doc/htp/examples/album.hti | 26 | -rw-r--r--···0·root·········(0)·root·········(0)·····2404·2015-05-16·17:04:11.000000·./usr/share/doc/htp/examples/album.hti |
27 | -rw-r--r--···0·root·········(0)·root·········(0)·····1087·2015-05-16·17:04:11.000000·./usr/share/doc/htp/examples/album.htt | 27 | -rw-r--r--···0·root·········(0)·root·········(0)·····1087·2015-05-16·17:04:11.000000·./usr/share/doc/htp/examples/album.htt |
Offset 114, 68 lines modified | Offset 114, 40 lines modified | ||
114 | ······<a·class="noline"·href="bugs.html">Bugs</a></td></tr> | 114 | ······<a·class="noline"·href="bugs.html">Bugs</a></td></tr> |
115 | ··</table> | 115 | ··</table> |
116 | ··</div> | 116 | ··</div> |
117 | </td> | 117 | </td> |
118 | <td·bgcolor="#f0f0d0"·rowspan="2"·valign="top"> | 118 | <td·bgcolor="#f0f0d0"·rowspan="2"·valign="top"> |
119 | <h2>syntax</h2> | 119 | <h2>syntax</h2> |
120 | ··<p><code> | 120 | ··<p><code> |
121 | ·<span·class="htp-tag"><<a·href="set.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">set</a>·<span·class="htp-attrib">time</span>=<span·class="htp-string">"0"</span>></span><br> | ||
122 | ·<span·class="htp-tag"><<a·href="block.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">block</a>·<span·class="htp-attrib">name</span>=<span·class="htp-value">a</span>></span><br> | ||
123 | 121 | <span·class="htp-tag"><<a·href="if.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">IF</a>·<span·class="ebnf">[</span><span·class="htp-attrib">NOT</span><span·class="ebnf">]</span>·<span·class="htp-attrib">conditional</span>&[·...·truncated·by·diffoscope;·len:·10,·SHA:·9e8ef223149d0770d69b29fa44c8431955f80464ef9389f8dc60852e89aca98d·...·]<br> | |
122 | · ·block·#1<br> | ||
123 | [<br> | ||
124 | <span·class="htp-tag"><ELSEIF·<span·class="ebnf">[</span><span·class="htp-attrib">NOT</span><span·class="ebnf">]</span>·<span·class="htp-attrib">conditional</span>></span><br> | ||
125 | · ·block·#2<br> | ||
126 | ...<br> | ||
127 | ]<br> | ||
128 | [<br> | ||
129 | <span·class="htp-tag"><ELSE></span><br> | ||
130 | · ·block·#3<br> | ||
131 | ]<br> | ||
124 | 132 | <span·class="htp-tag"><<a·href="if.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">/IF</a>></span><br> | |
133 | <br> | ||
125 | ·<span·class="htp-tag"><<a·href="block.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">block</a>·<span·class="htp-attrib">name</span>=<span·class="htp-value">b</span>·<span·class="htp-attrib">expand</span>></span><br> | ||
126 | · ·b·is·expanded·at·time·<span·class="htp-tag"><<a·href="use.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">use</a>·<span·class="htp-attrib">time</span>></span>.<br> | ||
127 | ·<span·class="htp-tag"><<a·href="block.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">/block</a>></span><br> | ||
128 | ·<span·class="htp-tag"><<a·href="set.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">set</a>·<span·class="htp-attrib">time</span>=<span·class="htp-string">"1"</span>></span><br> | ||
129 | ·<span·class="htp-tag"><<a·href="use.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">use</a>·<span·class="htp-attrib">a</span>></span><br> | ||
130 | ·<span·class="htp-tag"><<a·href="use.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">use</a>·<span·class="htp-attrib">b</span>></span><br> | ||
131 | ·contents·of·a:·<span·class="htp-tag"><<a·href="use.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">use</a>·<span·class="htp-attrib">a</span>·<span·class="htp-attrib">noexpand</span>></span><br> | ||
132 | ·contents·of·b:·<span·class="htp-tag"><<a·href="use.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">use</a>·<span·class="htp-attrib">b</span>·<span·class="htp-attrib">noexpand</span>></span><br> | ||
133 | ·<span·class="htp-tag"><<a·href="block.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">block</a>·<span·class="htp-attrib">name</span>=<span·class="htp-value">c</span>·<span·class="htp-attrib">expand</span>></span><br> | ||
134 | · ·c·is·expanded·at·time·<span·class="htp-tag"><<a·href="use.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">use</a>·<span·class="htp-attrib">time</span>></span>;·<span·class="htp-tag"><<a·href="use.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">use</a>·<span·class="htp-attrib">a</span>></span><br> | ||
135 | ·<span·class="htp-tag"><<a·href="block.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">/block</a>></span><br> | ||
136 | ·<span·class="htp-tag"><<a·href="block.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">block</a>·<span·class="htp-attrib">name</span>=<span·class="htp-value">d</span>·<span·class="htp-attrib">expand</span>></span><br> | ||
137 | · ·d·is·expanded·at·time·<span·class="htp-tag"><<a·href="use.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">use</a>·<span·class="htp-attrib">time</span>></span>;·<span·class="htp-tag"><<a·href="use.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">use</a>·<span·class="htp-attrib">a</span>·<span·class="htp-attrib">noexpand</span>></span><br> | ||
138 | ·<span·class="htp-tag"><<a·href="block.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">/block</a>></span><br> | ||
139 | ·<span·class="htp-tag"><<a·href="block.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">block</a>·<span·class="htp-attrib">name</span>=<span·class="htp-value">e</span>></span><br> | ||
140 | · ·e·is·expanded·at·time·<span·class="htp-tag"><<a·href="use.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">use</a>·<span·class="htp-attrib">time</span>></span>;·<span·class="htp-tag"><<a·href="use.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">use</a>·<span·class="htp-attrib">a</span>·<span·class="htp-attrib">noexpand</span>></span><br> | ||
141 | ·<span·class="htp-tag"><<a·href="block.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">/block</a>></span><br> | ||
142 | ·<span·class="htp-tag"><<a·href="set.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">set</a>·<span·class="htp-attrib">time</span>=<span·class="htp-string">"2"</span>></span><br> | ||
143 | ·<span·class="htp-tag"><<a·href="block.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">block</a>·<span·class="htp-attrib">name</span>=<span·class="htp-value">a</span>></span><br> | ||
144 | · ·a·is·defined·for·the·2nd·time·<span·class="htp-tag"><<a·href="use.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">use</a>·<span·class="htp-attrib">time</span>></span>.<br> | ||
145 | ·<span·class="htp-tag"><<a·href="block.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">/block</a>></span><br> | ||
146 | ·<span·class="htp-tag"><<a·href="use.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">use</a>·<span·class="htp-attrib">c</span>></span><br> | ||
147 | ·<span·class="htp-tag"><<a·href="use.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">use</a>·<span·class="htp-attrib">d</span>></span><br> | ||
148 | ·<span·class="htp-tag"><<a·href="use.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">use</a>·<span·class="htp-attrib">e</span>></span><br> | ||
149 | </code></p> | 134 | </code></p> |
150 | <h2>synopsis</h2> | 135 | <h2>synopsis</h2> |
151 | <strong>ALTTEXT</strong>·declares·an·ALT·attribute·for·any·<A | 136 | <strong>ALTTEXT</strong>·declares·an·ALT·attribute·for·any·<A |
152 | HREF="img.html">IMG</A>·tag·with·a·SRC·matching·the·ALTTEXT·NAME. | 137 | HREF="img.html">IMG</A>·tag·with·a·SRC·matching·the·ALTTEXT·NAME. |
153 | Since·relative·paths·can·be·used·to·point·to·the·same·image,·only·the | 138 | Since·relative·paths·can·be·used·to·point·to·the·same·image,·only·the |
154 | filename·is·considered·in·all·comparisons. | 139 | filename·is·considered·in·all·comparisons. |
155 | <p> | 140 | <p> |
156 | When·an·IMG·tag·with·a·matching·source·is·encountered,·htp·will·add·an·ALT | 141 | When·an·IMG·tag·with·a·matching·source·is·encountered,·htp·will·add·an·ALT |
157 | attribute·only·if·one·is·not·already·present.··This·allows·for·ALT·text·to | 142 | attribute·only·if·one·is·not·already·present.··This·allows·for·ALT·text·to |
158 | be·overridden·on·specific·images·and·default·text·on·all·others. | 143 | be·overridden·on·specific·images·and·default·text·on·all·others. |
159 | <p> | 144 | <p> |
160 | For·example: | 145 | For·example: |
161 | ··<p><code> | 146 | ··<p><code> |
162 | <span·class="htp-tag"><<a·href="if.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">IF</a>·<span·class="htp-attrib">[NOT]</span>·<span·class="htp-attrib">conditional</span>></span><br> | ||
163 | · ·block·#1<br> | ||
164 | [<br> | ||
165 | <span·class="htp-tag"><ELSEIF·<span·class="htp-attrib">[NOT]</span>·<span·class="htp-attrib">conditional</span>></span><br> | ||
166 | · ·block·#2<br> | ||
167 | ...<br> | ||
168 | ]<br> | ||
169 | [<br> | ||
170 | <span·class="htp-tag"><ELSE></span><br> | ||
171 | · ·block·#3<br> | ||
172 | ]<br> | ||
173 | <span·class="htp-tag"><<a·href="if.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">/IF</a>></span><br> | ||
174 | <br> | ||
175 | </code></p> | 147 | </code></p> |
176 | <p> | 148 | <p> |
177 | An·ALTTEXT·tag·with·a·name·but·no·text·attribute·removes·any·ALT | 149 | An·ALTTEXT·tag·with·a·name·but·no·text·attribute·removes·any·ALT |
178 | mapping·for·this·image.··Successing·IMG·tags·with·a·matching·SRC·name·are·not | 150 | mapping·for·this·image.··Successing·IMG·tags·with·a·matching·SRC·name·are·not |
179 | changed. | 151 | changed. |
180 | <p> | 152 | <p> |
181 | Since·this·is·useful·for·an·image·used·throughout·a·set·of·documents, | 153 | Since·this·is·useful·for·an·image·used·throughout·a·set·of·documents, |
Offset 1, 68 lines modified | Offset 1, 44 lines modified | ||
1 | [HTP] | 1 | [HTP] |
2 | ******·htp·on-line·reference·:·ALTTEXT·****** | 2 | ******·htp·on-line·reference·:·ALTTEXT·****** |
3 | Table_of·······*****·syntax·***** | 3 | Table_of_Contents············*****·syntax·***** |
4 | Contents······· ·<[[ref]]set·time="0"> | ||
5 | Introduction· ·<[[ref]]block·name=a> | ||
6 | License······ · ·a·is·expanded·at·time·<[[ref]]use·time>. | ||
7 | Tutorial····· ·<[[ref]]/block> | ||
8 | Usage········ ·<[[ref]]block·name=b·expand> | ||
9 | HTP·Tags····· · ·b·is·expanded·at·time·<[[ref]]use·time>. | ||
10 | [>]·ALTTEXT·· ·<[[ref]]/block> | ||
11 | ··BLOCK···· ·<[[ref]]set·time="1"> | ||
12 | ··BLOCKDEF· ·<[[ref]]use·a> | ||
13 | ··DEF······ ·<[[ref]]use·b> | ||
14 | ··FILE····· ·contents·of·a:·<[[ref]]use·a·noexpand> | ||
15 | ··IF······· ·contents·of·b:·<[[ref]]use·b·noexpand> | ||
16 | ··INC······ ·<[[ref]]block·name=c·expand> | ||
17 | ··IMG······ · ·c·is·expanded·at·time·<[[ref]]use·time>;·<[[ref]]use·a> | ||
18 | ··IMAGEURL· ·<[[ref]]/block> | ||
19 | ··OPT······ ·<[[ref]]block·name=d·expand> | ||
20 | ··OUTPUT··· · ·d·is·expanded·at·time·<[[ref]]use·time>;·<[[ref]]use·a·noexpand> | ||
21 | ··QUOTE···· ·<[[ref]]/block> | ||
22 | ··SET······ ·<[[ref]]block·name=e> | ||
23 | ··UNDEF···· · ·e·is·expanded·at·time·<[[ref]]use·time>;·<[[ref]]use·a·noexpand> | ||
24 | ··UNSET···· ·<[[ref]]/block> | ||
25 | ··USE,_$··· ·<[[ref]]set·time="2"> | ||
26 | ··WHILE···· ·<[[ref]]block·name=a> | ||
27 | ··<!---···· · ·a·is·defined·for·the·2nd·time·<[[ref]]use·time>. | ||
28 | History······ ·<[[ref]]/block> | ||
29 | Wish_list···· ·<[[ref]]use·c> | ||
30 | Bugs········· ·<[[ref]]use·d> | ||
31 | ··············· ·<[[ref]]use·e> | ||
32 | ···············*****·synopsis·***** | ||
33 | ···············ALTTEXT·declares·an·ALT·attribute·for·any·IMG·tag·with·a·SRC·matching | ||
34 | ···············the·ALTTEXT·NAME.·Since·relative·paths·can·be·used·to·point·to·the | ||
35 | ···············same·image,·only·the·filename·is·considered·in·all·comparisons. | ||
36 | ···············When·an·IMG·tag·with·a·matching·source·is·encountered,·htp·will·add·an | ||
37 | ···············ALT·attribute·only·if·one·is·not·already·present.·This·allows·for·ALT | ||
38 | ···············text·to·be·overridden·on·specific·images·and·default·text·on·all | ||
39 | ···············others. | ||
40 | ···············For·example: | ||
41 | ···············<[[ref]]IF·[NOT]·conditional> | 4 | Introduction···············<[[ref]]IF·[NOT]·conditional> |
42 | ··············· · ·block·#1 | 5 | License···················· · ·block·#1 |
43 | ···············[ | 6 | Tutorial···················[ |
44 | ···············<ELSEIF·[NOT]·conditional> | 7 | Usage······················<ELSEIF·[NOT]·conditional> |
45 | ··············· · ·block·#2 | 8 | HTP·Tags··················· · ·block·#2 |
46 | ···············... | ||
47 | ···············] | ||
48 | ··············· | 9 | [>]·ALTTEXT················... |
10 | ··BLOCK··················] | ||
11 | ··BLOCKDEF···············[ | ||
49 | ···············<ELSE> | 12 | ··DEF····················<ELSE> |
50 | ··············· · ·block·#3 | 13 | ··FILE··················· · ·block·#3 |
51 | ···············] | 14 | ··IF·····················] |
52 | ···············<[[ref]]/IF> | 15 | ··INC····················<[[ref]]/IF> |
16 | ··IMG | ||
17 | ··IMAGEURL···············*****·synopsis·***** | ||
18 | ··OPT····················ALTTEXT·declares·an·ALT·attribute·for·any·IMG·tag | ||
19 | ··OUTPUT·················with·a·SRC·matching·the·ALTTEXT·NAME.·Since | ||
20 | ··QUOTE··················relative·paths·can·be·used·to·point·to·the·same | ||
21 | ··SET····················image,·only·the·filename·is·considered·in·all | ||
22 | ··UNDEF··················comparisons. | ||
23 | ··UNSET··················When·an·IMG·tag·with·a·matching·source·is | ||
24 | ··USE,_$·················encountered,·htp·will·add·an·ALT·attribute·only·if | ||
25 | ··WHILE··················one·is·not·already·present.·This·allows·for·ALT | ||
26 | ··<!---··················text·to·be·overridden·on·specific·images·and | ||
27 | History····················default·text·on·all·others. | ||
28 | Wish_list··················For·example: | ||
53 | ···············An·ALTTEXT·tag·with·a·name·but·no·text·attribut | 29 | Bugs·······················An·ALTTEXT·tag·with·a·name·but·no·text·attribute |
54 | ···············mapping·for·this·image.·Successing·IMG·tags·with·a·matching·SRC·name | ||
55 | ··············· | 30 | ·····························removes·any·ALT·mapping·for·this·image.·Successing |
31 | ·····························IMG·tags·with·a·matching·SRC·name·are·not·changed. | ||
56 | ···············Since·this·is·useful·for·an·image·used·through | 32 | ·····························Since·this·is·useful·for·an·image·used·throughout |
33 | ·····························a·set·of·documents,·ALTTEXT·is·most·appropriate·in | ||
57 | ··············· | 34 | ·····························an·include_file·or·a·default_file. |
58 | ···············In·addition·to·ALTTEXT,·htp·can·also·automatically | 35 | ·····························In·addition·to·ALTTEXT,·htp·can·also·automatically |
59 | ···············HEIGHT·attributes·to·IMG·tags. | 36 | ·····························add·WIDTH·and·HEIGHT·attributes·to·IMG·tags. |
Offset 114, 43 lines modified | Offset 114, 36 lines modified | ||
114 | ······<a·class="noline"·href="bugs.html">Bugs</a></td></tr> | 114 | ······<a·class="noline"·href="bugs.html">Bugs</a></td></tr> |
115 | ··</table> | 115 | ··</table> |
116 | ··</div> | 116 | ··</div> |
117 | </td> | 117 | </td> |
118 | <td·bgcolor="#f0f0d0"·rowspan="2"·valign="top"> | 118 | <td·bgcolor="#f0f0d0"·rowspan="2"·valign="top"> |
119 | <h2>syntax</h2> | 119 | <h2>syntax</h2> |
120 | ··<p><code> | 120 | ··<p><code> |
121 | <span·class="htp-tag"><<a·href="img.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">img</a>·<span·class="htp-attrib">src</span>=<span·class="htp-string">"filename"</span>·<span·class="htp-attrib">...</span>></span><br> | ||
121 | <span·class="htp-tag"><<a·href="def.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">def</a>·<span·class="htp-attrib">name</span>=<span·class="htp-string">"tagname"</span>·<span·class="ebnf">[</span><span·class="htp-attrib">option</span>=<span·class="htp-string">"option1·<span·class="ebnf">[</span>option2·...<span·class="ebnf">]</span>"</span>·<span·class="ebnf">]</span>·<span·class="ebnf">[</span><span·class="htp-attrib">global</span><span·class="ebnf">]</span>·<span·class="ebnf">[</span><span·class="htp-attrib">expand</span><span·class="ebnf">]</span>></span><br> | ||
122 | <span·class="htp-tag"><<a·href="def.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">/def</a>></span><br> | ||
123 | <br> | 122 | <br> |
123 | text="Company·logo"><br> | ||
124 | ude="includefilename"·[parameters·...]><br> | ||
125 | <span·class="htp-tag"><<a·href="file.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">file</a>·<span·class="htp-attrib">name</span>></span><br> | ||
126 | <span·class="htp-tag"><<a·href="file.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">file</a>·<span·class="ebnf">[</span>·<span·class="htp-attrib">name</span>=<span·class="htp-string">"filename"</span>·<span·class="ebnf">]</span>·<span·class="htp-attrib">size</span><span·class="ebnf">[</span>·=<span·class="htp-value"></span>·<span·class="ebnf">(</span><span·class="htp-attrib">byte</span><span·class="ebnf">|</span><span·class="htp-attrib">kbyte</span><span·class="ebnf">|</span><span·class="htp-attrib">mbyte</span><span·class="ebnf">|</span><span·class="htp-attrib">gbyte</span><span·class="ebnf">)</span>·<span·class="ebnf">]</span>·<span·class="ebnf">[</span><span·class="htp-attrib">precision</span>=<span·class="htp-value">n<span·class="ebnf">]</span></span>></span><br> | ||
127 | <span·class="htp-tag"><<a·href="file.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">file</a>·<span·class="ebnf">[</span>·<span·class="htp-attrib">name</span>=<span·class="htp-string">"filename"</span>·<span·class="ebnf">]</span>·<span·class="htp-attrib">time</span><span·class="ebnf">[</span>·=<span·class="htp-string">"format"</span>·<span·class="ebnf">]</span>></span><br> | ||
128 | <span·class="htp-tag"><<a·href="file.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">file</a>·<span·class="ebnf">[</span>·<span·class="htp-attrib">name</span>=<span·class="htp-string">"filename"</span>·<span·class="ebnf">]</span>·<span·class="htp-attrib">date</span><span·class="ebnf">[</span>·=<span·class="htp-string">"format"</span>·<span·class="ebnf">]</span>></span><br> | ||
129 | <span·class="htp-tag"><<a·href="file.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">file</a>·<span·class="htp-attrib">search</span>=<span·class="htp-string">"searchpath"</span>></span><br> | ||
130 | <span·class="htp-tag"><<a·href="file.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">file</a>·<span·class="htp-attrib">template</span>=<span·class="htp-string">"templatefilename"</span>></span><br> | ||
131 | <br> | 124 | <br> |
125 | ·this·line:·<span·class="htp-tag"><<a·href="img.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">img</a>·<span·class="htp-attrib">src</span>=<span·class="htp-string">"logo.gif"</span>></span><br> | ||
126 | ·becomes·this·after·processing:·<span·class="htp-tag"><<a·href="img.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">img</a>·<span·class="htp-attrib">src</span>=<span·class="htp-string">"logo.gif"</span>·<span·class="htp-attrib">alt</span>=<span·class="htp-string">"Company·logo"</span>></span><br> | ||
127 | <br> | ||
128 | ·this·line:·<span·class="htp-tag"><<a·href="img.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">img</a>·<span·class="htp-attrib">src</span>=<span·class="htp-string">"../image/logo.gif"</span>></span><br> | ||
129 | ·will·also·have·an·ALT·attribute·appended·to·it<br> | ||
130 | <br> | ||
131 | ·this·line:·<span·class="htp-tag"><<a·href="img.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">img</a>·<span·class="htp-attrib">src</span>=<span·class="htp-string">"logo.gif"</span>·<span·class="htp-attrib">alt</span>=<span·class="htp-string">"Click·here·for·more·information!"</span>></span><br> | ||
132 | ·remains·unchanged.<br> | ||
132 | </code></p> | 133 | </code></p> |
133 | <h2>synopsis</h2> | 134 | <h2>synopsis</h2> |
134 | <strong>BLOCKDEF</strong>·creates·block·<A | 135 | <strong>BLOCKDEF</strong>·creates·block·<A |
135 | HREF="metatag.html">metatags</A>,·which·is·a·fancy·way·of·saying·it | 136 | HREF="metatag.html">metatags</A>,·which·is·a·fancy·way·of·saying·it |
136 | creates·new·block·tags.··A·block·tag·is·a·tag·that·takes·a·whole·block | 137 | creates·new·block·tags.··A·block·tag·is·a·tag·that·takes·a·whole·block |
137 | as·additional·parameter.··This·block·is·surrounded·by·<tagname>·and | 138 | as·additional·parameter.··This·block·is·surrounded·by·<tagname>·and |
138 | </tagname>.··The·contents·of·this·block·are·automatically·stored | 139 | </tagname>.··The·contents·of·this·block·are·automatically·stored |
139 | in·the·block·macro·named·BLOCK. | 140 | in·the·block·macro·named·BLOCK. |
140 | <P>·For·example:</P> | 141 | <P>·For·example:</P> |
141 | ··<p><code> | 142 | ··<p><code> |
142 | <span·class="htp-tag"><<a·href="if.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">if</a>·<span·class="htp-attrib">disabled_because_xyz</span>></span><br> | ||
143 | ·...<br> | ||
144 | <span·class="htp-tag"><<a·href="if.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">/if</a>></span><br> | ||
145 | =center><br> | ||
146 | · ·<span·class="htp-tag"><<a·href="def.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">/def</a>></span><br> | ||
147 | <br> | ||
148 | · ·<span·class="htp-tag"><centered></span><br> | ||
149 | · ·This·text·is·centered.<br> | ||
150 | </code></p> | 143 | </code></p> |
151 | <p> | 144 | <p> |
152 | All·block·metatags·have·the·implicit·option·<a | 145 | All·block·metatags·have·the·implicit·option·<a |
153 | href="expand.html">EXPAND</A>,·which·tells·htp·to·expand·the·contents | 146 | href="expand.html">EXPAND</A>,·which·tells·htp·to·expand·the·contents |
154 | of·the·block·before·the·definition·is·expanded. | 147 | of·the·block·before·the·definition·is·expanded. |
155 | </p> | 148 | </p> |
156 | <p> | 149 | <p> |
Offset 1, 50 lines modified | Offset 1, 38 lines modified | ||
1 | [HTP] | 1 | [HTP] |
2 | ******·htp·on-line·reference·:·BLOCKDEF,·/BLOCKDEF·****** | 2 | ******·htp·on-line·reference·:·BLOCKDEF,·/BLOCKDEF·****** |
3 | Table_of | 3 | Table_of·······*****·syntax·***** |
4 | Contents·······<[[ref]]img·src="filename"·...> | ||
5 | Introduction | ||
6 | License······ text="Company·logo"> | ||
7 | Tutorial | ||
8 | Usage········ ·this·line:·<[[ref]]img·src="logo.gif"> | ||
9 | HTP·Tags····· ·becomes·this·after·processing:·<[[ref]]img·src="logo.gif"·alt="Company | ||
10 | ··ALTTEXT··logo"> | ||
11 | ··BLOCK | ||
12 | [>]·BLOCKDEF· ·this·line:·<[[ref]]img·src="../image/logo.gif"> | ||
13 | ··DEF······ ·will·also·have·an·ALT·attribute·appended·to·it | ||
14 | ··FILE | ||
15 | ··IF······· ·this·line:·<[[ref]]img·src="logo.gif"·alt="Click·here·for·more | ||
16 | ··INC······information!"> | ||
17 | ··IMG······ ·remains·unchanged. | ||
18 | ··IMAGEURL·*****·synopsis·***** | ||
4 | Introduction···············<[[ref]]def·name="tagname"·[option="option1 | ||
5 | License····················[option2·...]"·]·[global]·[expand]> | ||
6 | Tutorial···················<[[ref]]/def> | ||
7 | Usage | ||
8 | HTP·Tags···················ude="includefilename"·[parameters·...]> | ||
9 | ··ALTTEXT················<[[ref]]file·name> | ||
10 | ··BLOCK··················<[[ref]]file·[·name="filename"·]·size[·= | ||
11 | [>]·BLOCKDEF···············(byte|kbyte|mbyte|gbyte)·]·[precision=n]> | ||
12 | ··DEF····················<[[ref]]file·[·name="filename"·]·time[·="format" | ||
13 | ··FILE···················]> | ||
14 | ··IF·····················<[[ref]]file·[·name="filename"·]·date[·="format" | ||
15 | ··INC····················]> | ||
16 | ··IMG····················<[[ref]]file·search="searchpath"> | ||
17 | ··IMAGEURL···············<[[ref]]file·template="templatefilename"> | ||
18 | ··OPT | ||
19 | ··OUTPUT·················*****·synopsis·***** | ||
20 | ·· | 19 | ··OPT······BLOCKDEF·creates·block·metatags,·which·is·a·fancy·way·of·saying·it |
20 | ··OUTPUT···creates·new·block·tags.·A·block·tag·is·a·tag·that·takes·a·whole·block·as | ||
21 | ··SET····················way·of·saying·it·creates·new·block·tags.·A·block | ||
22 | ··UNDEF··················tag·is·a·tag·that·takes·a·whole·block·as | ||
23 | ·· | 21 | ··QUOTE····additional·parameter.·This·block·is·surrounded·by·<tagname>·and·</ |
22 | ··SET······tagname>.·The·contents·of·this·block·are·automatically·stored·in·the | ||
23 | ··UNDEF····block·macro·named·BLOCK. | ||
24 | ··UNSET····For·example: | ||
25 | ··USE,_$···All·block·metatags·have·the·implicit·option·EXPAND,·which·tells·htp·to | ||
26 | ··WHILE····expand·the·contents·of·the·block·before·the·definition·is·expanded. | ||
27 | ··<!---····A·more·thorough·discussion·and·more·elaborate·examples·are·discussed·in | ||
28 | History······the·metatag·section. | ||
29 | Wish_list | ||
30 | Bugs | ||
24 | ··USE,_$·················<tagname>·and·</tagname>.·The·contents·of·this | ||
25 | ··WHILE··················block·are·automatically·stored·in·the·block·macro | ||
26 | ··<!---··················named·BLOCK. | ||
27 | History····················For·example: | ||
28 | Wish_list··················<[[ref]]if·disabled_because_xyz> | ||
29 | Bugs······················· ·... | ||
30 | ·····························<[[ref]]/if> | ||
31 | ·····························=center> | ||
32 | ····························· · ·<[[ref]]/def> | ||
33 | ····························· · ·<centered> | ||
34 | ····························· · ·This·text·is·centered. | ||
35 | ·····························All·block·metatags·have·the·implicit·option | ||
36 | ·····························EXPAND,·which·tells·htp·to·expand·the·contents·of | ||
37 | ·····························the·block·before·the·definition·is·expanded. | ||
38 | ·····························A·more·thorough·discussion·and·more·elaborate | ||
39 | ·····························examples·are·discussed·in·the·metatag·section. | ||
Offset 114, 25 lines modified | Offset 114, 24 lines modified | ||
114 | ······<a·class="noline"·href="bugs.html">Bugs</a></td></tr> | 114 | ······<a·class="noline"·href="bugs.html">Bugs</a></td></tr> |
115 | ··</table> | 115 | ··</table> |
116 | ··</div> | 116 | ··</div> |
117 | </td> | 117 | </td> |
118 | <td·bgcolor="#f0f0d0"·rowspan="2"·valign="top"> | 118 | <td·bgcolor="#f0f0d0"·rowspan="2"·valign="top"> |
119 | <h2>syntax</h2> | 119 | <h2>syntax</h2> |
120 | ··<p><code> | 120 | ··<p><code> |
121 | ·<span·class="htp-tag"><<a·href="alttext.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">alttext</a>·<span·class="htp-attrib">name</span>=<span·class="htp-string">"logo.gif"</span>·<span·class="htp-attrib">text</span>=<span·class="htp-string">"Company·logo"</span>></span><br> | ||
121 | <span·class="htp-tag"><<a·href="def.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">def</a>·<span·class="htp-attrib">name</span>=<span·class="htp-string">"tagname"</span>·<span·class="ebnf">[</span><span·class="htp-attrib">option</span>=<span·class="htp-string">"option1·<span·class="ebnf">[</span>option2·...<span·class="ebnf">]</span>"</span>·<span·class="ebnf">]</span>·<span·class="ebnf">[</span><span·class="htp-attrib">global</span><span·class="ebnf">]</span>·<span·class="ebnf">[</span><span·class="htp-attrib">expand</span><span·class="ebnf">]</span>></span><br> | ||
122 | <span·class="htp-tag"><<a·href="def.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">/def</a>></span><br> | ||
123 | <br> | 122 | <br> |
123 | ·this·line:·<span·class="htp-tag"><<a·href="img.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">img</a>·<span·class="htp-attrib">src</span>=<span·class="htp-string">"logo.gif"</span>></span><br> | ||
124 | ·becomes·this·after·processing:·<span·class="htp-tag"><<a·href="img.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">img</a>·<span·class="htp-attrib">src</span>=<span·class="htp-string">"logo.gif"</span>·<span·class="htp-attrib">alt</span>=<span·class="htp-string">"Company·logo"</span>></span><br> | ||
124 | ude="includefilename"·[parameters·...]><br> | ||
125 | <span·class="htp-tag"><<a·href="file.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">file</a>·<span·class="htp-attrib">name</span>></span><br> | ||
126 | <span·class="htp-tag"><<a·href="file.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">file</a>·<span·class="ebnf">[</span>·<span·class="htp-attrib">name</span>=<span·class="htp-string">"filename"</span>·<span·class="ebnf">]</span>·<span·class="htp-attrib">size</span><span·class="ebnf">[</span>·=<span·class="htp-value"></span>·<span·class="ebnf">(</span><span·class="htp-attrib">byte</span><span·class="ebnf">|</span><span·class="htp-attrib">kbyte</span><span·class="ebnf">|</span><span·class="htp-attrib">mbyte</span><span·class="ebnf">|</span><span·class="htp-attrib">gbyte</span><span·class="ebnf">)</span>·<span·class="ebnf">]</span>·<span·class="ebnf">[</span><span·class="htp-attrib">precision</span>=<span·class="htp-value">n<span·class="ebnf">]</span></span>></span><br> | ||
127 | <span·class="htp-tag"><<a·href="file.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">file</a>·<span·class="ebnf">[</span>·<span·class="htp-attrib">name</span>=<span·class="htp-string">"filename"</span>·<span·class="ebnf">]</span>·<span·class="htp-attrib">time</span><span·class="ebnf">[</span>·=<span·class="htp-string">"format"</span>·<span·class="ebnf">]</span>></span><br> | ||
128 | <span·class="htp-tag"><<a·href="file.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">file</a>·<span·class="ebnf">[</span>·<span·class="htp-attrib">name</span>=<span·class="htp-string">"filename"</span>·<span·class="ebnf">]</span>·<span·class="htp-attrib">date</span><span·class="ebnf">[</span>·=<span·class="htp-string">"format"</span>·<span·class="ebnf">]</span>></span><br> | ||
129 | <span·class="htp-tag"><<a·href="file.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">file</a>·<span·class="htp-attrib">search</span>=<span·class="htp-string">"searchpath"</span>></span><br> | ||
130 | <span·class="htp-tag"><<a·href="file.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">file</a>·<span·class="htp-attrib">template</span>=<span·class="htp-string">"templatefilename"</span>></span><br> | ||
131 | <br> | 125 | <br> |
126 | ·this·line:·<span·class="htp-tag"><<a·href="img.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">img</a>·<span·class="htp-attrib">src</span>=<span·class="htp-string">"../image/logo.gif"</span>></span><br> | ||
127 | ·will·also·have·an·ALT·attribute·appended·to·it<br> | ||
128 | <br> | ||
129 | ·this·line:·<span·class="htp-tag"><<a·href="img.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">img</a>·<span·class="htp-attrib">src</span>=<span·class="htp-string">"logo.gif"</span>·<span·class="htp-attrib">alt</span>=<span·class="htp-string">"Click·here·for·more·information!"</span>></span><br> | ||
130 | ·remains·unchanged.<br> | ||
132 | </code></p> | 131 | </code></p> |
133 | <h2>synopsis</h2> | 132 | <h2>synopsis</h2> |
134 | <p> | 133 | <p> |
135 | This·is·a·simple·comment·that·is·not·included·in·the·output.··This·is·useful | 134 | This·is·a·simple·comment·that·is·not·included·in·the·output.··This·is·useful |
136 | when·commenting·metatags,·since·the·metatags·do·not·appear·the·output·either. | 135 | when·commenting·metatags,·since·the·metatags·do·not·appear·the·output·either. |
137 | Example: | 136 | Example: |
138 | </p> | 137 | </p> |
Offset 1, 51 lines modified | Offset 1, 38 lines modified | ||
1 | [HTP] | 1 | [HTP] |
2 | ******·htp·on-line·reference·:·<!---·****** | 2 | ******·htp·on-line·reference·:·<!---·****** |
3 | Table_of | 3 | Table_of·······*****·syntax·***** |
4 | Contents······· ·<[[ref]]alttext·name="logo.gif"·text="Company·logo"> | ||
5 | Introduction | ||
6 | License······ ·this·line:·<[[ref]]img·src="logo.gif"> | ||
7 | Tutorial····· ·becomes·this·after·processing:·<[[ref]]img·src="logo.gif"·alt="Company | ||
8 | Usage········logo"> | ||
9 | HTP·Tags | ||
10 | ··ALTTEXT·· ·this·line:·<[[ref]]img·src="../image/logo.gif"> | ||
11 | ··BLOCK···· ·will·also·have·an·ALT·attribute·appended·to·it | ||
12 | ··BLOCKDEF | ||
13 | ··DEF······ ·this·line:·<[[ref]]img·src="logo.gif"·alt="Click·here·for·more | ||
14 | ··FILE·····information!"> | ||
15 | ··IF······· ·remains·unchanged. | ||
4 | Introduction···············<[[ref]]def·name="tagname"·[option="option1 | ||
5 | License····················[option2·...]"·]·[global]·[expand]> | ||
6 | Tutorial···················<[[ref]]/def> | ||
7 | Usage | ||
8 | HTP·Tags···················ude="includefilename"·[parameters·...]> | ||
9 | ··ALTTEXT················<[[ref]]file·name> | ||
10 | ··BLOCK··················<[[ref]]file·[·name="filename"·]·size[·= | ||
11 | ··BLOCKDEF···············(byte|kbyte|mbyte|gbyte)·]·[precision=n]> | ||
12 | ··DEF····················<[[ref]]file·[·name="filename"·]·time[·="format" | ||
13 | ··FILE···················]> | ||
14 | ··IF·····················<[[ref]]file·[·name="filename"·]·date[·="format" | ||
15 | ··INC····················]> | ||
16 | ··IMG····················<[[ref]]file·search="searchpath"> | ||
17 | ··IMAGEURL···············<[[ref]]file·template="templatefilename"> | ||
18 | ··OPT | ||
19 | ·· | 16 | ··INC······*****·synopsis·***** |
17 | ··IMG······This·is·a·simple·comment·that·is·not·included·in·the·output.·This·is | ||
18 | ··IMAGEURL·useful·when·commenting·metatags,·since·the·metatags·do·not·appear·the | ||
20 | ··QUOTE··················This·is·a·simple·comment·that·is·not·included·in | ||
21 | ··SET····················the·output.·This·is·useful·when·commenting | ||
22 | ··UNDEF··················metatags,·since·the·metatags·do·not·appear·the | ||
23 | ·· | 19 | ··OPT······output·either.·Example: |
20 | ··OUTPUT···Note·that·these·comments·should·not·include·<·or·>,·that·is·you·should | ||
21 | ··QUOTE····not·use·it·to·comment·out·htp·code.·For·that·purpose·use·something·like | ||
22 | ··SET······this: | ||
23 | ··UNDEF···· · ·<[[ref]]SET·emailaddr="jnelson@crl.com"> | ||
24 | ··UNSET····Make·sure·that·the·variable·is·never·defined·and·xyz·should·be·the·reason | ||
25 | ··USE,_$···why·you·don't·want·to·include·this·block | ||
26 | ··WHILE | ||
27 | [>]·<!--- | ||
28 | History | ||
29 | Wish_list | ||
30 | Bugs | ||
24 | ··USE,_$·················Note·that·these·comments·should·not·include·<·or | ||
25 | ··WHILE··················>,·that·is·you·should·not·use·it·to·comment·out | ||
26 | [>]·<!---··················htp·code.·For·that·purpose·use·something·like | ||
27 | History····················this: | ||
28 | Wish_list··················<[[ref]]if·disabled_because_xyz> | ||
29 | Bugs······················· ·... | ||
30 | ·····························<[[ref]]/if> | ||
31 | ·····························=center> | ||
32 | ····························· · ·<[[ref]]/def> | ||
33 | ····························· · ·<centered> | ||
34 | ····························· · ·This·text·is·centered. | ||
35 | ·····························Make·sure·that·the·variable·is·never·defined·and | ||
36 | ·····························xyz·should·be·the·reason·why·you·don't·want·to | ||
37 | ·····························include·this·block | ||
Offset 114, 24 lines modified | Offset 114, 16 lines modified | ||
114 | ······<a·class="noline"·href="bugs.html">Bugs</a></td></tr> | 114 | ······<a·class="noline"·href="bugs.html">Bugs</a></td></tr> |
115 | ··</table> | 115 | ··</table> |
116 | ··</div> | 116 | ··</div> |
117 | </td> | 117 | </td> |
118 | <td·bgcolor="#f0f0d0"·rowspan="2"·valign="top"> | 118 | <td·bgcolor="#f0f0d0"·rowspan="2"·valign="top"> |
119 | <h2>syntax</h2> | 119 | <h2>syntax</h2> |
120 | ··<p><code> | 120 | ··<p><code> |
121 | 121 | <span·class="htp-tag"><<a·href="inc.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">INC</a>·<span·class="htp-attrib">macroname1</span>=<span·class="htp-string">"increment1"</span>·<span·class="ebnf">[</span><span·class="htp-[·...·truncated·by·diffoscope;·len:·220,·SHA:·e5a7c322d181671814f71219bc400fbb8062367de1eb28c68790a00a59fb83ef·...·]</span>></span><br> | |
122 | <br> | 122 | <br> |
123 | ·this·line:·<span·class="htp-tag"><<a·href="img.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">img</a>·<span·class="htp-attrib">src</span>=<span·class="htp-string">"logo.gif"</span>></span><br> | ||
124 | ·becomes·this·after·processing:·<span·class="htp-tag"><<a·href="img.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">img</a>·<span·class="htp-attrib">src</span>=<span·class="htp-string">"logo.gif"</span>·<span·class="htp-attrib">alt</span>=<span·class="htp-string">"Company·logo"</span>></span><br> | ||
125 | <br> | ||
126 | ·this·line:·<span·class="htp-tag"><<a·href="img.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">img</a>·<span·class="htp-attrib">src</span>=<span·class="htp-string">"../image/logo.gif"</span>></span><br> | ||
127 | ·will·also·have·an·ALT·attribute·appended·to·it<br> | ||
128 | <br> | ||
129 | ·this·line:·<span·class="htp-tag"><<a·href="img.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">img</a>·<span·class="htp-attrib">src</span>=<span·class="htp-string">"logo.gif"</span>·<span·class="htp-attrib">alt</span>=<span·class="htp-string">"Click·here·for·more·information!"</span>></span><br> | ||
130 | ·remains·unchanged.<br> | ||
131 | </code></p> | 123 | </code></p> |
132 | <h2>synopsis</h2> | 124 | <h2>synopsis</h2> |
133 | <p> | 125 | <p> |
134 | <strong>DEF</strong>·creates·<a·href="metatag.html">metatags</a>,·which·is·a | 126 | <strong>DEF</strong>·creates·<a·href="metatag.html">metatags</a>,·which·is·a |
135 | fancy·way·of·saying·it·creates·new·tags.··The·mechanism·is·very·similar·to | 127 | fancy·way·of·saying·it·creates·new·tags.··The·mechanism·is·very·similar·to |
136 | <a·href="block.html">BLOCK</a>·macros,·except·that·the·<a·href="use.html">USE</a> | 128 | <a·href="block.html">BLOCK</a>·macros,·except·that·the·<a·href="use.html">USE</a> |
137 | tag·is·not·used·to·expand·them.··Instead,·they·are·expanded·by·their·own·name. | 129 | tag·is·not·used·to·expand·them.··Instead,·they·are·expanded·by·their·own·name. |
Offset 1, 67 lines modified | Offset 1, 61 lines modified | ||
1 | [HTP] | 1 | [HTP] |
2 | ******·htp·on-line·reference·:·DEF,·/DEF·****** | 2 | ******·htp·on-line·reference·:·DEF,·/DEF·****** |
3 | Table_of·······*****·syntax·***** | 3 | Table_of·······*****·syntax·***** |
4 | Contents·······<[[ref]]INC·macroname1="increment1"·[macroname2="increment2"·... | ||
5 | Introduction·]·[GLOBAL]> | ||
6 | License | ||
4 | Contents······· ·<[[ref]]alttext·name="logo.gif"·text="Company·logo"> | ||
5 | Introduction | ||
6 | License······ ·this·line:·<[[ref]]img·src="logo.gif"> | ||
7 | Tutorial····· ·becomes·this·after·processing:·<[[ref]]img·src="logo.gif"·alt="Company | ||
8 | Usage········logo"> | ||
9 | HTP·Tags | ||
10 | ··ALTTEXT·· ·this·line:·<[[ref]]img·src="../image/logo.gif"> | ||
11 | ··BLOCK···· ·will·also·have·an·ALT·attribute·appended·to·it | ||
12 | ··BLOCKDEF | ||
13 | [>]·DEF······ ·this·line:·<[[ref]]img·src="logo.gif"·alt="Click·here·for·more | ||
14 | ··FILE·····information!"> | ||
15 | ··IF······· ·remains·unchanged. | ||
16 | | 7 | Tutorial·····*****·synopsis·***** |
17 | | 8 | Usage········DEF·creates·metatags,·which·is·a·fancy·way·of·saying·it·creates |
18 | ··IMAGEURL·The·mechanism·is·very·similar·to·BLOCK·macros,·except·that·the·USE·tag·is | ||
19 | ··OPT······not·used·to·expand·them.·Instead,·they·are·expanded·by·their·own·name. | ||
20 | | 9 | HTP·Tags·····new·tags.·The·mechanism·is·very·similar·to·BLOCK·macros,·except |
10 | ··ALTTEXT··that·the·USE·tag·is·not·used·to·expand·them.·Instead,·they·are | ||
11 | ··BLOCK····expanded·by·their·own·name.·For·example: | ||
21 | ·· | 12 | ··BLOCKDEF·Some·metatags·will·require·an·opening·and·closing·tag·(comparable |
13 | [>]·DEF······to | ||
22 | ·· | 14 | ··FILE·····and |
23 | ·· | 15 | ··IF·······).·In·this·case,·you·should·use·the·BLOCKDEF·macro.·Another |
24 | ·· | 16 | ··INC······slightly·faster·alternative·is·to·use·two·metatags,·the·opening |
25 | ·· | 17 | ··IMG······tag·and·the·closing·tag·with·a·preceding·slash.·For·example: |
26 | ··WHILE····<[[ref]]OUTPUT·FILE="outputfilename"·[APPEND]·[EXPAND]> | ||
27 | ··<!---····text·block | ||
28 | History······<[[ref]]/OUTPUT> | ||
29 | Wish_list | ||
30 | | 18 | ··IMAGEURL·You·should·really·use·BLOCKDEF,·though,·as·it·will·check·for |
31 | ········ | 19 | ··OPT······matching·end·tag.·It·is·not·that·slower. |
32 | 20 | ··OUTPUT···Options·can·be·passed·to·a·metatag,·which·can·then·expand·as·if | |
33 | ···············SET·macro.·Option·names·are·parameterized·with·the·OPTION·attribute. | ||
34 | ···············Multiple·options·can·be·listed·by·separating·their·name·with·a·space | ||
35 | ···············(which·therefore·requires·they·be·surrounded·by·quotes.) | ||
36 | ···············<[[ref]]UNDEF·tagname> | ||
37 | ···············<[[ref]]UNDEF·tagname1·tagname2·...·> | ||
21 | ··QUOTE····it·were·a·SET·macro.·Option·names·are·parameterized·with·the | ||
22 | ··SET······OPTION·attribute.·Multiple·options·can·be·listed·by·separating | ||
23 | ··UNDEF····their·name·with·a·space·(which·therefore·requires·they·be | ||
24 | ··UNSET····surrounded·by·quotes.) | ||
25 | ··USE,_$··· ·<[[ref]]def·name="sharedimg"·option="name·alt"> | ||
26 | ··WHILE···· · ·<[[ref]]img·src="/home/sharedimages/${name}"·alt="${alt}">; | ||
27 | ··<!---···· ·<[[ref]]/def> | ||
28 | History | ||
29 | Wish_list···· ·<sharedimg·name="bubble.gif"·alt="Bubble·image"> | ||
38 | 30 | Bugs·········htp·will·do·very·specific·checking·of·parameters·when·a·metatag | |
39 | ···············invoked.·htp·assumes·that·all·parameter·options·to·the·metatag | 31 | ···············is·invoked.·htp·assumes·that·all·parameter·options·to·the·metatag |
40 | ···············optional.·This·is·why·the·HEADERIMG·definition·uses·IF·to | 32 | ···············are·optional.·This·is·why·the·HEADERIMG·definition·uses·IF·to |
41 | ···············option·is·defined·before·expanding·it·in·the·block.·If·a·parameter·is | ||
42 | ···············required,·simply·expand·it·without·first·checking.·When·htp·expands·the | ||
43 | ··············· | 33 | ···············verify·the·SIZE·option·is·defined·before·expanding·it·in·the |
34 | ···············block.·If·a·parameter·is·required,·simply·expand·it·without·first | ||
35 | ···············checking.·When·htp·expands·the·metatag·and·the·macro·is·not | ||
36 | ···············defined,·it·will·halt·processing·and·complain·with·an·error | ||
44 | ··············· | 37 | ···············message·and·the·required·macro·name.·Normally·htp·will·not·allow |
45 | ··············· | 38 | ···············parameters·not·listed·in·the·OPTION·attribute·to·be·added·to·the |
46 | ···············t | 39 | ···············tag.·This·is·why·the·third·invocation·of·HEADERIMG·will·fail. |
47 | ···············There·is·no·ALT·parameter·specified·in·the·OPTION·attribute. | 40 | ···············There·is·no·ALT·parameter·specified·in·the·OPTION·attribute. |
48 | ···············there·is·the·special·option·*,·which·matches·every·oth | 41 | ···············However,·there·is·the·special·option·*,·which·matches·every·other |
49 | ···············should·be·used·to·pass·all·other·options·to·another | 42 | ···············parameter.·It·should·be·used·to·pass·all·other·options·to·another |
43 | ···············tag. | ||
50 | ···············Metatags·can·be·removed·by·using·the·UNDEF·tag.·Note·that·both | 44 | ···············Metatags·can·be·removed·by·using·the·UNDEF·tag.·Note·that·both |
51 | ···············close·tags·must·be·removed·with·UNDEF.·Removing·one·will | 45 | ···············open·and·close·tags·must·be·removed·with·UNDEF.·Removing·one·will |
46 | ···············not·remove·both. | ||
52 | ···············Warning:·Although·possible,·def·should·not·be·used·to·override | 47 | ···············Warning:·Although·possible,·def·should·not·be·used·to·override |
53 | ···············HTML·and·htp·tag·names,·as·this·can·cause·much·confusio | 48 | ···············standard·HTML·and·htp·tag·names,·as·this·can·cause·much·confusion |
54 | ···············results.·The·def·tag·can·even·be·used·to·overrid | 49 | ···············and·unexpected·results.·The·def·tag·can·even·be·used·to·override |
55 | ···············Because·of·the·problems·this·can·cause,·its | 50 | ···············its·own·tag·name.·Because·of·the·problems·this·can·cause,·its |
56 | ···············override·known·tag·names. | 51 | ···············highly·recommended·to·not·override·known·tag·names. |
57 | ···············You·can·find·some·other·examples·in·the·[[ref]]metatag·section·of | 52 | ···············You·can·find·some·other·examples·in·the·[[ref]]metatag·section·of |
58 | ···············tutorial. | 53 | ···············the·tutorial. |
Offset 98, 25 lines modified | Offset 98, 30 lines modified | ||
98 | <p>However,·if·the·block·tag·is·marked·with·the·<code>expand</code> | 98 | <p>However,·if·the·block·tag·is·marked·with·the·<code>expand</code> |
99 | modifier·it·is·expanded·immediately.··This·is·useful·if·you·want·to | 99 | modifier·it·is·expanded·immediately.··This·is·useful·if·you·want·to |
100 | store·something·in·a·block·macro,·that·depends·on·the·current·value·of | 100 | store·something·in·a·block·macro,·that·depends·on·the·current·value·of |
101 | another·macro.··This·other·macro·may·no·longer·have·the·correct·value | 101 | another·macro.··This·other·macro·may·no·longer·have·the·correct·value |
102 | when·the·macro·is·expanded.··Here·is·some·code·that·demonstrate·when | 102 | when·the·macro·is·expanded.··Here·is·some·code·that·demonstrate·when |
103 | the·htp·tags·are·expanded:·</P> | 103 | the·htp·tags·are·expanded:·</P> |
104 | ··<p><code> | 104 | ··<p><code> |
105 | <font·size="-2"> 1.·</font> <span·class="htp-tag"><<a·href="def.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">def</a>·<span·class="htp-attrib">name</span>=<span·class="htp-string">"imghr"</span>></span><br> | ||
106 | <font·size="-2"> 2.·</font> · <span·class="htp-tag"><table·<span·class="htp-attrib">border</span>=<span·class="htp-string">"0"</span>·<span·class="htp-attrib">cellspacing</span>=<span·class="htp-string">"0"</span>·<span·class="htp-attrib">cellpadding</span>=<span·class="htp-string">"0"</span>></span><br> | ||
107 | <font·size="-2"> 3.·</font> · <span·class="htp-tag"><tr></span><br> | ||
108 | <font·size="-2"> 4.·</font> · ·<span·class="htp-tag"><td·<span·class="htp-attrib">width</span>=<span·class="htp-value">10</span>></span><span·class="htp-tag"><<a·href="img.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">img</a>·<span·class="htp-attrib">src</span>=<span·class="htp-string">"leftsep.png"</span>></span><span·class="htp-tag"></td></span><br> | ||
109 | <font·size="-2"> 5.·</font> · ·<span·class="htp-tag"><td·<span·class="htp-attrib">width</span>=<span·class="htp-string">"95%"</span>·<span·class="htp-attrib">background</span>=<span·class="htp-string">"midsep.png"</span>></span>&nbsp;<span·class="htp-tag"></td></span><br> | ||
110 | <font·size="-2"> 6.·</font> · ·<span·class="htp-tag"><td·<span·class="htp-attrib">width</span>=<span·class="htp-value">10</span>></span><span·class="htp-tag"><<a·href="img.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">img</a>·<span·class="htp-attrib">src</span>=<span·class="htp-string">"rightsep.png"</span>></span><span·class="htp-tag"></td></span><br> | ||
111 | <font·size="-2"> 7.·</font> · <span·class="htp-tag"></tr></span><br> | ||
112 | <font·size="-2"> 8.·</font> · <span·class="htp-tag"></table></span><br> | ||
113 | <font·size="-2"> 9.·</font> <span·class="htp-tag"><<a·href="def.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">/def</a>></span><br> | ||
114 | <font·size="-2">10.·</font><br> | ||
115 | <font·size="-2">11.·</font> paragraph<br> | ||
116 | <font·size="-2">12.·</font> <span·class="htp-tag"><imghr></span><br> | ||
117 | <font·size="-2">13.·</font> paragraph<br> | ||
105 | </code></p> | 118 | </code></p> |
106 | This·produces·the·following: | 119 | This·produces·the·following: |
107 | ··<p><code> | 120 | ··<p><code> |
108 | <span·class="htp-tag"><<a·href="if.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">if</a>·<span·class="htp-attrib">disabled_because_xyz</span>></span><br> | ||
109 | ·...<br> | ||
110 | <span·class="htp-tag"><<a·href="if.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">/if</a>></span><br> | ||
111 | =center><br> | ||
112 | · ·<span·class="htp-tag"><<a·href="def.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">/def</a>></span><br> | ||
113 | <br> | ||
114 | · ·<span·class="htp-tag"><centered></span><br> | ||
115 | · ·This·text·is·centered.<br> | ||
116 | </code></p> | 121 | </code></p> |
117 | <P> | 122 | <P> |
118 | When·block·a·and·block·b·are·defined·in·lines·2-7·the·contents·of·a | 123 | When·block·a·and·block·b·are·defined·in·lines·2-7·the·contents·of·a |
119 | are·taken·literally,·however,·the·contents·for·b·are·already·expanded | 124 | are·taken·literally,·however,·the·contents·for·b·are·already·expanded |
120 | so·the·macro·<code>time</code>·is·evaluated.··So·a·is·expanded·when·it | 125 | so·the·macro·<code>time</code>·is·evaluated.··So·a·is·expanded·when·it |
121 | is·used,·while·the·contents·of·b·are·already·expanded. | 126 | is·used,·while·the·contents·of·b·are·already·expanded. |
122 | </P> | 127 | </P> |
Offset 1, 80 lines modified | Offset 1, 79 lines modified | ||
1 | [HTP] | 1 | [HTP] |
2 | ******·htp·on-line·reference·:·global·and·expand·****** | 2 | ******·htp·on-line·reference·:·global·and·expand·****** |
3 | Table_of | 3 | Table_of·········*****·The·global·attribute·***** |
4 | 4 | Contents·········Normally·when·you·define·a·macro·it·is·only·defined·in·the | |
5 | Introduction···current·scope.·A·scope·is·for·example·the·definition·of·a | ||
5 | License····················defined·in·the·current·scope.·A·scope·is·for | ||
6 | Tutorial···················example·the·definition·of·a·metatag.·Once·the | ||
7 | | 6 | License········metatag.·Once·the·definition·is·expanded·and·the·metatag·has |
8 | | 7 | Tutorial·······finished·the·macro·is·automatically·removed.·In·some·cases |
8 | Usage··········you·want·to·define·a·macro·inside·a·metatag·and·use·it·later. | ||
9 | ··Command-···You·can·do·this·with·the·global·attribute·that·you·can·add·to | ||
10 | ······line·······[[ref]]set,·[[ref]]inc,·[[ref]]block,·[[ref]]def,·and·[ | ||
11 | ··Options····[ref]]blockdef·tags. | ||
12 | ··Predefined·*****·The·expand·attribute·***** | ||
9 | ··Options················some·cases·you·want·to·define·a·macro·inside·a | ||
10 | ··Predefined_macros······metatag·and·use·it·later.·You·can·do·this·with·the | ||
11 | [>]·global_and_expand······global·attribute·that·you·can·add·to·[[ref]]set,·[ | ||
12 | HTP_Tags···················[ref]]inc,·[[ref]]block,·[[ref]]def,·and·[ | ||
13 | History····················[ref]]blockdef·tags. | ||
14 | Wish_list··················*****·The·expand·attribute·***** | ||
15 | 13 | ······macros·····The·expand·attribute·is·not·a·tag·of·its·own·but·is·an | |
14 | [>]·global_and·attribute·of·all·block·tags·even·metatags·defined·with·the | ||
15 | ······expand·····blockdef·macro.·Normally·htp·uses·a·lazy·evaluation·strategy, | ||
16 | HTP_Tags·······i.e.·it·expands·htp·tags,·metatags·and·macros·when·the·HTML | ||
16 | ·····························is·an·attribute·of·all·block·tags·even·metatags | ||
17 | ·····························defined·with·the·blockdef·macro.·Normally·htp·uses | ||
18 | ·····························a·lazy·evaluation·strategy,·i.e.·it·expands·htp | ||
19 | ·····························tags,·metatags·and·macros·when·the·HTML·document | ||
20 | 17 | History········document·is·written·not·when·they're·stored·into·block | |
18 | Wish_list······macros.·When·you·use·a·macro·defined·with·the·blockdef·tag | ||
19 | Bugs···········the·html·code·between·the·tags·is·just·copied·literally·into | ||
21 | ·····························macros.·When·you·use·a·macro·defined·with·the | ||
22 | ·····························blockdef·tag·the·html·code·between·the·tags·is | ||
23 | ·····························just·copied·literally·into·the·macro·named·block, | ||
24 | ··················· | 20 | ·················the·macro·named·block,·without·any·expansion·going·on. |
25 | ················· | 21 | ·················However,·if·the·block·tag·is·marked·with·the·expand·modifier |
22 | ·················it·is·expanded·immediately.·This·is·useful·if·you·want·to | ||
26 | ·····························expand·modifier·it·is·expanded·immediately.·This | ||
27 | ·····························is·useful·if·you·want·to·store·something·in·a | ||
28 | ·················· | 23 | ·················store·something·in·a·block·macro,·that·depends·on·the·current |
29 | ················· | 24 | ·················value·of·another·macro.·This·other·macro·may·no·longer·have |
30 | ················· | 25 | ·················the·correct·value·when·the·macro·is·expanded.·Here·is·some |
31 | ················· | 26 | ·················code·that·demonstrate·when·the·htp·tags·are·expanded: |
32 | ················· | 27 | ················· 1. <[[ref]]def·name="imghr"> |
28 | ················· 2. · <table·border="0"·cellspacing="0"·cellpadding="0"> | ||
29 | ················· 3. · <tr> | ||
30 | ················· 4. · ·<td·width=10><[[ref]]img·src="leftsep.png"></td> | ||
31 | ················· 5. · ·<td·width="95%"·background="midsep.png"> </td> | ||
32 | ················· 6. · ·<td·width=10><[[ref]]img·src="rightsep.png"></td> | ||
33 | ················· 7. · </tr> | ||
34 | ················· 8. · </table> | ||
35 | ················· 9. <[[ref]]/def> | ||
36 | ·················10. | ||
37 | ·················11. paragraph | ||
38 | ·················12. <imghr> | ||
39 | ·················13. paragraph | ||
33 | ················· | 40 | ·················This·produces·the·following: |
34 | ·····························<[[ref]]if·disabled_because_xyz> | ||
35 | ····························· ·... | ||
36 | ·····························<[[ref]]/if> | ||
37 | ·····························=center> | ||
38 | ··················· | 41 | ·················When·block·a·and·block·b·are·defined·in·lines·2-7·the |
42 | ·················contents·of·a·are·taken·literally,·however,·the·contents·for | ||
43 | ·················b·are·already·expanded·so·the·macro·time·is·evaluated.·So·a | ||
44 | ·················is·expanded·when·it·is·used,·while·the·contents·of·b·are | ||
45 | ·················already·expanded. | ||
46 | ·················In·line·10·and·12·the·[[ref]]use·tag·is·used·with·the | ||
47 | ·················noexpand·attribute·which·prevents·the·expansion·of·the·macro | ||
48 | ·················value.·Here·it·is·used·to·show·you·what·the·value·of·the | ||
49 | ·················block·macros·really·is. | ||
50 | ·················A·more·important·reason·to·use·the·noexpand·attribute·is·to | ||
51 | ·················prevent·double·expansion·and·to·restore·the·original·lazy | ||
52 | ·················expansion·policy·when·you·have·to·use·the·expand·attribute·as | ||
53 | ·················for·block·d·in·the·example·above.·See·the·section·example·in | ||
54 | ·················the·[[ref]]metatag_tutorial.·Rule·of·thumb:·The·use·tags·in | ||
55 | ·················an·expanded·block·should·be·tagged·with·noexpand. | ||
39 | ····························· · ·<centered> | ||
40 | ····························· · ·This·text·is·centered. | ||
41 | ·····························When·block·a·and·block·b·are·defined·in·lines·2- | ||
42 | ·····························7·the·contents·of·a·are·taken·literally,·however, | ||
43 | ·····························the·contents·for·b·are·already·expanded·so·the | ||
44 | ·····························macro·time·is·evaluated.·So·a·is·expanded·when·it | ||
45 | ·····························is·used,·while·the·contents·of·b·are·already | ||
46 | ·····························expanded. | ||
47 | ·····························In·line·10·and·12·the·[[ref]]use·tag·is·used·with | ||
48 | ·····························the·noexpand·attribute·which·prevents·the | ||
49 | ·····························expansion·of·the·macro·value.·Here·it·is·used·to | ||
50 | ·····························show·you·what·the·value·of·the·block·macros·really | ||
51 | ·····························is. | ||
52 | ·····························A·more·important·reason·to·use·the·noexpand | ||
53 | ·····························attribute·is·to·prevent·double·expansion·and·to | ||
54 | ·····························restore·the·original·lazy·expansion·policy·when | ||
55 | ·····························you·have·to·use·the·expand·attribute·as·for·block | ||
56 | ·····························d·in·the·example·above.·See·the·section·example·in | ||
57 | ·····························the·[[ref]]metatag_tutorial.·Rule·of·thumb:·The | ||
58 | ·····························use·tags·in·an·expanded·block·should·be·tagged | ||
59 | ·····························with·noexpand. | ||
60 | page_source | 56 | page_source |
61 | htp_project | 57 | htp_project |
62 | htp_homepage | 58 | htp_homepage |
63 | hosted·by | 59 | hosted·by |
64 | Sourceforge | 60 | Sourceforge |
65 | HTML·coding | 61 | HTML·coding |
62 | [Powered_by | ||
66 | htp] | 63 | htp] |
67 | ·····htp·on-line·reference·/·http://htp.sourceforge.net/ref/ | 64 | ·····htp·on-line·reference·/·http://htp.sourceforge.net/ref/ |
68 | ·····Authors:·Jim·Nelson,·Jochen_Hoenicke,·Michael_Möller. | 65 | ·····Authors:·Jim·Nelson,·Jochen_Hoenicke,·Michael_Möller. |
69 | ·····Maintainers:·Jochen_Hoenicke. | 66 | ·····Maintainers:·Jochen_Hoenicke. |
70 | Copyright·©·1995–96·Jim·Nelson. | 67 | Copyright·©·1995–96·Jim·Nelson. |
71 | Copyright·©·2001–2014·Jochen_Hoenicke. | 68 | Copyright·©·2001–2014·Jochen_Hoenicke. |
72 | Permission·to·reproduce·and·distribute·this·hypertext·document·granted | 69 | Permission·to·reproduce·and·distribute·this·hypertext·document·granted |
Offset 114, 46 lines modified | Offset 114, 54 lines modified | ||
114 | ······<a·class="noline"·href="bugs.html">Bugs</a></td></tr> | 114 | ······<a·class="noline"·href="bugs.html">Bugs</a></td></tr> |
115 | ··</table> | 115 | ··</table> |
116 | ··</div> | 116 | ··</div> |
117 | </td> | 117 | </td> |
118 | <td·bgcolor="#f0f0d0"·rowspan="2"·valign="top"> | 118 | <td·bgcolor="#f0f0d0"·rowspan="2"·valign="top"> |
119 | <h2>syntax</h2> | 119 | <h2>syntax</h2> |
120 | ··<p><code> | 120 | ··<p><code> |
121 | <span·class="htp-tag"><<a·href="def.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">def</a>·<span·class="htp-attrib">name</span>=<span·class="htp-string">"imghr"</span>></span><br> | ||
122 | · <span·class="htp-tag"><table·<span·class="htp-attrib">border</span>=<span·class="htp-string">"0"</span>·<span·class="htp-attrib">cellspacing</span>=<span·class="htp-string">"0"</span>·<span·class="htp-attrib">cellpadding</span>=<span·class="htp-string">"0"</span>></span><br> | ||
123 | · <span·class="htp-tag"><tr></span><br> | ||
124 | · ·<span·class="htp-tag"><td·<span·class="htp-attrib">width</span>=<span·class="htp-value">10</span>></span><span·class="htp-tag"><<a·href="img.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">img</a>·<span·class="htp-attrib">src</span>=<span·class="htp-string">"leftsep.png"</span>></span><span·class="htp-tag"></td></span><br> | ||
125 | · ·<span·class="htp-tag"><td·<span·class="htp-attrib">width</span>=<span·class="htp-string">"95%"</span>·<span·class="htp-attrib">background</span>=<span·class="htp-string">"midsep.png"</span>></span>&nbsp;<span·class="htp-tag"></td></span><br> | ||
126 | · ·<span·class="htp-tag"><td·<span·class="htp-attrib">width</span>=<span·class="htp-value">10</span>></span><span·class="htp-tag"><<a·href="img.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">img</a>·<span·class="htp-attrib">src</span>=<span·class="htp-string">"rightsep.png"</span>></span><span·class="htp-tag"></td></span><br> | ||
127 | · <span·class="htp-tag"></tr></span><br> | ||
128 | · <span·class="htp-tag"></table></span><br> | ||
129 | <span·class="htp-tag"><<a·href="def.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">/def</a>></span><br> | ||
130 | <br> | ||
131 | paragraph<br> | ||
132 | <span·class="htp-tag"><imghr></span><br> | ||
133 | paragraph<br> | ||
121 | </code></p> | 134 | </code></p> |
122 | <h2>synopsis</h2> | 135 | <h2>synopsis</h2> |
123 | <STRONG>FILE</STRONG>·has·several·optional·parameters·of·differing·purpose. | 136 | <STRONG>FILE</STRONG>·has·several·optional·parameters·of·differing·purpose. |
124 | The·output·file's·name,·the·current·date·and·time,·and·the·contents·of | 137 | The·output·file's·name,·the·current·date·and·time,·and·the·contents·of |
125 | another·file·may·be·included.··Another·file's·time,·date,·or·size·may·be | 138 | another·file·may·be·included.··Another·file's·time,·date,·or·size·may·be |
126 | added·to·the·output·file·as·well. | 139 | added·to·the·output·file·as·well. |
127 | <P> | 140 | <P> |
128 | As·with·all·HTML,·these·tags·do·not·have·to·be·on·their·own·line,·so·the | 141 | As·with·all·HTML,·these·tags·do·not·have·to·be·on·their·own·line,·so·the |
129 | following·is·perfectly·acceptable: | 142 | following·is·perfectly·acceptable: |
130 | ··<p><code> | 143 | ··<p><code> |
131 | · ·<span·class="htp-tag"><<a·href="inc.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">INC</a>·<span·class="htp-attrib">i</span>=<span·class="htp-string">"1"</span>·<span·class="htp-attrib">j</span>=<span·class="htp-string">"-1"</span>></span><br> | ||
132 | </code></p> | 144 | </code></p> |
133 | <P> | 145 | <P> |
134 | <h3><a·name="name">NAME</a>,·TIME,·SIZE</h3> | 146 | <h3><a·name="name">NAME</a>,·TIME,·SIZE</h3> |
135 | <P> | 147 | <P> |
136 | To·include·information·about·another·file,·such·as·an·archive·file·or | 148 | To·include·information·about·another·file,·such·as·an·archive·file·or |
137 | graphic·image,·specify·its·name·with·the·NAME·attribute·followed·by·the | 149 | graphic·image,·specify·its·name·with·the·NAME·attribute·followed·by·the |
138 | type·of·information·to·be·displayed: | 150 | type·of·information·to·be·displayed: |
139 | ··<p><code> | 151 | ··<p><code> |
152 | <span·class="htp-tag"><<a·href="block.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">block</a>·<span·class="htp-attrib">stuff</span>></span><br> | ||
153 | ·<span·class="htp-tag"><a·<span·class="htp-attrib">href</span>=<span·class="htp-value"><span·class="htp-macro">$email</span></span>></span>send·email<span·class="htp-tag"></a></span><br> | ||
140 | · ·<span·class="htp-tag"><<a·href="if.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">IF</a>·<span·class="htp-attrib">name</span>=<span·class="htp-string">"Jim"</span>></span>...<span·class="htp-tag"><<a·href="if.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">/IF</a>></span><br> | ||
141 | e·border="0"·cellspacing="0"·cellpadding="0"><br> | ||
142 | · <span·class="htp-tag"><tr></span><br> | ||
143 | · ·<span·class="htp-tag"><td·<span·class="htp-attrib">width</span>=<span·class="htp-value">10</span>></span><span·class="htp-tag"><<a·href="img.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">img</a>·<span·class="htp-attrib">src</span>=<span·class="htp-string">"leftsep.png"</span>></span><span·class="htp-tag"></td></span><br> | ||
144 | · ·<span·class="htp-tag"><td·<span·class="htp-attrib">width</span>=<span·class="htp-string">"95%"</span>·<span·class="htp-attrib">background</span>=<span·class="htp-string">"midsep.png"</span>></span>&nbsp;<span·class="htp-tag"></td></span><br> | ||
145 | · ·<span·class="htp-tag"><td·<span·class="htp-attrib">width</span>=<span·class="htp-value">10</span>></span><span·class="htp-tag"><<a·href="img.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">img</a>·<span·class="htp-attrib">src</span>=<span·class="htp-string">"rightsep.png"</span>></span><span·class="htp-tag"></td></span><br> | ||
146 | · <span·class="htp-tag"></tr></span><br> | ||
147 | · <span·class="htp-tag"></table></span><br> | ||
148 | 154 | <span·class="htp-tag"><<a·href="block.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">/block</a>></span><br> | |
149 | <br> | 155 | <br> |
150 | paragraph<br> | ||
151 | <span·class="htp-tag"><imghr></span><br> | ||
152 | 156 | <span·class="htp-tag"><<a·href="set.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">set</a>·<span·class="htp-attrib">morestuff</span>=<span·class="htp-value"><span·class="htp-macro">$email</span></span>></span><br> | |
157 | <br> | ||
158 | This·works:· · ·<span·class="htp-tag"><<a·href="use.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">use</a>·<span·class="htp-attrib">stuff</span>·<span·class="htp-attrib">email</span>=<span·class="htp-string">"jnelson@crl.com"</span>></span><br> | ||
159 | But·this·fails:·<span·class="htp-tag"><<a·href="use.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">use</a>·<span·class="htp-attrib">email</span>></span><br> | ||
160 | And·this·fails:·<span·class="htp-tag"><<a·href="use.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">use</a>·<span·class="htp-attrib">morestuff</span>·<span·class="htp-attrib">email</span>=<span·class="htp-string">"jnelson@crl.com"</span>></span><br> | ||
153 | </code></p> | 161 | </code></p> |
154 | <P> | 162 | <P> |
155 | For·file·size·information,·the·value·BYTE,·KBYTE,·etc.·dictates·how·the | 163 | For·file·size·information,·the·value·BYTE,·KBYTE,·etc.·dictates·how·the |
156 | information·is·displayed.··In·anything·other·than·byte·format,·the·information | 164 | information·is·displayed.··In·anything·other·than·byte·format,·the·information |
157 | is·displayed·in·floating-point·notation.··The·amount·of·precision·(the·number | 165 | is·displayed·in·floating-point·notation.··The·amount·of·precision·(the·number |
158 | of·digits·to·the·right·of·the·decimal·point)·can·be·set·with·the·optional | 166 | of·digits·to·the·right·of·the·decimal·point)·can·be·set·with·the·optional |
159 | PRECISION·attribute.··The·default·precision·is·zero·(0),·which·means·no | 167 | PRECISION·attribute.··The·default·precision·is·zero·(0),·which·means·no |
Offset 1, 126 lines modified | Offset 1, 126 lines modified | ||
1 | [HTP] | 1 | [HTP] |
2 | ******·htp·on-line·reference·:·FILE·****** | 2 | ******·htp·on-line·reference·:·FILE·****** |
3 | Table_of | 3 | Table_of··········*****·syntax·***** |
4 | Contents·········· <[[ref]]def·name="imghr"> | ||
5 | Introduction···· · <table·border="0"·cellspacing="0"·cellpadding="0"> | ||
6 | License········· · <tr> | ||
7 | Tutorial········ · ·<td·width=10><[[ref]]img·src="leftsep.png"></td> | ||
8 | Usage··········· · ·<td·width="95%"·background="midsep.png"> </td> | ||
9 | HTP·Tags········ · ·<td·width=10><[[ref]]img·src="rightsep.png"></td> | ||
10 | ··ALTTEXT····· · </tr> | ||
11 | ··BLOCK······· · </table> | ||
12 | ··BLOCKDEF···· <[[ref]]/def> | ||
13 | ··DEF | ||
14 | [>]·FILE········ paragraph | ||
15 | ··IF·········· <imghr> | ||
16 | ··INC········· paragraph | ||
4 | | 17 | ··IMG·········*****·synopsis·***** |
5 | | 18 | ··IMAGEURL····FILE·has·several·optional·parameters·of·differing·purpose. |
19 | ··OPT·········The·output·file's·name,·the·current·date·and·time,·and·the | ||
20 | ··OUTPUT······contents·of·another·file·may·be·included.·Another·file's | ||
21 | ··QUOTE·······time,·date,·or·size·may·be·added·to·the·output·file·as·well. | ||
6 | Tutorial···········purpose.·The·output·file's·name,·the·current·date·and | ||
7 | Usage··············time,·and·the·contents·of·another·file·may·be·included. | ||
8 | HTP·Tags···········Another·file's·time,·date,·or·size·may·be·added·to·the | ||
9 | ··ALTTEXT········output·file·as·well. | ||
10 | ·· | 22 | ··SET·········As·with·all·HTML,·these·tags·do·not·have·to·be·on·their·own |
11 | ·· | 23 | ··UNDEF·······line,·so·the·following·is·perfectly·acceptable: |
12 | ··DEF············ · ·<[[ref]]INC·i="1"·j="-1"> | ||
13 | | 24 | ··UNSET·······****·NAME,·TIME,·SIZE·**** |
14 | ·· | 25 | ··USE,_$······To·include·information·about·another·file,·such·as·an |
15 | ·· | 26 | ··WHILE·······archive·file·or·graphic·image,·specify·its·name·with·the |
16 | ·· | 27 | ··<!---·······NAME·attribute·followed·by·the·type·of·information·to·be |
28 | History·········displayed: | ||
29 | Wish_list·······<[[ref]]block·stuff> | ||
30 | Bugs············ ·<a·href=$email>send·email</a> | ||
31 | ··················<[[ref]]/block> | ||
17 | ··IMAGEURL·······displayed: | ||
18 | ··OPT············ · ·<[[ref]]IF·name="Jim">...<[[ref]]/IF> | ||
19 | ··OUTPUT·········e·border="0"·cellspacing="0"·cellpadding="0"> | ||
20 | ··QUOTE·········· · <tr> | ||
21 | ··SET············ · ·<td·width=10><[[ref]]img·src="leftsep.png"></td> | ||
22 | ··UNDEF·········· · ·<td·width="95%"·background="midsep.png"> </td> | ||
23 | ··UNSET·········· · ·<td·width=10><[[ref]]img·src="rightsep.png"></td> | ||
24 | ··USE,_$········· · </tr> | ||
25 | ··WHILE·········· · </table> | ||
26 | ··<!---·········· <[[ref]]/def> | ||
27 | History | ||
28 | Wish_list·········· paragraph | ||
29 | Bugs··············· <imghr> | ||
30 | ····················· paragraph | ||
31 | ·····················For·file·size·information,·the·value·BYTE,·KBYTE,·etc. | ||
32 | ·····················dictates·how·the·information·is·displayed.·In·anything | ||
33 | ·····················other·than·byte·format,·the·information·is·displayed·in | ||
34 | ·····················floating-point·notation.·The·amount·of·precision·(the | ||
35 | ·····················number·of·digits·to·the·right·of·the·decimal·point)·can | ||
36 | ·····················be·set·with·the·optional·PRECISION·attribute.·The·default | ||
37 | ·····················precision·is·zero·(0),·which·means·no·fractional·portion | ||
38 | ·····················is·displayed. | ||
39 | ·····················At·the·request·of·many·people,·the·TIME·and·DATE | ||
40 | ·····················attributes·will·now·accept·formatting·characters·that·are | ||
41 | ·····················passed·directly·into·the·ANSI·C·library·function.·This | ||
42 | ·····················allows·for·the·time·and·date·to·be·displayed·in·virtually | ||
43 | ·····················any·format.·Users·not·wishing·to·mess·around·with·this | ||
44 | ·····················should·stick·to·the·default·format,·which·is·used·if·no | ||
45 | ·····················formatting·value·is·specified·(i.e.,·just·using·05:04:11 | ||
46 | ·····················PM). | ||
47 | ·····················Consult·any·C·programmer's·guide·discussing·the·standard | ||
48 | ·····················C·library·function·strftime()·for·information·on·how·to | ||
49 | ·····················build·a·format·string.·If·unsure,·ask·an·experienced·C | ||
50 | ·····················programmer·for·help,·or·consider·just·sticking·to·the | ||
51 | ·····················default·formatting. | ||
52 | ·····················****·INCLUDE·**** | ||
53 | ·····················INCLUDE·files·are·pre-processed·as·any·other·file.·The | ||
54 | ·····················resulting·text·is·incorporated·into·the·HTML·output·as·if | ||
55 | ·····················the·file·had·been·copied·into·the·source·at·the·same | ||
56 | ·····················location·as·the·FILE·markup·tag. | ||
57 | ·····················htp·will·automatically·convert·slashes·and·backslashes·to | ||
58 | ·····················match·the·operating·system's·directory·separator. | ||
59 | ·····················Additional·parameters·can·be·set·in·the·FILE·INCLUDE·tag, | ||
60 | ·····················which·are·interpreted·as·macros·that·are·"passed"·to·the | ||
61 | ·····················included·file.·The·macros·are·available·only·to·the | ||
62 | ·····················include·file·(and·any·macros·or·included·files·it·holds). | ||
63 | ·····················After·the·file·is·completely·included,·the·macros·are·no | ||
64 | ·····················longer·available.·So: | ||
65 | ·····················<[[ref]]SET·macroname1="macrovalue1" | ||
66 | ·····················[macroname2="macrovalue2"·...]·[GLOBAL]> | ||
32 | ··················<[[ref]]set·morestuff=$email> | ||
33 | ··················This·works:· · ·<[[ref]]use·stuff·email="jnelson@crl.com"> | ||
34 | ··················But·this·fails:·<[[ref]]use·email> | ||
35 | ··················And·this·fails:·<[[ref]]use·morestuff | ||
36 | ··················email="jnelson@crl.com"> | ||
37 | ··················For·file·size·information,·the·value·BYTE,·KBYTE,·etc. | ||
38 | ··················dictates·how·the·information·is·displayed.·In·anything·other | ||
39 | ··················than·byte·format,·the·information·is·displayed·in·floating- | ||
40 | ··················point·notation.·The·amount·of·precision·(the·number·of | ||
41 | ··················digits·to·the·right·of·the·decimal·point)·can·be·set·with | ||
42 | ··················the·optional·PRECISION·attribute.·The·default·precision·is | ||
43 | ··················zero·(0),·which·means·no·fractional·portion·is·displayed. | ||
44 | ··················At·the·request·of·many·people,·the·TIME·and·DATE·attributes | ||
45 | ··················will·now·accept·formatting·characters·that·are·passed | ||
46 | ··················directly·into·the·ANSI·C·library·function.·This·allows·for | ||
47 | ··················the·time·and·date·to·be·displayed·in·virtually·any·format. | ||
48 | ··················Users·not·wishing·to·mess·around·with·this·should·stick·to | ||
49 | ··················the·default·format,·which·is·used·if·no·formatting·value·is | ||
50 | ··················specified·(i.e.,·just·using·05:04:11·PM). | ||
51 | ··················Consult·any·C·programmer's·guide·discussing·the·standard·C | ||
52 | ··················library·function·strftime()·for·information·on·how·to·build | ||
53 | ··················a·format·string.·If·unsure,·ask·an·experienced·C·programmer | ||
54 | ··················for·help,·or·consider·just·sticking·to·the·default | ||
55 | ··················formatting. | ||
56 | ··················****·INCLUDE·**** | ||
57 | ··················INCLUDE·files·are·pre-processed·as·any·other·file.·The | ||
58 | ··················resulting·text·is·incorporated·into·the·HTML·output·as·if | ||
59 | ··················the·file·had·been·copied·into·the·source·at·the·same | ||
60 | ··················location·as·the·FILE·markup·tag. | ||
61 | ··················htp·will·automatically·convert·slashes·and·backslashes·to | ||
62 | ··················match·the·operating·system's·directory·separator. | ||
63 | ··················Additional·parameters·can·be·set·in·the·FILE·INCLUDE·tag, | ||
64 | ··················which·are·interpreted·as·macros·that·are·"passed"·to·the | ||
65 | ··················included·file.·The·macros·are·available·only·to·the·include | ||
66 | ··················file·(and·any·macros·or·included·files·it·holds).·After·the | ||
67 | ··················file·is·completely·included,·the·macros·are·no·longer | ||
68 | ··················available.·So: | ||
67 | ·················· | 69 | ··················Macros·named·"name"·and·"email"·are·set,·and·available |
Max diff block lines reached; 12/15075 bytes (0.08%) of diff not shown. |
Offset 114, 38 lines modified | Offset 114, 31 lines modified | ||
114 | ······<a·class="noline"·href="bugs.html">Bugs</a></td></tr> | 114 | ······<a·class="noline"·href="bugs.html">Bugs</a></td></tr> |
115 | ··</table> | 115 | ··</table> |
116 | ··</div> | 116 | ··</div> |
117 | </td> | 117 | </td> |
118 | <td·bgcolor="#f0f0d0"·rowspan="2"·valign="top"> | 118 | <td·bgcolor="#f0f0d0"·rowspan="2"·valign="top"> |
119 | <h2>syntax</h2> | 119 | <h2>syntax</h2> |
120 | ··<p><code> | 120 | ··<p><code> |
121 | <span·class="htp-tag"><<a·href="if.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">if</a>·<span·class="htp-attrib">disabled_because_xyz</span>></span><br> | ||
122 | ·...<br> | ||
123 | <span·class="htp-tag"><<a·href="if.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">/if</a>></span><br> | ||
124 | =center><br> | ||
125 | · ·<span·class="htp-tag"><<a·href="def.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">/def</a>></span><br> | ||
126 | <br> | ||
127 | · ·<span·class="htp-tag"><centered></span><br> | ||
128 | · ·This·text·is·centered.<br> | ||
129 | </code></p> | 121 | </code></p> |
130 | <h2>synopsis</h2> | 122 | <h2>synopsis</h2> |
131 | <STRONG>IF,·NOT,·ELSEIF,·ELSE,·and·/IF</STRONG>·are·the·building | 123 | <STRONG>IF,·NOT,·ELSEIF,·ELSE,·and·/IF</STRONG>·are·the·building |
132 | blocks·for·conditional·processing.··The·basic·form·is·shown·above. | 124 | blocks·for·conditional·processing.··The·basic·form·is·shown·above. |
133 | <P>·"Conditional"·is·either·a·"compare"·or·"is·defined"·operation.··A | 125 | <P>·"Conditional"·is·either·a·"compare"·or·"is·defined"·operation.··A |
134 | compare·operator·is·a·test·of·the·value·of·a·macro·against·a·literal | 126 | compare·operator·is·a·test·of·the·value·of·a·macro·against·a·literal |
135 | string: | 127 | string: |
136 | ··<p><code> | 128 | ··<p><code> |
137 | </code></p> | 129 | </code></p> |
138 | <P> | 130 | <P> |
139 | and·a·defined·operator·is·a·test·of·a·macro's·existance: | 131 | and·a·defined·operator·is·a·test·of·a·macro's·existance: |
140 | <P> | 132 | <P> |
141 | ··<p><code> | 133 | ··<p><code> |
134 | ·<span·class="htp-tag"><<a·href="while.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">WHILE</a>·<span·class="htp-attrib">NOT</span>·<span·class="htp-attrib">i</span>=<span·class="htp-string">"10"</span>></span><br> | ||
135 | · ·...<br> | ||
142 | <span·class="htp-tag"><<a·href=" | 136 | · ·<span·class="htp-tag"><<a·href="inc.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">INC</a>·<span·class="htp-attrib">i</span>></span><br> |
137 | ·<span·class="htp-tag"><<a·href="while.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">/WHILE</a>></span><br> | ||
143 | <span·class="htp-tag"><<a·href="undef.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">UNDEF</a>·<span·class="htp-attrib">tagname1</span>·<span·class="htp-attrib">tagname2</span>·<span·class="htp-attrib">...</span>·></span><br> | ||
144 | <br> | ||
145 | </code></p> | 138 | </code></p> |
146 | <P> | 139 | <P> |
147 | If·the·NOT·tag·is·present·in·the·IF·markup,·the·evaluation·of·the | 140 | If·the·NOT·tag·is·present·in·the·IF·markup,·the·evaluation·of·the |
148 | conditional·is·reversed.··The·first·IF·or·ELSEIF·condition·that | 141 | conditional·is·reversed.··The·first·IF·or·ELSEIF·condition·that |
149 | evaluates·to·true·is·chosen.··If·none·of·the·conditions·is·true·the | 142 | evaluates·to·true·is·chosen.··If·none·of·the·conditions·is·true·the |
150 | ELSE·block·is·taken·if·it·is·present.··A·conditional·block | 143 | ELSE·block·is·taken·if·it·is·present.··A·conditional·block |
151 | <EM>must</EM>·be·closed·with·the·/IF·tag.··IF·tags·can·be·nested. | 144 | <EM>must</EM>·be·closed·with·the·/IF·tag.··IF·tags·can·be·nested. |
Offset 1, 44 lines modified | Offset 1, 37 lines modified | ||
1 | [HTP] | 1 | [HTP] |
2 | ******·htp·on-line·reference·:·IF,·ELSEIF,·ELSE,·/IF·****** | 2 | ******·htp·on-line·reference·:·IF,·ELSEIF,·ELSE,·/IF·****** |
3 | Table_of_Contents············*****·syntax·***** | 3 | Table_of_Contents············*****·syntax·***** |
4 | Introduction···············<[[ref]]if·disabled_because_xyz> | ||
5 | License···················· ·... | ||
6 | Tutorial···················<[[ref]]/if> | ||
7 | Usage······················=center> | ||
8 | HTP·Tags··················· · ·<[[ref]]/def> | ||
9 | ··ALTTEXT | ||
10 | ··BLOCK·················· · ·<centered> | ||
11 | ··BLOCKDEF··············· · ·This·text·is·centered. | ||
12 | | 4 | Introduction···············*****·synopsis·***** |
13 | | 5 | License····················IF,·NOT,·ELSEIF,·ELSE,·and·/IF·are·the·building |
14 | | 6 | Tutorial···················blocks·for·conditional·processing.·The·basic·form |
15 | | 7 | Usage······················is·shown·above. |
16 | | 8 | HTP·Tags···················"Conditional"·is·either·a·"compare"·or·"is |
17 | ·· | 9 | ··ALTTEXT················defined"·operation.·A·compare·operator·is·a·test |
18 | ·· | 10 | ··BLOCK··················of·the·value·of·a·macro·against·a·literal·string: |
19 | ·· | 11 | ··BLOCKDEF···············and·a·defined·operator·is·a·test·of·a·macro's |
20 | ·· | 12 | ··DEF····················existance: |
21 | ··SET····················<[[ref]]UNDEF·tagname> | ||
22 | ··UNDEF··················<[[ref]]UNDEF·tagname1·tagname2·...·> | ||
23 | ·· | 13 | ··FILE··················· ·<[[ref]]WHILE·NOT·i="10"> |
14 | [>]·IF····················· · ·... | ||
15 | ··INC···················· · ·<[[ref]]INC·i> | ||
16 | ··IMG···················· ·<[[ref]]/WHILE> | ||
24 | ·· | 17 | ··IMAGEURL···············If·the·NOT·tag·is·present·in·the·IF·markup,·the |
25 | ·· | 18 | ··OPT····················evaluation·of·the·conditional·is·reversed.·The |
26 | ·· | 19 | ··OUTPUT·················first·IF·or·ELSEIF·condition·that·evaluates·to |
27 | | 20 | ··QUOTE··················true·is·chosen.·If·none·of·the·conditions·is·true |
28 | | 21 | ··SET····················the·ELSE·block·is·taken·if·it·is·present.·A |
29 | | 22 | ··UNDEF··················conditional·block·must·be·closed·with·the·/IF·tag. |
30 | 23 | ··UNSET··················IF·tags·can·be·nested. | |
24 | ··USE,_$ | ||
25 | ··WHILE | ||
26 | ··<!--- | ||
27 | History | ||
28 | Wish_list | ||
29 | Bugs | ||
Offset 114, 15 lines modified | Offset 114, 27 lines modified | ||
114 | ······<a·class="noline"·href="bugs.html">Bugs</a></td></tr> | 114 | ······<a·class="noline"·href="bugs.html">Bugs</a></td></tr> |
115 | ··</table> | 115 | ··</table> |
116 | ··</div> | 116 | ··</div> |
117 | </td> | 117 | </td> |
118 | <td·bgcolor="#f0f0d0"·rowspan="2"·valign="top"> | 118 | <td·bgcolor="#f0f0d0"·rowspan="2"·valign="top"> |
119 | <h2>syntax</h2> | 119 | <h2>syntax</h2> |
120 | ··<p><code> | 120 | ··<p><code> |
121 | | 121 | <span·class="htp-tag"><<a·href="def.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">def</a>·<span·class="htp-attrib">name</span>=<span·class="htp-string">"imghr"</span>></span><br> |
122 | · <span·class="htp-tag"><table·<span·class="htp-attrib">border</span>=<span·class="htp-string">"0"</span>·<span·class="htp-attrib">cellspacing</span>=<span·class="htp-string">"0"</span>·<span·class="htp-attrib">cellpadding</span>=<span·class="htp-string">"0"</span>></span><br> | ||
123 | · <span·class="htp-tag"><tr></span><br> | ||
124 | · ·<span·class="htp-tag"><td·<span·class="htp-attrib">width</span>=<span·class="htp-value">10</span>></span><span·class="htp-tag"><<a·href="img.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">img</a>·<span·class="htp-attrib">src</span>=<span·class="htp-string">"leftsep.png"</span>></span><span·class="htp-tag"></td></span><br> | ||
125 | · ·<span·class="htp-tag"><td·<span·class="htp-attrib">width</span>=<span·class="htp-string">"95%"</span>·<span·class="htp-attrib">background</span>=<span·class="htp-string">"midsep.png"</span>></span>&nbsp;<span·class="htp-tag"></td></span><br> | ||
126 | · ·<span·class="htp-tag"><td·<span·class="htp-attrib">width</span>=<span·class="htp-value">10</span>></span><span·class="htp-tag"><<a·href="img.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">img</a>·<span·class="htp-attrib">src</span>=<span·class="htp-string">"rightsep.png"</span>></span><span·class="htp-tag"></td></span><br> | ||
127 | · <span·class="htp-tag"></tr></span><br> | ||
128 | · <span·class="htp-tag"></table></span><br> | ||
129 | <span·class="htp-tag"><<a·href="def.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">/def</a>></span><br> | ||
130 | <br> | ||
131 | paragraph<br> | ||
132 | <span·class="htp-tag"><imghr></span><br> | ||
133 | paragraph<br> | ||
122 | </code></p> | 134 | </code></p> |
123 | <h2>synopsis</h2> | 135 | <h2>synopsis</h2> |
124 | <P> | 136 | <P> |
125 | <STRONG>IMAGEURL</STRONG>·tells·htp,·where·to·find·images·on·the·local | 137 | <STRONG>IMAGEURL</STRONG>·tells·htp,·where·to·find·images·on·the·local |
126 | file·system.··declares·an·URL·replacement·that·is·used·for | 138 | file·system.··declares·an·URL·replacement·that·is·used·for |
127 | size·lookups·in·any·<A·HREF="img.html">IMG</A>·tag.·This·definitions | 139 | size·lookups·in·any·<A·HREF="img.html">IMG</A>·tag.·This·definitions |
128 | takes·effect·only·if·the·<A·HREF="opt.html">IMGXY</A>·option·is | 140 | takes·effect·only·if·the·<A·HREF="opt.html">IMGXY</A>·option·is |
Offset 1, 41 lines modified | Offset 1, 49 lines modified | ||
1 | [HTP] | 1 | [HTP] |
2 | ******·htp·on-line·reference·:·IMAGEURL·****** | 2 | ******·htp·on-line·reference·:·IMAGEURL·****** |
3 | Table_of_Contents···· | 3 | Table_of_Contents····*****·syntax·***** |
4 | Introduction··············· · ·<[[ref]]INC·i="1"·j="-1"> | ||
5 | | 4 | Introduction······· <[[ref]]def·name="imghr"> |
5 | License············ · <table·border="0"·cellspacing="0"·cellpadding="0"> | ||
6 | Tutorial··········· · <tr> | ||
7 | Usage·············· · ·<td·width=10><[[ref]]img·src="leftsep.png"></td> | ||
8 | HTP·Tags··········· · ·<td·width="95%"·background="midsep.png"> </td> | ||
9 | ··ALTTEXT········ · ·<td·width=10><[[ref]]img·src="rightsep.png"></td> | ||
10 | ··BLOCK·········· · </tr> | ||
11 | ··BLOCKDEF······· · </table> | ||
12 | ··DEF············ <[[ref]]/def> | ||
13 | ··FILE | ||
14 | ··IF············· paragraph | ||
15 | ··INC············ <imghr> | ||
16 | ··IMG············ paragraph | ||
17 | [>]·IMAGEURL·······*****·synopsis·***** | ||
6 | | 18 | ··OPT············IMAGEURL·tells·htp,·where·to·find·images·on·the·local |
7 | Usage······················local·file·system.·declares·an·URL·replacement | ||
8 | HTP·Tags···················that·is·used·for·size·lookups·in·any·IMG·tag.·This | ||
9 | ··ALTTEXT················definitions·takes·effect·only·if·the·IMGXY·option | ||
10 | ··BLOCK··················is·enabled.·Beacause·htp·can't·lookup·files·in·the | ||
11 | ··BLOCKDEF···············world·wide·web·you·have·to·map·absolute·image·URLs | ||
12 | ·· | 19 | ··OUTPUT·········file·system.·declares·an·URL·replacement·that·is·used·for |
20 | ··QUOTE··········size·lookups·in·any·IMG·tag.·This·definitions·takes | ||
21 | ··SET············effect·only·if·the·IMGXY·option·is·enabled.·Beacause·htp | ||
22 | ··UNDEF··········can't·lookup·files·in·the·world·wide·web·you·have·to·map | ||
23 | ··UNSET··········absolute·image·URLs·to·a·directory·in·the·local·file | ||
24 | ··USE,_$·········system. | ||
13 | ·· | 25 | ··WHILE··········When·an·IMG·tag·is·encountered·where·htp·has·to·insert |
26 | ··<!---··········width·and·height·the·defined·URL·replacements·will·be | ||
27 | History············taken·into·account·(later·definitions·take·precedence·to | ||
28 | Wish_list··········earlier):·For·each·defined·imageurl·it·checks·(case- | ||
29 | Bugs···············insensitive)·if·it·is·a·prefix·of·the·image's·SRC | ||
30 | ·····················attribute.·If·it·matches·this·prefix·is·replaced·by·the | ||
14 | ··IF·····················insert·width·and·height·the·defined·URL | ||
15 | ··INC····················replacements·will·be·taken·into·account·(later | ||
16 | ··IMG····················definitions·take·precedence·to·earlier):·For·each | ||
17 | [>]·IMAGEURL···············defined·imageurl·it·checks·(case-insensitive)·if | ||
18 | ··OPT····················it·is·a·prefix·of·the·image's·SRC·attribute.·If·it | ||
19 | ··OUTPUT·················matches·this·prefix·is·replaced·by·the·given·PATH. | ||
20 | 31 | ·····················given·PATH.·If·no·IMAGEURL·matches·the·SRC·is·considered | |
21 | 32 | ·····················as·relative·link·and·looked·up·in·the·current·directory. | |
22 | ··UNDEF··················directory. | ||
23 | 33 | ·····················For·example: | |
24 | 34 | ·····················If·IMAGEURL·is·specified·with·a·URL·but·no·PATH | |
25 | 35 | ·····················attribute,·it·is·treated·as·an·undefine,·and·is·removed. | |
26 | ··<!---··················removed. | ||
27 | 36 | ·····················Since·you·usually·need·the·url·mapping·for·a·number·of | |
28 | Wish_list··················number·of·images·used·throughout·a·set·of | ||
29 | Bugs·······················documents,·IMAGEURL·is·most·appropriately·put·into | ||
30 | ····················· | 37 | ·····················images·used·throughout·a·set·of·documents,·IMAGEURL·is |
38 | ·····················most·appropriately·put·into·an·include_file·or·the | ||
39 | ·····················htp.def·file. | ||
31 | ····················· | 40 | ·····················In·addition·to·WIDTH·and·HEIGHT,·htp·can·also·(semi- |
32 | ····················· | 41 | ·····················)automatically·add·an·ALT_text·attribute·to·IMG·tags. |
33 | ·····························IMG·tags. | ||
Offset 114, 49 lines modified | Offset 114, 30 lines modified | ||
114 | ······<a·class="noline"·href="bugs.html">Bugs</a></td></tr> | 114 | ······<a·class="noline"·href="bugs.html">Bugs</a></td></tr> |
115 | ··</table> | 115 | ··</table> |
116 | ··</div> | 116 | ··</div> |
117 | </td> | 117 | </td> |
118 | <td·bgcolor="#f0f0d0"·rowspan="2"·valign="top"> | 118 | <td·bgcolor="#f0f0d0"·rowspan="2"·valign="top"> |
119 | <h2>syntax</h2> | 119 | <h2>syntax</h2> |
120 | ··<p><code> | 120 | ··<p><code> |
121 | <span·class="htp-tag"><<a·href="if.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">if</a>·<span·class="htp-attrib">disabled_because_xyz</span>></span><br> | ||
122 | ·...<br> | ||
123 | <span·class="htp-tag"><<a·href="if.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">/if</a>></span><br> | ||
124 | =center><br> | ||
125 | · ·<span·class="htp-tag"><<a·href="def.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">/def</a>></span><br> | ||
126 | <br> | ||
127 | · ·<span·class="htp-tag"><centered></span><br> | ||
128 | · ·This·text·is·centered.<br> | ||
129 | </code></p> | 121 | </code></p> |
130 | <h2>synopsis</h2> | 122 | <h2>synopsis</h2> |
131 | The·<STRONG>INC</STRONG>·can·be·used·for·incrementing/decrementing·a | 123 | The·<STRONG>INC</STRONG>·can·be·used·for·incrementing/decrementing·a |
132 | variable·or·for·variable·addition.··The·basic·form·is·shown·above. | 124 | variable·or·for·variable·addition.··The·basic·form·is·shown·above. |
133 | <P> | 125 | <P> |
134 | The·"increment"·is·anything·that·evaluates·to·a·integer.··It·can·be·a | 126 | The·"increment"·is·anything·that·evaluates·to·a·integer.··It·can·be·a |
135 | literal·string·or·a·macro·preceeded·by·the·'$'-operator.··The | 127 | literal·string·or·a·macro·preceeded·by·the·'$'-operator.··The |
136 | macroname·must·be·the·name·of·a·defined·macro·that·contains·an | 128 | macroname·must·be·the·name·of·a·defined·macro·that·contains·an |
137 | integer.··If·the·increment·is·ommitted·it·defaults·to·1. | 129 | integer.··If·the·increment·is·ommitted·it·defaults·to·1. |
138 | The·effect·of·this·operation·is·that·the·macro·is·redefined | 130 | The·effect·of·this·operation·is·that·the·macro·is·redefined |
139 | to·contain·the·sum·of·its·previous·value·and·its·increment. | 131 | to·contain·the·sum·of·its·previous·value·and·its·increment. |
140 | <P> | 132 | <P> |
141 | To·increment·or·decrement·a·variable·you·can·use·this·form: | 133 | To·increment·or·decrement·a·variable·you·can·use·this·form: |
142 | ··<p><code> | 134 | ··<p><code> |
135 | · ·File·image.gif·<span·class="htp-tag"><<a·href="file.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">FILE</a>·<span·class="htp-attrib">NAME</span>=<span·class="htp-string">"image.gif"</span>·<span·class="htp-attrib">SIZE</span>=<span·class="htp-value">KBYTE</span>></span> kilobytes<br> | ||
136 | · ·Last·modified·<span·class="htp-tag"><<a·href="file.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">FILE</a>·<span·class="htp-attrib">NAME</span>=<span·class="htp-string">"image.gif"</span>·<span·class="htp-attrib">TIME</span>></span>,·<span·class="htp-tag"><<a·href="file.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">FILE</a>·<span·class="htp-attrib">NAME</span>=<span·class="htp-string">"image.gif"</span>·<span·class="htp-attrib">DATE</span>></span><br> | ||
143 | · ·<span·class="htp-tag"><<a·href="if.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">IF</a>·<span·class="htp-attrib">name</span>=<span·class="htp-string">"Jim"</span>></span>...<span·class="htp-tag"><<a·href="if.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">/IF</a>></span><br> | ||
144 | e·border="0"·cellspacing="0"·cellpadding="0"><br> | ||
145 | · <span·class="htp-tag"><tr></span><br> | ||
146 | · ·<span·class="htp-tag"><td·<span·class="htp-attrib">width</span>=<span·class="htp-value">10</span>></span><span·class="htp-tag"><<a·href="img.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">img</a>·<span·class="htp-attrib">src</span>=<span·class="htp-string">"leftsep.png"</span>></span><span·class="htp-tag"></td></span><br> | ||
147 | · ·<span·class="htp-tag"><td·<span·class="htp-attrib">width</span>=<span·class="htp-string">"95%"</span>·<span·class="htp-attrib">background</span>=<span·class="htp-string">"midsep.png"</span>></span>&nbsp;<span·class="htp-tag"></td></span><br> | ||
148 | · ·<span·class="htp-tag"><td·<span·class="htp-attrib">width</span>=<span·class="htp-value">10</span>></span><span·class="htp-tag"><<a·href="img.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">img</a>·<span·class="htp-attrib">src</span>=<span·class="htp-string">"rightsep.png"</span>></span><span·class="htp-tag"></td></span><br> | ||
149 | · <span·class="htp-tag"></tr></span><br> | ||
150 | · <span·class="htp-tag"></table></span><br> | ||
151 | <span·class="htp-tag"><<a·href="def.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">/def</a>></span><br> | ||
152 | <br> | ||
153 | paragraph<br> | ||
154 | <span·class="htp-tag"><imghr></span><br> | ||
155 | paragraph<br> | ||
156 | </code></p> | 137 | </code></p> |
157 | <p> | 138 | <p> |
158 | Note·that·INC·doesn't·check·if·the·strings·really·denote·integers.··It | 139 | Note·that·INC·doesn't·check·if·the·strings·really·denote·integers.··It |
159 | may·give·weired·results·when·used·on·arbitrary·strings.··The·integer | 140 | may·give·weired·results·when·used·on·arbitrary·strings.··The·integer |
160 | values·are·limited·to·the·range·-2^31..2^31. | 141 | values·are·limited·to·the·range·-2^31..2^31. |
161 | <P> | 142 | <P> |
162 | Note·further·that·htp·wasn't·designed·to·do·extensive·calculations. | 143 | Note·further·that·htp·wasn't·designed·to·do·extensive·calculations. |
Offset 1, 60 lines modified | Offset 1, 38 lines modified | ||
1 | [HTP] | 1 | [HTP] |
2 | ******·htp·on-line·reference·:·INC·****** | 2 | ******·htp·on-line·reference·:·INC·****** |
3 | Table_of | 3 | Table_of·······*****·syntax·***** |
4 | Contents·······*****·synopsis·***** | ||
5 | Introduction·The·INC·can·be·used·for·incrementing/decrementing·a·variable·or·for | ||
6 | License······variable·addition.·The·basic·form·is·shown·above. | ||
4 | Introduction·······<[[ref]]if·disabled_because_xyz> | ||
5 | License············ ·... | ||
6 | Tutorial···········<[[ref]]/if> | ||
7 | Usage··············=center> | ||
8 | HTP·Tags··········· · ·<[[ref]]/def> | ||
9 | ··ALTTEXT | ||
10 | ··BLOCK·········· · ·<centered> | ||
11 | ··BLOCKDEF······· · ·This·text·is·centered. | ||
12 | ··DEF············*****·synopsis·***** | ||
13 | ··FILE···········The·INC·can·be·used·for·incrementing/decrementing·a | ||
14 | ··IF·············variable·or·for·variable·addition.·The·basic·form·is | ||
15 | [>]·INC············shown·above. | ||
16 | | 7 | Tutorial·····The·"increment"·is·anything·that·evaluates·to·a·integer.·It·can·be·a |
8 | Usage········literal·string·or·a·macro·preceeded·by·the·'$'-operator.·The·macroname | ||
9 | HTP·Tags·····must·be·the·name·of·a·defined·macro·that·contains·an·integer.·If·the | ||
17 | ··IMAGEURL·······It·can·be·a·literal·string·or·a·macro·preceeded·by·the | ||
18 | ··OPT············'$'-operator.·The·macroname·must·be·the·name·of·a·defined | ||
19 | ··OUTPUT·········macro·that·contains·an·integer.·If·the·increment·is | ||
20 | ·· | 10 | ··ALTTEXT··increment·is·ommitted·it·defaults·to·1.·The·effect·of·this·operation·is |
21 | ·· | 11 | ··BLOCK····that·the·macro·is·redefined·to·contain·the·sum·of·its·previous·value·and |
22 | ·· | 12 | ··BLOCKDEF·its·increment. |
23 | ·· | 13 | ··DEF······To·increment·or·decrement·a·variable·you·can·use·this·form: |
14 | ··FILE····· · ·File·image.gif·<[[ref]]FILE·NAME="image.gif"·SIZE=KBYTE> kilobytes | ||
15 | ··IF······· · ·Last·modified·<[[ref]]FILE·NAME="image.gif"·TIME>,·<[[ref]]FILE | ||
16 | [>]·INC······NAME="image.gif"·DATE> | ||
24 | ··USE,_$·········form: | ||
25 | ··WHILE·········· · ·<[[ref]]IF·name="Jim">...<[[ref]]/IF> | ||
26 | ··<!---··········e·border="0"·cellspacing="0"·cellpadding="0"> | ||
27 | History············ · <tr> | ||
28 | Wish_list·········· · ·<td·width=10><[[ref]]img·src="leftsep.png"></td> | ||
29 | Bugs··············· · ·<td·width="95%"·background="midsep.png"> </td> | ||
30 | ····················· · ·<td·width=10><[[ref]]img·src="rightsep.png"></td> | ||
31 | ····················· · </tr> | ||
32 | ····················· · </table> | ||
33 | ····················· <[[ref]]/def> | ||
34 | ····················· paragraph | ||
35 | ····················· <imghr> | ||
36 | ····················· paragraph | ||
37 | 17 | ··IMG······Note·that·INC·doesn't·check·if·the·strings·really·denote·integers.·It·may | |
18 | ··IMAGEURL·give·weired·results·when·used·on·arbitrary·strings.·The·integer·values | ||
19 | ··OPT······are·limited·to·the·range·-2^31..2^31. | ||
20 | ··OUTPUT···Note·further·that·htp·wasn't·designed·to·do·extensive·calculations.·The | ||
21 | ··QUOTE····INC·tag·is·useful·in·conjunction·with·WHILE·to·iterate·over·the·defined | ||
22 | ··SET······blocks. | ||
23 | ··UNDEF | ||
24 | ··UNSET | ||
25 | ··USE,_$ | ||
26 | ··WHILE | ||
27 | ··<!--- | ||
28 | History | ||
29 | Wish_list | ||
30 | Bugs | ||
38 | ·····················integers.·It·may·give·weired·results·when·used·on | ||
39 | ·····················arbitrary·strings.·The·integer·values·are·limited·to·the | ||
40 | ·····················range·-2^31..2^31. | ||
41 | ·····················Note·further·that·htp·wasn't·designed·to·do·extensive | ||
42 | ·····················calculations.·The·INC·tag·is·useful·in·conjunction·with | ||
43 | ·····················WHILE·to·iterate·over·the·defined·blocks. | ||
Offset 105, 38 lines modified | Offset 105, 46 lines modified | ||
105 | file</a>.··</p> | 105 | file</a>.··</p> |
106 | <P>·Often·you·want·to·define·tags·that·have·an·opening·and·a·closing | 106 | <P>·Often·you·want·to·define·tags·that·have·an·opening·and·a·closing |
107 | variant.··For·this·purpose·you·should·use·the·<a·href="blockdef.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10"><code>blockdef</code></a>·tag.··When·htp | 107 | variant.··For·this·purpose·you·should·use·the·<a·href="blockdef.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10"><code>blockdef</code></a>·tag.··When·htp |
108 | encounters·a·blockdef·tag·it·will·automatically·search·for·the | 108 | encounters·a·blockdef·tag·it·will·automatically·search·for·the |
109 | matching·closing·tag·and·put·everything·between·these·tags·in·a·block | 109 | matching·closing·tag·and·put·everything·between·these·tags·in·a·block |
110 | macro·named·<code>block</code>.··Here·is·an·example·for·this.··</P> | 110 | macro·named·<code>block</code>.··Here·is·an·example·for·this.··</P> |
111 | ··<p><code> | 111 | ··<p><code> |
112 | <font·size="-2"> 1.·</font><span·class="htp-tag"><<a·href=" | 112 | <font·size="-2"> 1.·</font><span·class="htp-tag"><<a·href="block.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">block</a>·<span·class="htp-attrib">stuff</span>></span><br> |
113 | <font·size="-2"> 2.·</font><span·class="htp-tag">< | 113 | <font·size="-2"> 2.·</font> ·<span·class="htp-tag"><a·<span·class="htp-attrib">href</span>=<span·class="htp-value"><span·class="htp-macro">$email</span></span>></span>send·email<span·class="htp-tag"></a></span><br> |
114 | <font·size="-2"> 3.·</font><span·class="htp-tag"><<a·href="block.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">/block</a>></span><br> | ||
114 | <font·size="-2"> | 115 | <font·size="-2"> 4.·</font><br> |
116 | <font·size="-2"> 5.·</font><span·class="htp-tag"><<a·href="set.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">set</a>·<span·class="htp-attrib">morestuff</span>=<span·class="htp-value"><span·class="htp-macro">$email</span></span>></span><br> | ||
117 | <font·size="-2"> 6.·</font><br> | ||
118 | <font·size="-2"> 7.·</font>This·works:· · ·<span·class="htp-tag"><<a·href="use.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">use</a>·<span·class="htp-attrib">stuff</span>·<span·class="htp-attrib">email</span>=<span·class="htp-string">"jnelson@crl.com"</span>></span><br> | ||
119 | <font·size="-2"> 8.·</font>But·this·fails:·<span·class="htp-tag"><<a·href="use.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">use</a>·<span·class="htp-attrib">email</span>></span><br> | ||
120 | <font·size="-2"> 9.·</font>And·this·fails:·<span·class="htp-tag"><<a·href="use.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">use</a>·<span·class="htp-attrib">morestuff</span>·<span·class="htp-attrib">email</span>=<span·class="htp-string">"jnelson@crl.com"</span>></span><br> | ||
115 | </code></p> | 121 | </code></p> |
116 | <h2>Using·parameters</h2> | 122 | <h2>Using·parameters</h2> |
117 | <p>·More·sophisticated·tags·accept·parameters.··The | 123 | <p>·More·sophisticated·tags·accept·parameters.··The |
118 | <code>option</code>·parameter·lets·multiple·metatag·parameters·be | 124 | <code>option</code>·parameter·lets·multiple·metatag·parameters·be |
119 | named·and·expanded·inside·the·<code>def</code>·or | 125 | named·and·expanded·inside·the·<code>def</code>·or |
120 | <code>blockdef</code>·block:·</p> | 126 | <code>blockdef</code>·block:·</p> |
121 | ··<p><code> | 127 | ··<p><code> |
122 | <font·size="-2"> 1.·</font> · ·<span·class="htp-tag"><<a·href="set.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">SET</a>·<span·class="htp-attrib">emailaddr</span>=<span·class="htp-string">"jnelson@crl.com"</span>></span><br> | ||
123 | </code></p> | 128 | </code></p> |
124 | <h2>Saving·blocks·for·later</h2> | 129 | <h2>Saving·blocks·for·later</h2> |
125 | <p>When·you·are·using·templates,·the·html·should·only·be·written·by | 130 | <p>When·you·are·using·templates,·the·html·should·only·be·written·by |
126 | the·template·file.··The·normal·htp·files·should·just·define·macros | 131 | the·template·file.··The·normal·htp·files·should·just·define·macros |
127 | that·are·used·later·in·the·template.··So·you·may·want·to·write·block | 132 | that·are·used·later·in·the·template.··So·you·may·want·to·write·block |
128 | tags·that·just·save·the·block·in·a·macro·for·later·use.··Although·this | 133 | tags·that·just·save·the·block·in·a·macro·for·later·use.··Although·this |
129 | is·possible·with·htp·it·is·quite·tricky,·so·here·we·present·the·way·to | 134 | is·possible·with·htp·it·is·quite·tricky,·so·here·we·present·the·way·to |
130 | do·this:</p> | 135 | do·this:</p> |
131 | ··<p><code> | 136 | ··<p><code> |
132 | <font·size="-2"> 1.·</font><span·class="htp-tag"><<a·href="while.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">WHILE</a>·<span·class="htp-attrib">[NOT]</span>·<span·class="htp-attrib">conditional</span>></span><br> | ||
133 | <font·size="-2"> | 137 | <font·size="-2"> 1.·</font> ·<span·class="htp-tag"><<a·href="set.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">set</a>·<span·class="htp-attrib">sect-ctr</span>=<span·class="htp-string">"0"</span>></span><br> |
138 | <font·size="-2"> 2.·</font> ·<span·class="htp-tag"><<a·href="blockdef.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">blockdef</a>·<span·class="htp-attrib">name</span>=<span·class="htp-string">"section"</span>></span><br> | ||
139 | <font·size="-2"> 3.·</font> · ·<span·class="htp-tag"><<a·href="inc.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">inc</a>·<span·class="htp-attrib">sect-ctr</span>></span><br> | ||
140 | <font·size="-2"> 4.·</font> · ·<span·class="htp-tag"><<a·href="block.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">block</a>·<span·class="htp-attrib">name</span>=<span·class="htp-string">"sect-<span·class="htp-macro">${sect-ctr}</span>"</span>·<span·class="htp-attrib">expand</span>·<span·class="htp-attrib">global</span>></span><br> | ||
141 | <font·size="-2"> 5.·</font> · · ·<span·class="htp-tag"><<a·href="use.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">use</a>·<span·class="htp-attrib">block</span>·<span·class="htp-attrib">noexpand</span>></span><br> | ||
142 | <font·size="-2"> 6.·</font> · ·<span·class="htp-tag"><<a·href="block.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">/block</a>></span><br> | ||
134 | <font·size="-2"> | 143 | <font·size="-2"> 7.·</font> ·<span·class="htp-tag"><<a·href="blockdef.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">/blockdef</a>></span><br> |
135 | <font·size="-2"> 4.·</font><br> | ||
136 | </code></p> | 144 | </code></p> |
137 | <p>·This·defines·a·block·macro·named·section.··This·macro·uses·a | 145 | <p>·This·defines·a·block·macro·named·section.··This·macro·uses·a |
138 | counter·<code>sect-ctr</code>·that·enumerates·the·sections.··It·is | 146 | counter·<code>sect-ctr</code>·that·enumerates·the·sections.··It·is |
139 | increased·for·every·section·(line·3)·and·then·the·block·macro·name·is | 147 | increased·for·every·section·(line·3)·and·then·the·block·macro·name·is |
140 | build·from·this·counter.··So·the·first·section·is·stored·in·block | 148 | build·from·this·counter.··So·the·first·section·is·stored·in·block |
141 | sect-1,·the·second·in·sect-2·and·so·on.··The·<a·href="expand.html#global"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10"><code>global</code></a>·flag | 149 | sect-1,·the·second·in·sect-2·and·so·on.··The·<a·href="expand.html#global"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10"><code>global</code></a>·flag |
142 | in·line·4·tells·htp·that·these·macros·should·be·defined·globally | 150 | in·line·4·tells·htp·that·these·macros·should·be·defined·globally |
Offset 1, 117 lines modified | Offset 1, 121 lines modified | ||
1 | [HTP] | 1 | [HTP] |
2 | ******·htp·on-line·reference·:·Metatags·****** | 2 | ******·htp·on-line·reference·:·Metatags·****** |
3 | Table_of | 3 | Table_of········*****·Programming·your·own·tags·***** |
4 | 4 | Contents········Metatags·allow·for·defining·your·own·HTML-like·tags.·When·you | |
5 | Introduction··define·a·metatag·you·have·to·provide·the·HTML·code·which·it | ||
6 | License·······abbreviates.·In·fact·metatags·are·just·like·block·macros,·but·they | ||
7 | Tutorial······have·a·nicer·syntax.·With·metatags·you·can·expand·htp's | ||
8 | ··Macros····functionality. | ||
9 | ··Including·Metatags·are·defined·with·the·[[ref]]def·and·[[ref]]blockdef·tags | ||
10 | ··Templates·and·undefined·with·the·[[ref]]undef·tag. | ||
5 | License···············When·you·define·a·metatag·you·have·to·provide·the·HTML | ||
6 | Tutorial··············code·which·it·abbreviates.·In·fact·metatags·are·just | ||
7 | ··Macros············like·block·macros,·but·they·have·a·nicer·syntax.·With | ||
8 | ··Including·········metatags·you·can·expand·htp's·functionality. | ||
9 | ··Templates·········Metatags·are·defined·with·the·[[ref]]def·and·[ | ||
10 | ··Files·············[ref]]blockdef·tags·and·undefined·with·the·[[ref]]undef | ||
11 | [>]·Metatags··········tag. | ||
12 | | 11 | ··Files·····As·an·example·we·show·how·to·define·a·tag·that·builds·a·fancy |
13 | | 12 | [>]·Metatags··horizontal·rule·out·of·several·images. |
14 | | 13 | Usage·········In·line·1·of·the·above·example·a·new·tag·named·imghr·is·defined. |
14 | HTP_Tags······The·html·code·which·implements·this·rule·is·following·in·lines·2- | ||
15 | History·······8.·between·the·[[ref]]def_and_/def·tags.·You·don't·have·to | ||
16 | Wish_list·····understand·this·html·code,·but·you·should·understand·that·this·is | ||
17 | Bugs··········just·pure·html·to·draw·the·fancy·rule.·Every·time·you·write | ||
15 | Wish_list·············defined.·The·html·code·which·implements·this·rule·is | ||
16 | Bugs··················following·in·lines·2-8.·between·the·[[ref]]def_and_/def | ||
17 | ························tags.·You·don't·have·to·understand·this·html·code,·but | ||
18 | ························you·should·understand·that·this·is·just·pure·html·to | ||
19 | ························draw·the·fancy·rule.·Every·time·you·write·<imghr>·as·in | ||
20 | ················ | 18 | ················<imghr>·as·in·line·12·htp·will·replace·this·tag·with·the |
21 | ················ | 19 | ················corresponding·html·code.·To·make·metatags·available·to·all·htp |
22 | ················ | 20 | ················documents·in·your·project,·place·them·in·a·common·[[ref]]include |
23 | ················ | 21 | ················file. |
24 | ················ | 22 | ················Often·you·want·to·define·tags·that·have·an·opening·and·a·closing |
25 | ················ | 23 | ················variant.·For·this·purpose·you·should·use·the·[[ref]]blockdef·tag. |
24 | ················When·htp·encounters·a·blockdef·tag·it·will·automatically·search | ||
26 | ························[[ref]]blockdef·tag.·When·htp·encounters·a·blockdef·tag | ||
27 | ························it·will·automatically·search·for·the·matching·closing | ||
28 | ··················· | 25 | ················for·the·matching·closing·tag·and·put·everything·between·these·tags |
29 | ·················· | 26 | ················in·a·block·macro·named·block.·Here·is·an·example·for·this. |
30 | ························ 1.<[[ref]]UNDEF·tagname> | ||
31 | ················ | 27 | ················ 1.<[[ref]]block·stuff> |
28 | ················ 2. ·<a·href=$email>send·email</a> | ||
29 | ················ 3.<[[ref]]/block> | ||
32 | ················ | 30 | ················ 4. |
31 | ················ 5.<[[ref]]set·morestuff=$email> | ||
32 | ················ 6. | ||
33 | ················ 7.This·works:· · ·<[[ref]]use·stuff·email="jnelson@crl.com"> | ||
34 | ················ 8.But·this·fails:·<[[ref]]use·email> | ||
35 | ················ 9.And·this·fails:·<[[ref]]use·morestuff·email="jnelson@crl.com"> | ||
33 | ················ | 36 | ················*****·Using·parameters·***** |
34 | ················ | 37 | ················More·sophisticated·tags·accept·parameters.·The·option·parameter |
35 | ················ | 38 | ················lets·multiple·metatag·parameters·be·named·and·expanded·inside·the |
39 | ················def·or·blockdef·block: | ||
36 | ························expanded·inside·the·def·or·blockdef·block: | ||
37 | ························ 1. · ·<[[ref]]SET·emailaddr="jnelson@crl.com"> | ||
38 | ················ | 40 | ················*****·Saving·blocks·for·later·***** |
39 | ················ | 41 | ················When·you·are·using·templates,·the·html·should·only·be·written·by |
42 | ················the·template·file.·The·normal·htp·files·should·just·define·macros | ||
43 | ················that·are·used·later·in·the·template.·So·you·may·want·to·write | ||
40 | ························written·by·the·template·file.·The·normal·htp·files | ||
41 | ························should·just·define·macros·that·are·used·later·in·the | ||
42 | ························template.·So·you·may·want·to·write·block·tags·that·just | ||
43 | ··················· | 44 | ················block·tags·that·just·save·the·block·in·a·macro·for·later·use. |
44 | ················ | 45 | ················Although·this·is·possible·with·htp·it·is·quite·tricky,·so·here·we |
45 | ················ | 46 | ················present·the·way·to·do·this: |
46 | ························ 1.<[[ref]]WHILE·[NOT]·conditional> | ||
47 | ························ 2. · ·block | ||
48 | ························ 3.<[[ref]]/WHILE> | ||
49 | ·················· | 47 | ················ 1. ·<[[ref]]set·sect-ctr="0"> |
48 | ················ 2. ·<[[ref]]blockdef·name="section"> | ||
49 | ················ 3. · ·<[[ref]]inc·sect-ctr> | ||
50 | ················ 4. · ·<[[ref]]block·name="sect-${sect-ctr}"·expand·global> | ||
51 | ················ 5. · · ·<[[ref]]use·block·noexpand> | ||
52 | ················ 6. · ·<[[ref]]/block> | ||
53 | ················ 7. ·<[[ref]]/blockdef> | ||
50 | ················ | 54 | ················This·defines·a·block·macro·named·section.·This·macro·uses·a |
51 | ················ | 55 | ················counter·sect-ctr·that·enumerates·the·sections.·It·is·increased·for |
56 | ················every·section·(line·3)·and·then·the·block·macro·name·is·build·from | ||
52 | ························It·is·increased·for·every·section·(line·3)·and·then·the | ||
53 | ························block·macro·name·is·build·from·this·counter.·So·the | ||
54 | ·················· | 57 | ················this·counter.·So·the·first·section·is·stored·in·block·sect-1,·the |
55 | ················ | 58 | ················second·in·sect-2·and·so·on.·The·[[ref]]global·flag·in·line·4·tells |
56 | ················ | 59 | ················htp·that·these·macros·should·be·defined·globally·for·the·remaining |
57 | ························for·the·remaining·run.·Otherwise·they·would·be | ||
58 | ··················· | 60 | ················run.·Otherwise·they·would·be·forgotten·at·the·end·of·the·section |
61 | ················macro. | ||
59 | ················ | 62 | ················The·tricky·part·is·the·[[ref]]expand·and·noexpand·flags·in·line·4 |
60 | ················ | 63 | ················and·5.·Normally·when·you·define·a·block·macro·the·code·between·the |
64 | ················start·and·end·tag·is·literally·copied·into·the·macro·value.·The | ||
61 | ························the·code·between·the·start·and·end·tag·is·literally | ||
62 | ························copied·into·the·macro·value.·The·expansion·takes·place | ||
63 | ·················· | 65 | ················expansion·takes·place·when·the·macro·is·used.·In·this·case·that |
64 | ················ | 66 | ················doesn't·make·sense;·all·macros·sect-1,·sect-2·and·so·on·would·just |
65 | ················ | 67 | ················contain·the·same·value,·namely·<use·block>·and·block·wouldn't·be |
68 | ················defined·anymore·when·the·macros·are·finally·expanded.·Therefore·we | ||
66 | ························wouldn't·be·defined·anymore·when·the·macros·are·finally | ||
67 | ························expanded.·Therefore·we·use·expand·to·expand·the·use·tag | ||
68 | ······················ | 69 | ················use·expand·to·expand·the·use·tag·already·when·sect-1·is·defined. |
69 | ················ | 70 | ················The·noexpand·attribute·of·the·[[ref]]use·tag·is·just·the·opposite |
71 | ················and·prevents·the·contents·of·block·to·be·expanded·twice.·If·you | ||
72 | ················omit·it,·it·would·be·expanded·when·defining·the·sect-1·macro·and | ||
70 | ························the·opposite·and·prevents·the·contents·of·block·to·be | ||
71 | ························expanded·twice.·If·you·omit·it,·it·would·be·expanded | ||
72 | ························when·defining·the·sect-1·macro·and·when·using·it·later | ||
73 | ··················· | 73 | ················when·using·it·later·in·the·template.·Generally·it·is·a·good·idea |
74 | ················ | 74 | ················to·use·noexpand·whenever·you·use·expand·in·a·block·around·it. |
75 | ················ | 75 | ················To·close·this·example·we·show·how·to·expand·the·sect-${sect-ctr} |
76 | ················ | 76 | ················blocks·in·the·template: |
77 | ················ | 77 | ················ 1.<[[ref]]file·include="header.hti"> |
78 | ················ 2. ·<[[ref]]set·sect-ctr="1"> | ||
79 | ················ 3. ·<[[ref]]while·sect-${sect-ctr}> | ||
80 | ················ 4. · ·<[[ref]]use·sect-${sect-ctr}> | ||
81 | ················ 5. · ·<[[ref]]inc·sect-ctr> | ||
82 | ················ 6. ·<[[ref]]/while> | ||
83 | ················ 7.<[[ref]]file·include="footer.hti"> | ||
78 | ················ | 84 | ················The·[[ref]]while·tag·in·line·3·checks·whether·the·macro·sect-$ |
79 | ················ | 85 | ················{sect-ctr}·is·defined.·If·it·is·defined·the·body·is·evaluated, |
86 | ················which·expands·the·macro·and·increases·sect-ctr.·Afterwards·the | ||
87 | ················while·condition·is·checked·again·to·check·for·sect-2·macro.·This | ||
80 | ························is·evaluated,·which·expands·the·macro·and·increases | ||
81 | ························sect-ctr.·Afterwards·the·while·condition·is·checked | ||
82 | ························again·to·check·for·sect-2·macro.·This·repeats·until | ||
83 | ················ | 88 | ················repeats·until·sect-${sect-ctr}·is·not·defined. |
84 | ················ | 89 | ················*****·Conclusions·***** |
85 | ················ | 90 | ················This·closes·our·short·htp·tutorial.·I·hope·you·did·enjoy·it·and |
Max diff block lines reached; 656/13875 bytes (4.73%) of diff not shown. |
Offset 114, 40 lines modified | Offset 114, 14 lines modified | ||
114 | ······<a·class="noline"·href="bugs.html">Bugs</a></td></tr> | 114 | ······<a·class="noline"·href="bugs.html">Bugs</a></td></tr> |
115 | ··</table> | 115 | ··</table> |
116 | ··</div> | 116 | ··</div> |
117 | </td> | 117 | </td> |
118 | <td·bgcolor="#f0f0d0"·rowspan="2"·valign="top"> | 118 | <td·bgcolor="#f0f0d0"·rowspan="2"·valign="top"> |
119 | <h2>syntax</h2> | 119 | <h2>syntax</h2> |
120 | ··<p><code> | 120 | ··<p><code> |
121 | <span·class="htp-tag"><<a·href="quote.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">QUOTE</a>·<span·class="htp-attrib">TAG</span>·<span·class="ebnf">[</span><span·class="htp-attrib">ATTRIBUTE</span>=<span·class="htp-value">VALUE</span>·<span·class="htp-attrib">...</span><span·class="ebnf">]</span>></span><br> | ||
122 | <br> | ||
123 | TITLE·SIZE"><br> | ||
124 | · ·<span·class="htp-tag"><<a·href="if.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">IF</a>·<span·class="htp-attrib">size</span>></span><br> | ||
125 | · · · ·<span·class="htp-tag"><FONT·<span·class="htp-attrib">SIZE</span>=<span·class="htp-value"><span·class="htp-macro">${size}</span></span>></span><br> | ||
126 | · ·<span·class="htp-tag"><<a·href="if.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">/IF</a>></span><br> | ||
127 | · ·<span·class="htp-tag"><<a·href="img.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">IMG</a>·<span·class="htp-attrib">SRC</span>=<span·class="htp-value">pics/<span·class="htp-macro">${src}</span></span>></span><br> | ||
128 | · ·<span·class="htp-tag"><<a·href="use.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">USE</a>·<span·class="htp-attrib">title</span>></span><br> | ||
129 | · ·<span·class="htp-tag"><<a·href="if.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">IF</a>·<span·class="htp-attrib">size</span>></span><br> | ||
130 | · · · ·<span·class="htp-tag"></FONT></span><br> | ||
131 | · ·<span·class="htp-tag"><<a·href="if.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">/IF</a>></span><br> | ||
132 | ·<span·class="htp-tag"><<a·href="def.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">/DEF</a>></span><br> | ||
133 | <br> | ||
134 | ·<span·class="htp-tag"><HEADERIMG·<span·class="htp-attrib">SRC</span>=<span·class="htp-string">"logo.gif"</span>·<span·class="htp-attrib">SIZE</span>=<span·class="htp-string">"+2"</span>·<span·class="htp-attrib">TITLE</span>=<span·class="htp-string">"A·title"</span>></span><br> | ||
135 | <br> | ||
136 | ·<span·class="htp-tag"><HEADERIMG·<span·class="htp-attrib">SRC</span>=<span·class="htp-string">"logo.gif"</span>·<span·class="htp-attrib">TITLE</span>=<span·class="htp-string">"Normal·sized·title"</span>></span><br> | ||
137 | <br> | ||
138 | ·This·will·fail:<br> | ||
139 | ·<span·class="htp-tag"><HEADERIMG·<span·class="htp-attrib">SRC</span>=<span·class="htp-string">"logo.gif"</span>·<span·class="htp-attrib">ALT</span>=<span·class="htp-string">"Our·logo"</span>·<span·class="htp-attrib">TITLE</span>=<span·class="htp-string">"Another·title"</span>></span><br> | ||
140 | <br> | ||
141 | ·Instead,·use·*·like·this:<br> | ||
142 | ·<span·class="htp-tag"><<a·href="def.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">DEF</a>·<span·class="htp-attrib">NAME</span>=<span·class="htp-string">"MYIMG"</span>·<span·class="htp-attrib">OPTION</span>=<span·class="htp-string">"SRC·*"</span>></span><br> | ||
143 | · ·<span·class="htp-tag"><<a·href="img.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">IMG</a>·<span·class="htp-attrib">SRC</span>=<span·class="htp-string">"pics/<span·class="htp-macro">${src}</span>"</span>·<span·class="htp-attrib"><span·class="htp-macro">$*</span></span>></span><br> | ||
144 | ·<span·class="htp-tag"><<a·href="def.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">/DEF</a>></span><br> | ||
145 | · ·<br> | ||
146 | ·<span·class="htp-tag"><MYIMG·<span·class="htp-attrib">SRC</span>=<span·class="htp-string">"logo.gif"</span>·<span·class="htp-attrib">ALT</span>=<span·class="htp-string">"Our·logo"</span>></span><br> | ||
147 | </code></p> | 121 | </code></p> |
148 | <h2>synopsis</h2> | 122 | <h2>synopsis</h2> |
149 | <STRONG>OPT</STRONG>·is·an·htp·tag·that·can·be·used·to·specify·processing | 123 | <STRONG>OPT</STRONG>·is·an·htp·tag·that·can·be·used·to·specify·processing |
150 | options·inside·the·actual·document·being·processed.··The·options·are | 124 | options·inside·the·actual·document·being·processed.··The·options·are |
151 | used·exactly·as·they·would·be·on·the·command-line,·although·they·are·not | 125 | used·exactly·as·they·would·be·on·the·command-line,·although·they·are·not |
152 | preceded·by·a·‘-’·character. | 126 | preceded·by·a·‘-’·character. |
153 | <P> | 127 | <P> |
Offset 1, 62 lines modified | Offset 1, 38 lines modified | ||
1 | [HTP] | 1 | [HTP] |
2 | ******·htp·on-line·reference·:·OPT·****** | 2 | ******·htp·on-line·reference·:·OPT·****** |
3 | Table_of·······*****·syntax·***** | 3 | Table_of·······*****·syntax·***** |
4 | Contents·······<[[ref]]QUOTE·TAG·[ATTRIBUTE=VALUE·...]> | ||
5 | Introduction | ||
6 | License······ TITLE·SIZE"> | ||
7 | Tutorial····· · ·<[[ref]]IF·size> | ||
8 | Usage········ · · · ·<FONT·SIZE=${size}> | ||
9 | HTP·Tags····· · ·<[[ref]]/IF> | ||
10 | ··ALTTEXT·· · ·<[[ref]]IMG·SRC=pics/${src}> | ||
11 | ··BLOCK···· · ·<[[ref]]USE·title> | ||
12 | ··BLOCKDEF· · ·<[[ref]]IF·size> | ||
13 | ··DEF······ · · · ·</FONT> | ||
14 | ··FILE····· · ·<[[ref]]/IF> | ||
15 | 4 | Contents·······*****·synopsis·***** | |
5 | Introduction·OPT·is·an·htp·tag·that·can·be·used·to·specify·processing·options·inside·the | ||
6 | License······actual·document·being·processed.·The·options·are·used·exactly·as·they·would·be | ||
7 | Tutorial·····on·the·command-line,·although·they·are·not·preceded·by·a·‘-’·character. | ||
8 | Usage········Click·here·for·more_information_on_using_customization_options_with_htp. | ||
9 | HTP·Tags | ||
10 | ··ALTTEXT | ||
11 | ··BLOCK | ||
12 | ··BLOCKDEF | ||
13 | ··DEF | ||
14 | ··FILE | ||
15 | ··IF | ||
16 | ··INC | 16 | ··INC |
17 | ··IMG | 17 | ··IMG |
18 | ··IMAGEURL | 18 | ··IMAGEURL |
19 | [>]·OPT | 19 | [>]·OPT |
20 | ··OUTPUT | 20 | ··OUTPUT |
21 | ··QUOTE···· ·This·will·fail: | ||
22 | ·· | 21 | ··QUOTE |
22 | ··SET | ||
23 | ··UNDEF | 23 | ··UNDEF |
24 | ··UNSET | ||
25 | ··USE,_$ | ||
26 | ··WHILE | ||
27 | ··<!--- | ||
28 | History | ||
29 | Wish_list | ||
30 | Bugs | ||
24 | ··UNSET···· ·Instead,·use·*·like·this: | ||
25 | ··USE,_$··· ·<[[ref]]DEF·NAME="MYIMG"·OPTION="SRC·*"> | ||
26 | ··WHILE···· · ·<[[ref]]IMG·SRC="pics/${src}"·$*> | ||
27 | ··<!---···· ·<[[ref]]/DEF> | ||
28 | History······ · | ||
29 | Wish_list···· ·<MYIMG·SRC="logo.gif"·ALT="Our·logo"> | ||
30 | Bugs·········*****·synopsis·***** | ||
31 | ···············OPT·is·an·htp·tag·that·can·be·used·to·specify·processing·options·inside·the | ||
32 | ···············actual·document·being·processed.·The·options·are·used·exactly·as·they·would·be | ||
33 | ···············on·the·command-line,·although·they·are·not·preceded·by·a·‘-’·character. | ||
34 | ···············Click·here·for·more_information_on_using_customization_options_with_htp. | ||
35 | page_source | 31 | page_source |
36 | htp_project | 32 | htp_project |
37 | htp_homepage | 33 | htp_homepage |
38 | hosted·by | 34 | hosted·by |
39 | Sourceforge | 35 | Sourceforge |
40 | HTML·coding | 36 | HTML·coding |
41 | [Powered_by | 37 | [Powered_by |
Offset 114, 40 lines modified | Offset 114, 23 lines modified | ||
114 | ······<a·class="noline"·href="bugs.html">Bugs</a></td></tr> | 114 | ······<a·class="noline"·href="bugs.html">Bugs</a></td></tr> |
115 | ··</table> | 115 | ··</table> |
116 | ··</div> | 116 | ··</div> |
117 | </td> | 117 | </td> |
118 | <td·bgcolor="#f0f0d0"·rowspan="2"·valign="top"> | 118 | <td·bgcolor="#f0f0d0"·rowspan="2"·valign="top"> |
119 | <h2>syntax</h2> | 119 | <h2>syntax</h2> |
120 | ··<p><code> | 120 | ··<p><code> |
121 | <span·class="htp-tag"><<a·href=" | 121 | ·<span·class="htp-tag"><<a·href="def.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">def</a>·<span·class="htp-attrib">name</span>=<span·class="htp-string">"bigfont"</span>></span><br> |
122 | · ·<span·class="htp-tag"><font·<span·class="htp-attrib">size</span>=<span·class="htp-string">"+4"</span>></span><br> | ||
123 | ·<span·class="htp-tag"><<a·href="def.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">/def</a>></span><br> | ||
122 | <br> | 124 | <br> |
125 | ·<span·class="htp-tag"><<a·href="def.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">def</a>·<span·class="htp-attrib">name</span>=<span·class="htp-string">"/bigfont"</span>></span><br> | ||
123 | TITLE·SIZE"><br> | ||
124 | · ·<span·class="htp-tag"><<a·href="if.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">IF</a>·<span·class="htp-attrib">size</span>></span><br> | ||
125 | · · · ·<span·class="htp-tag"><FONT·<span·class="htp-attrib">SIZE</span>=<span·class="htp-value"><span·class="htp-macro">${size}</span></span>></span><br> | ||
126 | · ·<span·class="htp-tag"><<a·href="if.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">/IF</a>></span><br> | ||
127 | · ·<span·class="htp-tag"><<a·href="img.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">IMG</a>·<span·class="htp-attrib">SRC</span>=<span·class="htp-value">pics/<span·class="htp-macro">${src}</span></span>></span><br> | ||
128 | · ·<span·class="htp-tag"><<a·href="use.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">USE</a>·<span·class="htp-attrib">title</span>></span><br> | ||
129 | · ·<span·class="htp-tag"><<a·href="if.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">IF</a>·<span·class="htp-attrib">size</span>></span><br> | ||
130 | · · | 126 | · ·<span·class="htp-tag"></font></span><br> |
131 | · ·<span·class="htp-tag"><<a·href="if.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">/IF</a>></span><br> | ||
132 | ·<span·class="htp-tag"><<a·href="def.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">/ | 127 | ·<span·class="htp-tag"><<a·href="def.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">/def</a>></span><br> |
133 | <br> | 128 | <br> |
129 | ·<span·class="htp-tag"><bigfont></span>Some·large·text<span·class="htp-tag"></bigfont></span><br> | ||
134 | ·<span·class="htp-tag"><HEADERIMG·<span·class="htp-attrib">SRC</span>=<span·class="htp-string">"logo.gif"</span>·<span·class="htp-attrib">SIZE</span>=<span·class="htp-string">"+2"</span>·<span·class="htp-attrib">TITLE</span>=<span·class="htp-string">"A·title"</span>></span><br> | ||
135 | <br> | ||
136 | ·<span·class="htp-tag"><HEADERIMG·<span·class="htp-attrib">SRC</span>=<span·class="htp-string">"logo.gif"</span>·<span·class="htp-attrib">TITLE</span>=<span·class="htp-string">"Normal·sized·title"</span>></span><br> | ||
137 | <br> | ||
138 | ·This·will·fail:<br> | ||
139 | ·<span·class="htp-tag"><HEADERIMG·<span·class="htp-attrib">SRC</span>=<span·class="htp-string">"logo.gif"</span>·<span·class="htp-attrib">ALT</span>=<span·class="htp-string">"Our·logo"</span>·<span·class="htp-attrib">TITLE</span>=<span·class="htp-string">"Another·title"</span>></span><br> | ||
140 | <br> | ||
141 | ·Instead,·use·*·like·this:<br> | ||
142 | ·<span·class="htp-tag"><<a·href="def.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">DEF</a>·<span·class="htp-attrib">NAME</span>=<span·class="htp-string">"MYIMG"</span>·<span·class="htp-attrib">OPTION</span>=<span·class="htp-string">"SRC·*"</span>></span><br> | ||
143 | · ·<span·class="htp-tag"><<a·href="img.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">IMG</a>·<span·class="htp-attrib">SRC</span>=<span·class="htp-string">"pics/<span·class="htp-macro">${src}</span>"</span>·<span·class="htp-attrib"><span·class="htp-macro">$*</span></span>></span><br> | ||
144 | ·<span·class="htp-tag"><<a·href="def.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">/DEF</a>></span><br> | ||
145 | · ·<br> | ||
146 | ·<span·class="htp-tag"><MYIMG·<span·class="htp-attrib">SRC</span>=<span·class="htp-string">"logo.gif"</span>·<span·class="htp-attrib">ALT</span>=<span·class="htp-string">"Our·logo"</span>></span><br> | ||
147 | </code></p> | 130 | </code></p> |
148 | <h2>synopsis</h2> | 131 | <h2>synopsis</h2> |
149 | <P>·The·<STRONG>OUTPUT</STRONG>·tag·can·be·used·to·create·auxillary | 132 | <P>·The·<STRONG>OUTPUT</STRONG>·tag·can·be·used·to·create·auxillary |
150 | files·besides·the·main·HTML·file.··The·text·between·this·tag·and·the | 133 | files·besides·the·main·HTML·file.··The·text·between·this·tag·and·the |
151 | corresponding·</OUTPUT>·tag·is·written·to·output·file.·</P> | 134 | corresponding·</OUTPUT>·tag·is·written·to·output·file.·</P> |
152 | <P>·Normally·the·outputfile·is·cleared·before·writing·to·it,·but·you | 135 | <P>·Normally·the·outputfile·is·cleared·before·writing·to·it,·but·you |
153 | can·use·the·APPEND·attribute·to·extend·an·existing·file.··The·text | 136 | can·use·the·APPEND·attribute·to·extend·an·existing·file.··The·text |
Offset 1, 52 lines modified | Offset 1, 37 lines modified | ||
1 | [HTP] | 1 | [HTP] |
2 | ******·htp·on-line·reference·:·OUTPUT·****** | 2 | ******·htp·on-line·reference·:·OUTPUT·****** |
3 | Table_of·······*****·syntax·***** | 3 | Table_of_Contents············*****·syntax·***** |
4 | Introduction··············· ·<[[ref]]def·name="bigfont"> | ||
5 | License···················· · ·<font·size="+4"> | ||
6 | Tutorial··················· ·<[[ref]]/def> | ||
7 | Usage | ||
8 | HTP·Tags··················· ·<[[ref]]def·name="/bigfont"> | ||
9 | ··ALTTEXT················ · ·</font> | ||
10 | ··BLOCK·················· ·<[[ref]]/def> | ||
11 | ··BLOCKDEF | ||
12 | ··DEF···················· ·<bigfont>Some·large·text</bigfont> | ||
13 | ··FILE···················*****·synopsis·***** | ||
4 | Contents·······<[[ref]]QUOTE·TAG·[ATTRIBUTE=VALUE·...]> | ||
5 | Introduction | ||
6 | License······ TITLE·SIZE"> | ||
7 | Tutorial····· · ·<[[ref]]IF·size> | ||
8 | Usage········ · · · ·<FONT·SIZE=${size}> | ||
9 | HTP·Tags····· · ·<[[ref]]/IF> | ||
10 | ··ALTTEXT·· · ·<[[ref]]IMG·SRC=pics/${src}> | ||
11 | ··BLOCK···· · ·<[[ref]]USE·title> | ||
12 | ··BLOCKDEF· · ·<[[ref]]IF·size> | ||
13 | ··DEF······ · · · ·</FONT> | ||
14 | ··FILE····· · ·<[[ref]]/IF> | ||
15 | ··IF······· ·<[[ref]]/DEF> | ||
16 | ··INC | ||
17 | ··IMG······ ·<HEADERIMG·SRC="logo.gif"·SIZE="+2"·TITLE="A·title"> | ||
18 | ··IMAGEURL | ||
19 | ··OPT······ ·<HEADERIMG·SRC="logo.gif"·TITLE="Normal·sized·title"> | ||
20 | [>]·OUTPUT | ||
21 | ··QUOTE···· ·This·will·fail: | ||
22 | ··SET······ ·<HEADERIMG·SRC="logo.gif"·ALT="Our·logo"·TITLE="Another·title"> | ||
23 | ··UNDEF | ||
24 | ··UNSET···· ·Instead,·use·*·like·this: | ||
25 | ··USE,_$··· ·<[[ref]]DEF·NAME="MYIMG"·OPTION="SRC·*"> | ||
26 | ··WHILE···· · ·<[[ref]]IMG·SRC="pics/${src}"·$*> | ||
27 | ··<!---···· ·<[[ref]]/DEF> | ||
28 | History······ · | ||
29 | Wish_list···· ·<MYIMG·SRC="logo.gif"·ALT="Our·logo"> | ||
30 | Bugs·········*****·synopsis·***** | ||
31 | ···············The·OUTPUT·tag·can·be·used·to·create·auxillary | 14 | ··IF·····················The·OUTPUT·tag·can·be·used·to·create·auxillary |
32 | ···············main·HTML·file.·The·text·between·this·tag·and·the·corresponding·</ | ||
33 | ··············· | 15 | ··INC····················files·besides·the·main·HTML·file.·The·text·between |
16 | ··IMG····················this·tag·and·the·corresponding·</OUTPUT>·tag·is | ||
17 | ··IMAGEURL···············written·to·output·file. | ||
34 | ···············Normally·the·outputfile·is·cleared·before·writing | 18 | ··OPT····················Normally·the·outputfile·is·cleared·before·writing |
35 | 19 | [>]·OUTPUT·················to·it,·but·you·can·use·the·APPEND·attribute·to | |
20 | ··QUOTE··················extend·an·existing·file.·The·text·written·to·the | ||
36 | 21 | ··SET····················file·is·normally·not·expanded,·i.e.·all·tags | |
37 | ···············this·block·are·not·executed·but·written·unmodified·to·the·file. | ||
38 | ···············However,·you·can·use·the·EXPAND·attribute·to·override·this | ||
39 | ···············behaviour. | ||
22 | ··UNDEF··················inside·this·block·are·not·executed·but·written | ||
23 | ··UNSET··················unmodified·to·the·file.·However,·you·can·use·the | ||
24 | ··USE,_$·················EXPAND·attribute·to·override·this·behaviour. | ||
25 | ··WHILE | ||
26 | ··<!--- | ||
27 | History | ||
28 | Wish_list | ||
29 | Bugs | ||
Offset 114, 17 lines modified | Offset 114, 14 lines modified | ||
114 | ······<a·class="noline"·href="bugs.html">Bugs</a></td></tr> | 114 | ······<a·class="noline"·href="bugs.html">Bugs</a></td></tr> |
115 | ··</table> | 115 | ··</table> |
116 | ··</div> | 116 | ··</div> |
117 | </td> | 117 | </td> |
118 | <td·bgcolor="#f0f0d0"·rowspan="2"·valign="top"> | 118 | <td·bgcolor="#f0f0d0"·rowspan="2"·valign="top"> |
119 | <h2>syntax</h2> | 119 | <h2>syntax</h2> |
120 | ··<p><code> | 120 | ··<p><code> |
121 | <span·class="htp-tag"><<a·href="undef.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">UNDEF</a>·<span·class="htp-attrib">tagname</span>></span><br> | ||
122 | <span·class="htp-tag"><<a·href="undef.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">UNDEF</a>·<span·class="htp-attrib">tagname1</span>·<span·class="htp-attrib">tagname2</span>·<span·class="htp-attrib">...</span>·></span><br> | ||
123 | <br> | ||
124 | </code></p> | 121 | </code></p> |
125 | <h2>synopsis</h2> | 122 | <h2>synopsis</h2> |
126 | <STRONG>QUOTE</STRONG>·is·used·to·quote·a·macro·that·would·otherwise | 123 | <STRONG>QUOTE</STRONG>·is·used·to·quote·a·macro·that·would·otherwise |
127 | be·interpreted·by·HTP.··It·may·be·useful·in·conjunction·with·a | 124 | be·interpreted·by·HTP.··It·may·be·useful·in·conjunction·with·a |
128 | surrounding·<a·href="expand.html">EXPAND</a>ed·block·to·prevent·early | 125 | surrounding·<a·href="expand.html">EXPAND</a>ed·block·to·prevent·early |
129 | expansion·of·some·contained·blocks.··Note·that·'$'·evaluation·is·still | 126 | expansion·of·some·contained·blocks.··Note·that·'$'·evaluation·is·still |
130 | done·inside·a·quote·block. | 127 | done·inside·a·quote·block. |
Offset 1, 21 lines modified | Offset 1, 21 lines modified | ||
1 | [HTP] | 1 | [HTP] |
2 | ******·htp·on-line·reference·:·QUOTE·****** | 2 | ******·htp·on-line·reference·:·QUOTE·****** |
3 | Table_of_Contents············*****·syntax·***** | 3 | Table_of_Contents············*****·syntax·***** |
4 | Introduction···············<[[ref]]UNDEF·tagname> | ||
5 | License····················<[[ref]]UNDEF·tagname1·tagname2·...·> | ||
6 | Tutorial | ||
7 | | 4 | Introduction···············*****·synopsis·***** |
8 | | 5 | License····················QUOTE·is·used·to·quote·a·macro·that·would |
9 | | 6 | Tutorial···················otherwise·be·interpreted·by·HTP.·It·may·be·useful |
10 | | 7 | Usage······················in·conjunction·with·a·surrounding·EXPANDed·block |
11 | | 8 | HTP·Tags···················to·prevent·early·expansion·of·some·contained |
12 | ·· | 9 | ··ALTTEXT················blocks.·Note·that·'$'·evaluation·is·still·done |
13 | ·· | 10 | ··BLOCK··················inside·a·quote·block. |
11 | ··BLOCKDEF | ||
12 | ··DEF | ||
13 | ··FILE | ||
14 | ··IF | 14 | ··IF |
15 | ··INC | 15 | ··INC |
16 | ··IMG | 16 | ··IMG |
17 | ··IMAGEURL | 17 | ··IMAGEURL |
18 | ··OPT | 18 | ··OPT |
19 | ··OUTPUT | 19 | ··OUTPUT |
20 | [>]·QUOTE | 20 | [>]·QUOTE |
Offset 114, 23 lines modified | Offset 114, 26 lines modified | ||
114 | ······<a·class="noline"·href="bugs.html">Bugs</a></td></tr> | 114 | ······<a·class="noline"·href="bugs.html">Bugs</a></td></tr> |
115 | ··</table> | 115 | ··</table> |
116 | ··</div> | 116 | ··</div> |
117 | </td> | 117 | </td> |
118 | <td·bgcolor="#f0f0d0"·rowspan="2"·valign="top"> | 118 | <td·bgcolor="#f0f0d0"·rowspan="2"·valign="top"> |
119 | <h2>syntax</h2> | 119 | <h2>syntax</h2> |
120 | ··<p><code> | 120 | ··<p><code> |
121 | · ·File·image.gif·<span·class="htp-tag"><<a·href="file.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">FILE</a>·<span·class="htp-attrib">NAME</span>=<span·class="htp-string">"image.gif"</span>·<span·class="htp-attrib">SIZE</span>=<span·class="htp-value">KBYTE</span>></span> kilobytes<br> | ||
122 | · ·Last·modified·<span·class="htp-tag"><<a·href="file.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">FILE</a>·<span·class="htp-attrib">NAME</span>=<span·class="htp-string">"image.gif"</span>·<span·class="htp-attrib">TIME</span>></span>,·<span·class="htp-tag"><<a·href="file.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">FILE</a>·<span·class="htp-attrib">NAME</span>=<span·class="htp-string">"image.gif"</span>·<span·class="htp-attrib">DATE</span>></span><br> | ||
121 | <span·class="htp-tag"><<a·href="unset.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">unset</a>·<span·class="htp-attrib">macroname</span>></span><br> | ||
122 | <span·class="htp-tag"><<a·href="unset.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">unset</a>·<span·class="htp-attrib">macroname1</span>·<span·class="htp-attrib">macroname2</span>·<span·class="htp-attrib">...</span>·></span><br> | ||
123 | <br> | ||
124 | </code></p> | 123 | </code></p> |
125 | <h2>synopsis</h2> | 124 | <h2>synopsis</h2> |
126 | <STRONG>SET</STRONG>·creates·a·macro·definition·that·can·later·be·expanded | 125 | <STRONG>SET</STRONG>·creates·a·macro·definition·that·can·later·be·expanded |
127 | anywhere·in·the·HTML·document.··To·create·a·macro: | 126 | anywhere·in·the·HTML·document.··To·create·a·macro: |
128 | ··<p><code> | 127 | ··<p><code> |
128 | ·<span·class="htp-tag"><<a·href="def.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">def</a>·<span·class="htp-attrib">name</span>=<span·class="htp-string">"sharedimg"</span>·<span·class="htp-attrib">option</span>=<span·class="htp-string">"name·alt"</span>></span><br> | ||
129 | · ·<span·class="htp-tag"><<a·href="img.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">img</a>·<span·class="htp-attrib">src</span>=<span·class="htp-string">"/home/sharedimages/<span·class="htp-macro">${name}</span>"</span>·<span·class="htp-attrib">alt</span>=<span·class="htp-string">"<span·class="htp-macro">${alt}</span>"</span>></span>;<br> | ||
129 | · | 130 | ·<span·class="htp-tag"><<a·href="def.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">/def</a>></span><br> |
131 | <br> | ||
132 | ·<span·class="htp-tag"><sharedimg·<span·class="htp-attrib">name</span>=<span·class="htp-string">"bubble.gif"</span>·<span·class="htp-attrib">alt</span>=<span·class="htp-string">"Bubble·image"</span>></span><br> | ||
130 | </code></p> | 133 | </code></p> |
131 | <P> | 134 | <P> |
132 | The·macro·"emailaddr"·can·then·be·expanded·later.··The·<A·HREF="use.html"> | 135 | The·macro·"emailaddr"·can·then·be·expanded·later.··The·<A·HREF="use.html"> |
133 | USE</A>·tag·is·used·to·expand·the·macro·outside·a·tag·(i.e.,·into·the·regular | 136 | USE</A>·tag·is·used·to·expand·the·macro·outside·a·tag·(i.e.,·into·the·regular |
134 | text).··If·the·macro·needs·to·be·expanded·inside·a·markup·tag,·use·the | 137 | text).··If·the·macro·needs·to·be·expanded·inside·a·markup·tag,·use·the |
135 | <A·HREF="use.html">'$'</A>·operator. | 138 | <A·HREF="use.html">'$'</A>·operator. |
136 | <P> | 139 | <P> |
Offset 1, 41 lines modified | Offset 1, 38 lines modified | ||
1 | [HTP] | 1 | [HTP] |
2 | ******·htp·on-line·reference·:·SET·****** | 2 | ******·htp·on-line·reference·:·SET·****** |
3 | Table_of | 3 | Table_of·······*****·syntax·***** |
4 | Introduction···············<[[ref]]unset·macroname> | ||
5 | License····················<[[ref]]unset·macroname1·macroname2·...·> | ||
6 | Tutorial | ||
7 | Usage······················*****·synopsis·***** | ||
8 | HTP·Tags···················SET·creates·a·macro·definition·that·can·later·be | ||
9 | ··ALTTEXT················expanded·anywhere·in·the·HTML·document.·To·create | ||
10 | ··BLOCK··················a·macro: | ||
11 | 4 | Contents······· · ·File·image.gif·<[[ref]]FILE·NAME="image.gif"·SIZE=KBYTE> kilobytes | |
5 | Introduction· · ·Last·modified·<[[ref]]FILE·NAME="image.gif"·TIME>,·<[[ref]]FILE | ||
6 | License······NAME="image.gif"·DATE> | ||
7 | Tutorial·····*****·synopsis·***** | ||
8 | Usage········SET·creates·a·macro·definition·that·can·later·be·expanded·anywhere·in·the | ||
9 | HTP·Tags·····HTML·document.·To·create·a·macro: | ||
10 | ··ALTTEXT·· ·<[[ref]]def·name="sharedimg"·option="name·alt"> | ||
11 | ··BLOCK···· · ·<[[ref]]img·src="/home/sharedimages/${name}"·alt="${alt}">; | ||
12 | ··BLOCKDEF· ·<[[ref]]/def> | ||
13 | ··DEF | ||
14 | ··FILE····· ·<sharedimg·name="bubble.gif"·alt="Bubble·image"> | ||
12 | ·· | 15 | ··IF·······The·macro·"emailaddr"·can·then·be·expanded·later.·The·USE·tag·is·used·to |
16 | ··INC······expand·the·macro·outside·a·tag·(i.e.,·into·the·regular·text).·If·the | ||
13 | ··FILE···················The·USE·tag·is·used·to·expand·the·macro·outside·a | ||
14 | ··IF·····················tag·(i.e.,·into·the·regular·text).·If·the·macro | ||
15 | ··I | 17 | ··IMG······macro·needs·to·be·expanded·inside·a·markup·tag,·use·the·'$'·operator. |
16 | ··IMG····················'$'·operator. | ||
17 | ··IMAGEURL· | 18 | ··IMAGEURL·Multiple·macros·can·be·declared·in·a·single·markup·tag,·as·the·second |
18 | ··OPT······ | 19 | ··OPT······syntax·line·shows. |
19 | ··OUTPUT··· | 20 | ··OUTPUT···SET·should·only·be·used·for·a·single·line's·worth·of·text.·Multi-line |
21 | ··QUOTE····macros·can·be·defined·with·the·BLOCK·tag.·The·BLOCK·tag·is·also·useful·if | ||
20 | ··QUOTE··················of·text.·Multi-line·macros·can·be·defined·with·the | ||
21 | [>]·SET····················BLOCK·tag.·The·BLOCK·tag·is·also·useful·if·the | ||
22 | | 22 | [>]·SET······the·macro·contains·a·quotation·character·and·you·don't·want·to·fool |
23 | ··UNDEF····around·with·special·escape·characters. | ||
24 | ··UNSET····Macros·can·be·redefined·by·using·another·SET·command·with·the·same·macro | ||
25 | ··USE,_$···name.·The·prior·definition·will·be·destroyed,·however.·Also,·the·macro | ||
26 | ··WHILE····can·be·removed·(destroyed)·with·the·UNSET·tag. | ||
27 | ··<!--- | ||
28 | History | ||
29 | Wish_list | ||
30 | Bugs | ||
23 | ··UNSET··················want·to·fool·around·with·special·escape | ||
24 | ··USE,_$·················characters. | ||
25 | ··WHILE··················Macros·can·be·redefined·by·using·another·SET | ||
26 | ··<!---··················command·with·the·same·macro·name.·The·prior | ||
27 | History····················definition·will·be·destroyed,·however.·Also,·the | ||
28 | Wish_list··················macro·can·be·removed·(destroyed)·with·the·UNSET | ||
29 | Bugs·······················tag. | ||
Offset 16, 10 lines modified | Offset 16, 10 lines modified | ||
16 | <tr><td><b>Phone:</b></td><td>+49·761·203-8243</td></tr> | 16 | <tr><td><b>Phone:</b></td><td>+49·761·203-8243</td></tr> |
17 | <tr><td><b>Fax:</b></td><td>+49·761·203-8242</td></tr> | 17 | <tr><td><b>Fax:</b></td><td>+49·761·203-8242</td></tr> |
18 | </table> | 18 | </table> |
19 | ···</td></tr> | 19 | ···</td></tr> |
20 | ··</table> | 20 | ··</table> |
21 | ··<hr> | 21 | ··<hr> |
22 | ··Copyright·by·<a·href="mailto:webmaster@domain.com">Joe·Doe</a>.<br> | 22 | ··Copyright·by·<a·href="mailto:webmaster@domain.com">Joe·Doe</a>.<br> |
23 | ··last·updated· | 23 | ··last·updated·Fri·May·16,·2025 |
24 | ·</body> | 24 | ·</body> |
25 | </html> | 25 | </html> |
Offset 1, 8 lines modified | Offset 1, 8 lines modified | ||
1 | ···············******·Jochen·Hoenicke·****** | 1 | ···············******·Jochen·Hoenicke·****** |
2 | Navigation·bar·[Photo] | 2 | Navigation·bar·[Photo] |
3 | Main···········Room:··Bld.52·00-020 | 3 | Main···········Room:··Bld.52·00-020 |
4 | Example········Phone:·+49·761·203-8243 | 4 | Example········Phone:·+49·761·203-8243 |
5 | ···············Fax:···+49·761·203-8242 | 5 | ···············Fax:···+49·761·203-8242 |
6 | =============================================================================== | 6 | =============================================================================== |
7 | Copyright·by·Joe_Doe. | 7 | Copyright·by·Joe_Doe. |
8 | last·updated· | 8 | last·updated·Fri·May·16,·2025 |
Offset 5, 9 lines modified | Offset 5, 9 lines modified | ||
5 | <meta·name="Generator"·content="htp·1.19"> | 5 | <meta·name="Generator"·content="htp·1.19"> |
6 | </head> | 6 | </head> |
7 | <body> | 7 | <body> |
8 | This·page·was·produced·by·htp. | 8 | This·page·was·produced·by·htp. |
9 | <hr> | 9 | <hr> |
10 | Copyright·by·Joe·Doe, | 10 | Copyright·by·Joe·Doe, |
11 | <a·href="mailto:webmaster@domain.com">webmaster@domain.com</a>, | 11 | <a·href="mailto:webmaster@domain.com">webmaster@domain.com</a>, |
12 | last·updated· | 12 | last·updated·Fri·May·16,·2025 |
13 | </body> | 13 | </body> |
Offset 1, 3 lines modified | Offset 1, 3 lines modified | ||
1 | This·page·was·produced·by·htp. | 1 | This·page·was·produced·by·htp. |
2 | =============================================================================== | 2 | =============================================================================== |
3 | Copyright·by·Joe·Doe,·webmaster@domain.com,·last·updated· | 3 | Copyright·by·Joe·Doe,·webmaster@domain.com,·last·updated·Fri·May·16,·2025 |
Offset 13, 10 lines modified | Offset 13, 10 lines modified | ||
13 | <p> | 13 | <p> |
14 | As·you·can·see·the·file·contains·almost·only·the·contents. | 14 | As·you·can·see·the·file·contains·almost·only·the·contents. |
15 | </p> | 15 | </p> |
16 | ···</td></tr> | 16 | ···</td></tr> |
17 | ··</table> | 17 | ··</table> |
18 | ··<hr> | 18 | ··<hr> |
19 | ··Copyright·by·<a·href="mailto:webmaster@domain.com">Joe·Doe</a>.<br> | 19 | ··Copyright·by·<a·href="mailto:webmaster@domain.com">Joe·Doe</a>.<br> |
20 | ··last·updated· | 20 | ··last·updated·Fri·May·16,·2025 |
21 | ·</body> | 21 | ·</body> |
22 | </html> | 22 | </html> |
Offset 1, 6 lines modified | Offset 1, 6 lines modified | ||
1 | Navigation·bar·*****·Here·is·the·content·***** | 1 | Navigation·bar·*****·Here·is·the·content·***** |
2 | Main···········As·you·can·see·the·file·contains·almost·only·the·contents. | 2 | Main···········As·you·can·see·the·file·contains·almost·only·the·contents. |
3 | Example | 3 | Example |
4 | =============================================================================== | 4 | =============================================================================== |
5 | Copyright·by·Joe_Doe. | 5 | Copyright·by·Joe_Doe. |
6 | last·updated· | 6 | last·updated·Fri·May·16,·2025 |
Offset 13, 10 lines modified | Offset 13, 10 lines modified | ||
13 | ·<p> | 13 | ·<p> |
14 | ·As·you·can·see·the·file·contains·almost·only·the·contents. | 14 | ·As·you·can·see·the·file·contains·almost·only·the·contents. |
15 | ·</p> | 15 | ·</p> |
16 | ···</td></tr> | 16 | ···</td></tr> |
17 | ··</table> | 17 | ··</table> |
18 | ··<hr> | 18 | ··<hr> |
19 | ··Copyright·by·<a·href="webmaster@domain.com">Joe·Doe</a>.<br> | 19 | ··Copyright·by·<a·href="webmaster@domain.com">Joe·Doe</a>.<br> |
20 | ··last·updated· | 20 | ··last·updated·Fri·May·16,·2025 |
21 | ·</body> | 21 | ·</body> |
22 | </html> | 22 | </html> |
Offset 1, 6 lines modified | Offset 1, 6 lines modified | ||
1 | Navigation·bar·*****·Here·are·the·contents·***** | 1 | Navigation·bar·*****·Here·are·the·contents·***** |
2 | Main···········As·you·can·see·the·file·contains·almost·only·the·contents. | 2 | Main···········As·you·can·see·the·file·contains·almost·only·the·contents. |
3 | Example | 3 | Example |
4 | =============================================================================== | 4 | =============================================================================== |
5 | Copyright·by·Joe_Doe. | 5 | Copyright·by·Joe_Doe. |
6 | last·updated· | 6 | last·updated·Fri·May·16,·2025 |
Offset 125, 27 lines modified | Offset 125, 30 lines modified | ||
125 | The·macro·is·subsequently·not·available·for·use·in·the·pre-processed·files. | 125 | The·macro·is·subsequently·not·available·for·use·in·the·pre-processed·files. |
126 | (Note·that·simply·redefining·the·macro·with·another·<A·HREF="set.html">SET</A>·or | 126 | (Note·that·simply·redefining·the·macro·with·another·<A·HREF="set.html">SET</A>·or |
127 | <A·HREF="block.html">BLOCK</A>·definition·with·the·same·name·is·acceptable.··The | 127 | <A·HREF="block.html">BLOCK</A>·definition·with·the·same·name·is·acceptable.··The |
128 | old·macro·definition·will·be·removed·automatically.) | 128 | old·macro·definition·will·be·removed·automatically.) |
129 | <P> | 129 | <P> |
130 | For·example: | 130 | For·example: |
131 | ··<p><code> | 131 | ··<p><code> |
132 | ·<span·class="htp-tag"><<a·href="def.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">def</a>·<span·class="htp-attrib">name</span>=<span·class="htp-string">"sharedimg"</span>·<span·class="htp-attrib">option</span>=<span·class="htp-string">"name·alt"</span>></span><br> | ||
133 | · ·<span·class="htp-tag"><<a·href="img.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">img</a>·<span·class="htp-attrib">src</span>=<span·class="htp-string">"/home/sharedimages/<span·class="htp-macro">${name}</span>"</span>·<span·class="htp-attrib">alt</span>=<span·class="htp-string">"<span·class="htp-macro">${alt}</span>"</span>></span>;<br> | ||
132 | <span·class="htp-tag"><<a·href="file.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">file</a>·<span·class="htp-attrib">include</span>=<span·class="htp-string">"header.hti"</span>></span><br> | ||
133 | ·<span·class="htp-tag"><<a·href="set.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">set</a>·<span·class="htp-attrib">sect-ctr</span>=<span·class="htp-string">"1"</span>></span><br> | ||
134 | ·<span·class="htp-tag"><<a·href="while.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">while</a>·<span·class="htp-attrib">sect-<span·class="htp-macro">${sect-ctr}</span></span>></span><br> | ||
135 | · ·<span·class="htp-tag"><<a·href="use.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">use</a>·<span·class="htp-attrib">sect-<span·class="htp-macro">${sect-ctr}</span></span>></span><br> | ||
136 | · ·<span·class="htp-tag"><<a·href="inc.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">inc</a>·<span·class="htp-attrib">sect-ctr</span>></span><br> | ||
137 | ·<span·class="htp-tag"><<a·href=" | 134 | ·<span·class="htp-tag"><<a·href="def.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">/def</a>></span><br> |
138 | < | 135 | <br> |
136 | ·<span·class="htp-tag"><sharedimg·<span·class="htp-attrib">name</span>=<span·class="htp-string">"bubble.gif"</span>·<span·class="htp-attrib">alt</span>=<span·class="htp-string">"Bubble·image"</span>></span><br> | ||
139 | </code></p> | 137 | </code></p> |
140 | <P> | 138 | <P> |
141 | More·than·one·macro·may·be·removed·in·the·same·tag: | 139 | More·than·one·macro·may·be·removed·in·the·same·tag: |
142 | ··<p><code> | 140 | ··<p><code> |
143 | <span·class="htp-tag"><a·<span·class="htp-attrib">href</span>=<span·class="htp-string">"mailto:<span·class="htp-macro">$email</span>"</span>></span>mailto·hyperlink<span·class="htp-tag"></a></span><br> | ||
144 | <span·class="htp-tag">< | 141 | ·<span·class="htp-tag"><<a·href="set.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">set</a>·<span·class="htp-attrib">sect-ctr</span>=<span·class="htp-string">"0"</span>></span><br> |
142 | ·<span·class="htp-tag"><<a·href="blockdef.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">blockdef</a>·<span·class="htp-attrib">name</span>=<span·class="htp-string">"section"</span>></span><br> | ||
143 | · ·<span·class="htp-tag"><<a·href="inc.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">inc</a>·<span·class="htp-attrib">sect-ctr</span>></span><br> | ||
144 | · ·<span·class="htp-tag"><<a·href="block.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">block</a>·<span·class="htp-attrib">name</span>=<span·class="htp-string">"sect-<span·class="htp-macro">${sect-ctr}</span>"</span>·<span·class="htp-attrib">expand</span>·<span·class="htp-attrib">global</span>></span><br> | ||
145 | · · ·<span·class="htp-tag"><<a·href="use.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">use</a>·<span·class="htp-attrib">block</span>·<span·class="htp-attrib">noexpand</span>></span><br> | ||
146 | · ·<span·class="htp-tag"><<a·href="block.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">/block</a>></span><br> | ||
147 | ·<span·class="htp-tag"><<a·href="blockdef.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">/blockdef</a>></span><br> | ||
145 | </code></p> | 148 | </code></p> |
146 | <p> | 149 | <p> |
147 | </td> | 150 | </td> |
148 | </tr> | 151 | </tr> |
149 | <tr> | 152 | <tr> |
150 | <td·width="20%"·bgcolor="white"·valign="bottom"> | 153 | <td·width="20%"·bgcolor="white"·valign="bottom"> |
151 | ·<table·border="0"·cellspacing="0"·cellpadding="0"·width="100%"> | 154 | ·<table·border="0"·cellspacing="0"·cellpadding="0"·width="100%"> |
Offset 1, 33 lines modified | Offset 1, 34 lines modified | ||
1 | [HTP] | 1 | [HTP] |
2 | ******·htp·on-line·reference·:·UNSET·****** | 2 | ******·htp·on-line·reference·:·UNSET·****** |
3 | Table_of | 3 | Table_of·······*****·syntax·***** |
4 | 4 | Contents······· · ·<[[ref]]SET·emailaddr="jnelson@crl.com"> | |
5 | Introduction·*****·synopsis·***** | ||
6 | License······UNSET·removes·(or·deletes)·a·macro·and·it's·definition.·The·macro | ||
7 | Tutorial·····is·subsequently·not·available·for·use·in·the·pre-processed·files. | ||
8 | Usage········(Note·that·simply·redefining·the·macro·with·another·SET·or·BLOCK | ||
9 | HTP·Tags·····definition·with·the·same·name·is·acceptable.·The·old·macro | ||
10 | ··ALTTEXT··definition·will·be·removed·automatically.) | ||
11 | ··BLOCK····For·example: | ||
12 | ··BLOCKDEF· ·<[[ref]]def·name="sharedimg"·option="name·alt"> | ||
13 | ··DEF······ · ·<[[ref]]img·src="/home/sharedimages/${name}"·alt="${alt}">; | ||
14 | ··FILE····· ·<[[ref]]/def> | ||
15 | ··IF | ||
16 | ··INC······ ·<sharedimg·name="bubble.gif"·alt="Bubble·image"> | ||
5 | License····················*****·synopsis·***** | ||
6 | Tutorial···················UNSET·removes·(or·deletes)·a·macro·and·it's | ||
7 | Usage······················definition.·The·macro·is·subsequently·not | ||
8 | HTP·Tags···················available·for·use·in·the·pre-processed·files. | ||
9 | ··ALTTEXT················(Note·that·simply·redefining·the·macro·with | ||
10 | ··BLOCK··················another·SET·or·BLOCK·definition·with·the·same·name | ||
11 | ··BLOCKDEF···············is·acceptable.·The·old·macro·definition·will·be | ||
12 | ··DEF····················removed·automatically.) | ||
13 | ··FILE···················For·example: | ||
14 | ··IF·····················<[[ref]]file·include="header.hti"> | ||
15 | ··INC···················· ·<[[ref]]set·sect-ctr="1"> | ||
16 | ··IMG···················· ·<[[ref]]while·sect-${sect-ctr}> | ||
17 | ··IMAGEURL··············· · ·<[[ref]]use·sect-${sect-ctr}> | ||
18 | ··OPT···················· · ·<[[ref]]inc·sect-ctr> | ||
19 | ··OUTPUT················· ·<[[ref]]/while> | ||
20 | ··QUOTE··················<[[ref]]file·include="footer.hti"> | ||
21 | ·· | 17 | ··IMG······More·than·one·macro·may·be·removed·in·the·same·tag: |
22 | ··UNDEF··················tag: | ||
23 | [>]·UNSET··················<a·href="mailto:$email">mailto·hyperlink</a> | ||
24 | ··USE,_$·················<a·href="http://$domain/~${username}/">another | ||
25 | ·· | 18 | ··IMAGEURL· ·<[[ref]]set·sect-ctr="0"> |
19 | ··OPT······ ·<[[ref]]blockdef·name="section"> | ||
20 | ··OUTPUT··· · ·<[[ref]]inc·sect-ctr> | ||
21 | ··QUOTE···· · ·<[[ref]]block·name="sect-${sect-ctr}"·expand·global> | ||
22 | ··SET······ · · ·<[[ref]]use·block·noexpand> | ||
23 | ··UNDEF···· · ·<[[ref]]/block> | ||
24 | [>]·UNSET···· ·<[[ref]]/blockdef> | ||
25 | ··USE,_$ | ||
26 | ··WHILE | ||
26 | ··<!--- | 27 | ··<!--- |
27 | History | 28 | History |
28 | Wish_list | 29 | Wish_list |
29 | Bugs | 30 | Bugs |
Offset 114, 18 lines modified | Offset 114, 15 lines modified | ||
114 | ······<a·class="noline"·href="bugs.html">Bugs</a></td></tr> | 114 | ······<a·class="noline"·href="bugs.html">Bugs</a></td></tr> |
115 | ··</table> | 115 | ··</table> |
116 | ··</div> | 116 | ··</div> |
117 | </td> | 117 | </td> |
118 | <td·bgcolor="#f0f0d0"·rowspan="2"·valign="top"> | 118 | <td·bgcolor="#f0f0d0"·rowspan="2"·valign="top"> |
119 | <h2>syntax</h2> | 119 | <h2>syntax</h2> |
120 | ··<p><code> | 120 | ··<p><code> |
121 | · ·<span·class="htp-tag"><<a·href="set.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">SET</a>·<span·class="htp-attrib">emailaddr</span>=<span·class="htp-string">"jnelson@crl.com"</span>></span><br> | ||
121 | <span·class="htp-tag"><<a·href="while.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">WHILE</a>·<span·class="ebnf">[</span><span·class="htp-attrib">NOT</span><span·class="ebnf">]</span>·<span·class="htp-attrib">conditional</span>></span><br> | ||
122 | · ·block<br> | ||
123 | <span·class="htp-tag"><<a·href="while.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">/WHILE</a>></span><br> | ||
124 | <br> | ||
125 | </code></p> | 122 | </code></p> |
126 | <h2>synopsis</h2> | 123 | <h2>synopsis</h2> |
127 | <strong>USE</strong>·will·expand·macros·that·have·been·previously | 124 | <strong>USE</strong>·will·expand·macros·that·have·been·previously |
128 | declared·with·either·<A·HREF="set.html">SET</A>·or·<A | 125 | declared·with·either·<A·HREF="set.html">SET</A>·or·<A |
129 | HREF="block.html">BLOCK</A>.··USE·can·only·be·used·outside·of·other | 126 | HREF="block.html">BLOCK</A>.··USE·can·only·be·used·outside·of·other |
130 | markup·tags. | 127 | markup·tags. |
131 | <p>·If·you·USE·a·block·macro·the·value·of·expanded·block·macros·will | 128 | <p>·If·you·USE·a·block·macro·the·value·of·expanded·block·macros·will |
Offset 1, 65 lines modified | Offset 1, 73 lines modified | ||
1 | [HTP] | 1 | [HTP] |
2 | ******·htp·on-line·reference·:·USE,·$·****** | 2 | ******·htp·on-line·reference·:·USE,·$·****** |
3 | Table_of·······*****·syntax·***** | 3 | Table_of·······*****·syntax·***** |
4 | Contents······· · ·<[[ref]]SET·emailaddr="jnelson@crl.com"> | ||
5 | Introduction·*****·synopsis·***** | ||
4 | Contents·······<[[ref]]WHILE·[NOT]·conditional> | ||
5 | Introduction· · ·block | ||
6 | License······<[[ref]]/WHILE> | ||
7 | Tutorial | ||
8 | Usage········*****·synopsis·***** | ||
9 | | 6 | License······USE·will·expand·macros·that·have·been·previously·declared·with |
10 | | 7 | Tutorial·····either·SET·or·BLOCK.·USE·can·only·be·used·outside·of·other |
11 | | 8 | Usage········markup·tags. |
12 | | 9 | HTP·Tags·····If·you·USE·a·block·macro·the·value·of·expanded·block·macros |
13 | ·· | 10 | ··ALTTEXT··will·be·further·parsed·by·htp.·This·is·maybe·not·what·you |
14 | ·· | 11 | ··BLOCK····want,·for·example,·if·the·use·is·inside·a·block·which·expands |
15 | ·· | 12 | ··BLOCKDEF·itself.·You·can·use·the·noexpand·attribute·to·prevent·further |
13 | ··DEF······expansion. | ||
16 | ·· | 14 | ··FILE·····USE·will·accept·additional·parameters,·which·are·"local" |
17 | ··I | 15 | ··IF·······macros·for·the·expanded·macro.·This·is·only·valid·for·BLOCK |
18 | ··I | 16 | ··INC······macros.·Macros·created·using·SET·cannot·have·parameters |
17 | ··IMG······passed.·For·example: | ||
19 | ··OPT······example: | ||
20 | ··OUTPUT··· 1. · ·<[[ref]]unset·email_addr·home_url·login_name> | ||
21 | ·· | 18 | ··IMAGEURL·(See·below·for·a·description·of·the·'$'·operator.)·The·example |
22 | ·· | 19 | ··OPT······on·line·7·works·because·"stuff"·has·been·declared·as·a·block |
23 | ·· | 20 | ··OUTPUT···macro,·and·the·tag·is·passing·the·"email"·macro·to·the·"stuff" |
24 | ··U | 21 | ··QUOTE····macro.·Line·8·fails·because·the·"email"·macro·is·unavailable |
25 | | 22 | ··SET······once·the·block·macro·is·completely·expanded,·and·cannot·be |
26 | ·· | 23 | ··UNDEF····passed·to·a·SET·macro. |
27 | ·· | 24 | ··UNSET····Note·that·the·"email"·macro·is·available·to·other·macros·or |
28 | | 25 | [>]·USE,_$···included·files·called·within·the·"stuff"·block. |
29 | | 26 | ··WHILE····Inside·a·markup·tag,·like·IMG,·A·(anchor),·or·any·other |
30 | | 27 | ··<!---····standard·HTML·or·htp·tag,·the·'$'·operator·must·be·used.·The |
31 | ···············be·immediately·followed·by·the·macro·name,·which·may·or·may·not | ||
32 | ···············be·surrounded·by·curly·braces.·When·htp·encounters·this·it | ||
33 | 28 | History······'$'·should·be·immediately·followed·by·the·macro·name,·which | |
29 | Wish_list····may·or·may·not·be·surrounded·by·curly·braces.·When·htp | ||
30 | Bugs·········encounters·this·it·replaces·the·macro·name·by·the·contents·of | ||
34 | ···············further·processing·the·contents. | 31 | ···············the·macro·without·further·processing·the·contents. |
35 | ··············· 1.<a·href="mailto:$email">mailto·hyperlink</a> | ||
36 | ··············· | 32 | ··············· 1. ·<[[ref]]set·sect-ctr="0"> |
33 | ··············· 2. ·<[[ref]]blockdef·name="section"> | ||
34 | ··············· 3. · ·<[[ref]]inc·sect-ctr> | ||
35 | ··············· 4. · ·<[[ref]]block·name="sect-${sect-ctr}"·expand·global> | ||
36 | ··············· 5. · · ·<[[ref]]use·block·noexpand> | ||
37 | ··············· 6. · ·<[[ref]]/block> | ||
38 | ··············· 7. ·<[[ref]]/blockdef> | ||
37 | ···············The·use·of·curly·braces·is·encouraged,·since·it·is·more·robust | 39 | ···············The·use·of·curly·braces·is·encouraged,·since·it·is·more·robust |
38 | ···············and·should·never·cause·confusion·with·surrounding·text.·If·no | 40 | ···············and·should·never·cause·confusion·with·surrounding·text.·If·no |
39 | ···············curly·braces·are·used·the·macro·name·consists·either·of·a | 41 | ···············curly·braces·are·used·the·macro·name·consists·either·of·a |
40 | ···············punctuation·character·or·the·maximum·sequence·of | 42 | ···············single·punctuation·character·or·the·maximum·sequence·of |
41 | ···············digits,·"-"·and·"_"·that·follows·it. | 43 | ···············letters,·digits,·"-"·and·"_"·that·follows·it. |
42 | ···············If·a·'$'·character·needs·to·be·kept·in·the·final·output,·and | 44 | ···············If·a·'$'·character·needs·to·be·kept·in·the·final·output,·and |
43 | ···············interpreted·as·a·macro·name,·it·must·be·escaped·by·another | 45 | ···············not·interpreted·as·a·macro·name,·it·must·be·escaped·by·another |
44 | ···············character.·This·is·especially·true·for·PHP·code. | 46 | ···············'$'·character.·This·is·especially·true·for·PHP·code. |
45 | ···············If·the·'$'·macro·is·the·only·text·in·the·attribute's·value, | 47 | ···············If·the·'$'·macro·is·the·only·text·in·the·attribute's·value, |
46 | ···············will·automatically·surround·it·with·quotation·marks·to | 48 | ···············htp·will·automatically·surround·it·with·quotation·marks·to |
47 | ···············spaces·from·delimiting·the·text·as·if·it·were | 49 | ···············prevent·spaces·from·delimiting·the·text·as·if·it·were |
48 | ···············attributes.·If·the·'$'·macro·is·surrounded·by·other·text·(as·in | ||
49 | ···············the·two·examples·above),·quotation·marks·are·not·automatically | ||
50 | ··············· | 50 | ···············additional·markup·attributes.·If·the·'$'·macro·is·surrounded |
51 | ···············by·other·text·(as·in·the·two·examples·above),·quotation·marks | ||
52 | ···············are·not·automatically·supplied. | ||
51 | ···············Note·that·a·'$'·macro·can·be·placed·anywhere·in·a·markup·tag | 53 | ···············Note·that·a·'$'·macro·can·be·placed·anywhere·in·a·markup·tag |
52 | ···············can·be·nested.·This·is·valid: | 54 | ···············and·can·be·nested.·This·is·valid: |
53 | ··············· | 55 | ···············<[[ref]]file·include="header.hti"> |
56 | ··············· ·<[[ref]]set·sect-ctr="1"> | ||
57 | ··············· ·<[[ref]]while·sect-${sect-ctr}> | ||
58 | ··············· · ·<[[ref]]use·sect-${sect-ctr}> | ||
59 | ··············· · ·<[[ref]]inc·sect-ctr> | ||
60 | ··············· ·<[[ref]]/while> | ||
61 | ···············<[[ref]]file·include="footer.hti"> | ||
54 | ···············The·tagName·macro·can·contain·any·tag·name,·even·a·self- | 62 | ···············The·tagName·macro·can·contain·any·tag·name,·even·a·self- |
55 | ···············metatag.·Note·that·$ctr·is·expanded·before·the·valueX | 63 | ···············defined·metatag.·Note·that·$ctr·is·expanded·before·the·valueX |
56 | ···············expanded,·so·assuming·that·ctr·was·set·to·1·it·will | 64 | ···············macro·is·expanded,·so·assuming·that·ctr·was·set·to·1·it·will |
57 | ···············value1. | 65 | ···············expand·value1. |
Offset 114, 39 lines modified | Offset 114, 41 lines modified | ||
114 | ······<a·class="noline"·href="bugs.html">Bugs</a></td></tr> | 114 | ······<a·class="noline"·href="bugs.html">Bugs</a></td></tr> |
115 | ··</table> | 115 | ··</table> |
116 | ··</div> | 116 | ··</div> |
117 | </td> | 117 | </td> |
118 | <td·bgcolor="#f0f0d0"·rowspan="2"·valign="top"> | 118 | <td·bgcolor="#f0f0d0"·rowspan="2"·valign="top"> |
119 | <h2>syntax</h2> | 119 | <h2>syntax</h2> |
120 | ··<p><code> | 120 | ··<p><code> |
121 | <span·class="htp-tag"><<a·href="file.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">file</a>·<span·class="htp-attrib">include</span>=<span·class="htp-string">"header.hti"</span>></span><br> | ||
122 | ·<span·class="htp-tag"><<a·href="set.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">set</a>·<span·class="htp-attrib">sect-ctr</span>=<span·class="htp-string">"1"</span>></span><br> | ||
123 | ·<span·class="htp-tag"><<a·href="while.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">while</a>·<span·class="htp-attrib">sect-<span·class="htp-macro">${sect-ctr}</span></span>></span><br> | ||
124 | · ·<span·class="htp-tag"><<a·href="use.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">use</a>·<span·class="htp-attrib">sect-<span·class="htp-macro">${sect-ctr}</span></span>></span><br> | ||
125 | · ·<span·class="htp-tag"><<a·href="inc.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">inc</a>·<span·class="htp-attrib">sect-ctr</span>></span><br> | ||
126 | ·<span·class="htp-tag"><<a·href="while.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">/while</a>></span><br> | ||
127 | <span·class="htp-tag"><<a·href="file.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">file</a>·<span·class="htp-attrib">include</span>=<span·class="htp-string">"footer.hti"</span>></span><br> | ||
128 | </code></p> | 121 | </code></p> |
129 | <h2>synopsis</h2> | 122 | <h2>synopsis</h2> |
130 | <STRONG>WHILE</STRONG>·is·the·building·block·for·repeated·processing. | 123 | <STRONG>WHILE</STRONG>·is·the·building·block·for·repeated·processing. |
131 | The·basic·form·is·shown·above. | 124 | The·basic·form·is·shown·above. |
132 | <P> | 125 | <P> |
133 | "Conditional"·is·either·a·"compare"·or·"is·defined"·operation. | 126 | "Conditional"·is·either·a·"compare"·or·"is·defined"·operation. |
134 | A·compare·operator·is·a·test·of·the·value·of·a·macro·against·a·literal·string. | 127 | A·compare·operator·is·a·test·of·the·value·of·a·macro·against·a·literal·string. |
135 | If·the·NOT·tag·is·present·in·the·WHILE·markup,·the·evaluation·of·the | 128 | If·the·NOT·tag·is·present·in·the·WHILE·markup,·the·evaluation·of·the |
136 | conditional·is·reversed: | 129 | conditional·is·reversed: |
137 | ··<p><code> | 130 | ··<p><code> |
138 | <span·class="htp-tag"><a·<span·class="htp-attrib">href</span>=<span·class="htp-string">"mailto:<span·class="htp-macro">$email</span>"</span>></span>mailto·hyperlink<span·class="htp-tag"></a></span><br> | ||
139 | <span·class="htp-tag"><a·<span·class="htp-attrib"> | 131 | ·<span·class="htp-tag"><<a·href="def.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">def</a>·<span·class="htp-attrib">name</span>=<span·class="htp-string">"sharedimg"</span>·<span·class="htp-attrib">option</span>=<span[·...·truncated·by·diffoscope;·len:·37,·SHA:·e09912519b132811f30da9278a59c551d2e40a2207413a2dc6036406858a79c6·...·]></span><br> |
132 | · ·<span·class="htp-tag"><<a·href="img.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">img</a>·<span·class="htp-attrib">src</span>=<span·class="htp-string">"/home/sharedimages/<span·class="htp-macro">${name}</span>"</span>·<span·class="htp-attrib">alt</span>=<span·class="htp-string">"<span·class="htp-macro">${alt}</span>"</span>></span>;<br> | ||
133 | ·<span·class="htp-tag"><<a·href="def.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">/def</a>></span><br> | ||
134 | <br> | ||
135 | ·<span·class="htp-tag"><sharedimg·<span·class="htp-attrib">name</span>=<span·class="htp-string">"bubble.gif"</span>·<span·class="htp-attrib">alt</span>=<span·class="htp-string">"Bubble·image"</span>></span><br> | ||
140 | </code></p> | 136 | </code></p> |
141 | <P> | 137 | <P> |
142 | Just·as·with·<a·href="if.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">IF</a>·you·can·also·check·for·a | 138 | Just·as·with·<a·href="if.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">IF</a>·you·can·also·check·for·a |
143 | macro's·existance: | 139 | macro's·existance: |
144 | ··<p><code> | 140 | ··<p><code> |
145 | · | 141 | ·<span·class="htp-tag"><<a·href="set.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">set</a>·<span·class="htp-attrib">sect-ctr</span>=<span·class="htp-string">"0"</span>></span><br> |
142 | ·<span·class="htp-tag"><<a·href="blockdef.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">blockdef</a>·<span·class="htp-attrib">name</span>=<span·class="htp-string">"section"</span>></span><br> | ||
143 | · ·<span·class="htp-tag"><<a·href="inc.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">inc</a>·<span·class="htp-attrib">sect-ctr</span>></span><br> | ||
144 | · ·<span·class="htp-tag"><<a·href="block.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">block</a>·<span·class="htp-attrib">name</span>=<span·class="htp-string">"sect-<span·class="htp-macro">${sect-ctr}</span>"</span>·<span·class="htp-attrib">expand</span>·<span·class="htp-attrib">global</span>></span><br> | ||
145 | · · ·<span·class="htp-tag"><<a·href="use.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">use</a>·<span·class="htp-attrib">block</span>·<span·class="htp-attrib">noexpand</span>></span><br> | ||
146 | · ·<span·class="htp-tag"><<a·href="block.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">/block</a>></span><br> | ||
147 | ·<span·class="htp-tag"><<a·href="blockdef.html"·><img·src="pic/manual.png"·border=0·alt="[ref]"·width="10"·height="10">/blockdef</a>></span><br> | ||
146 | </code></p> | 148 | </code></p> |
147 | <P> | 149 | <P> |
148 | If·the·condition·is·true,·the·block·is·evaluated·and·afterwards·the | 150 | If·the·condition·is·true,·the·block·is·evaluated·and·afterwards·the |
149 | WHILE·tag·is·evaluated·again.··If·the·'$'-operator·is·used·in·the | 151 | WHILE·tag·is·evaluated·again.··If·the·'$'-operator·is·used·in·the |
150 | WHILE·tag·it·is·also·reevaluated·on·each·iteration. | 152 | WHILE·tag·it·is·also·reevaluated·on·each·iteration. |
151 | <P> | 153 | <P> |
152 | A·loop·block·<EM>must</EM>·be·closed·with·the·/WHILE·tag. | 154 | A·loop·block·<EM>must</EM>·be·closed·with·the·/WHILE·tag. |
Offset 1, 39 lines modified | Offset 1, 38 lines modified | ||
1 | [HTP] | 1 | [HTP] |
2 | ******·htp·on-line·reference·:·WHILE·****** | 2 | ******·htp·on-line·reference·:·WHILE·****** |
3 | Table_of | 3 | Table_of·······*****·syntax·***** |
4 | Contents·······*****·synopsis·***** | ||
5 | Introduction·WHILE·is·the·building·block·for·repeated·processing.·The·basic | ||
6 | License······form·is·shown·above. | ||
7 | Tutorial·····"Conditional"·is·either·a·"compare"·or·"is·defined"·operation.·A | ||
8 | Usage········compare·operator·is·a·test·of·the·value·of·a·macro·against·a | ||
9 | HTP·Tags·····literal·string.·If·the·NOT·tag·is·present·in·the·WHILE·markup, | ||
4 | Introduction···············<[[ref]]file·include="header.hti"> | ||
5 | License···················· ·<[[ref]]set·sect-ctr="1"> | ||
6 | Tutorial··················· ·<[[ref]]while·sect-${sect-ctr}> | ||
7 | Usage······················ · ·<[[ref]]use·sect-${sect-ctr}> | ||
8 | HTP·Tags··················· · ·<[[ref]]inc·sect-ctr> | ||
9 | ··ALTTEXT················ ·<[[ref]]/while> | ||
10 | ··BLOCK··················<[[ref]]file·include="footer.hti"> | ||
11 | ··BLOCKDEF···············*****·synopsis·***** | ||
12 | ··DEF····················WHILE·is·the·building·block·for·repeated | ||
13 | ··FILE···················processing.·The·basic·form·is·shown·above. | ||
14 | ··IF·····················"Conditional"·is·either·a·"compare"·or·"is | ||
15 | ··INC····················defined"·operation.·A·compare·operator·is·a·test | ||
16 | ··IMG····················of·the·value·of·a·macro·against·a·literal·string. | ||
17 | ··IMAGEURL···············If·the·NOT·tag·is·present·in·the·WHILE·markup,·the | ||
18 | ·· | 10 | ··ALTTEXT··the·evaluation·of·the·conditional·is·reversed: |
19 | ··OUTPUT·················<a·href="mailto:$email">mailto·hyperlink</a> | ||
20 | ··QUOTE··················<a·href="http://$domain/~${username}/">another | ||
21 | ·· | 11 | ··BLOCK···· ·<[[ref]]def·name="sharedimg"·option="name·alt"> |
12 | ··BLOCKDEF· · ·<[[ref]]img·src="/home/sharedimages/${name}"·alt="${alt}">; | ||
13 | ··DEF······ ·<[[ref]]/def> | ||
14 | ··FILE | ||
15 | ··IF······· ·<sharedimg·name="bubble.gif"·alt="Bubble·image"> | ||
22 | ·· | 16 | ··INC······Just·as·with·[[ref]]IF·you·can·also·check·for·a·macro's |
23 | ··UNSET··················macro's·existance: | ||
24 | ··USE,_$················· · ·<${tagName}·${attrName}=${value$ctr}> | ||
25 | [>]·WHILE··················If·the·condition·is·true,·the·block·is·evaluated | ||
26 | ··<!---··················and·afterwards·the·WHILE·tag·is·evaluated·again. | ||
27 | History····················If·the·'$'-operator·is·used·in·the·WHILE·tag·it·is | ||
28 | | 17 | ··IMG······existance: |
18 | ··IMAGEURL· ·<[[ref]]set·sect-ctr="0"> | ||
19 | ··OPT······ ·<[[ref]]blockdef·name="section"> | ||
20 | ··OUTPUT··· · ·<[[ref]]inc·sect-ctr> | ||
21 | ··QUOTE···· · ·<[[ref]]block·name="sect-${sect-ctr}"·expand·global> | ||
22 | ··SET······ · · ·<[[ref]]use·block·noexpand> | ||
23 | ··UNDEF···· · ·<[[ref]]/block> | ||
24 | ··UNSET···· ·<[[ref]]/blockdef> | ||
25 | ··USE,_$···If·the·condition·is·true,·the·block·is·evaluated·and·afterwards | ||
26 | [>]·WHILE····the·WHILE·tag·is·evaluated·again.·If·the·'$'-operator·is·used·in | ||
27 | ··<!---····the·WHILE·tag·it·is·also·reevaluated·on·each·iteration. | ||
29 | | 28 | History······A·loop·block·must·be·closed·with·the·/WHILE·tag. |
29 | Wish_list | ||
30 | Bugs | ||