Added in G-Cows version 1.1
type (variable
):
text + Cows expressions
endtype;
Text is copied verbatim into variable
with an exception:
everything enclosed between @@ characters will be treated as an
expression and its value will be echoed.
In other words, writing @@ expression @@ inside Type Mode corresponds to writing echo (expression); outside Type Mode.
Variable can't be supplied via the $ function (Section 9.6).
<cows> author1 = "-- Joan Gilbert"; author2 = "-- Albert Schweitzer"; type (content): <p> Every civilizing step in history has been ridiculed as 'sentimental', 'impractical', or 'womanish', etc., by those whose fun, profit or convenience was at stake. @@ author1 @@ <p> It is the fate of every truth to be an object of ridicule when it is first acclaimed. It was once considered foolish to suppose that black men were really human beings and ought to be treated as such. What was once foolish has now become a recognized truth. Today it is considered as exaggeration to proclaim constant respect for every form of life as being the serious demand of a rational ethic. But the time is coming when people will be amazed that the human race existed so long before it recognized that thoughtless injury to life is incompatible with real ethics. Ethics is in its unqualified form extended responsibility to everything that has life. @@ author2 @@ <HR> Updated: @@ date ("#d #M #y") @@ endtype; type: <html> <body> ... layout tags ... @@ content @@ ... other layout tags ... </body </html> endtype; </cows>
The type mode is used twice: first we type page content into variable content
; then, we type the whole HTML page into output file.
This manual can be downloaded from http://www.g-cows.org/.