Sophie

Sophie

distrib > Mandriva > 2010.2 > i586 > by-pkgid > 9f7023c9aebe2149a9eb898636964197 > files > 7

gtml-3.5.4-6mdv2010.1.noarch.rpm

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">

<html lang="en">

<head>
   <title>GTML - an HTML pre-processor</title>
   <meta name="Author" content="Andrew E. Schulman,Bruno Beaufils, Gihan Perera">
   <meta name="Generator" content="GTML 3.5.4">
   <meta name="Keywords" content=
     "HTML pre-processor, perl, script, web site design, templates, free
      software, GPL">
   <meta name="Description" content=
     "GTML is a simple yet powerful HTML pre-processor, which has a lot of
      features to design AND maintain entire web sites. It's syntax is very
      close to the C language preprocessor one. Some of its features are: use
      of macros, conditionnal processing, file inclusion, sitemap generation
      and much more. It is written in perl.">
   <link rel="Begin" type="text/html" href="http://sourceforge.net/projects/gtml/">
   <link rel="Next" type="text/html" href="gtml_ref.html">
   <link rel="Stylesheet" type="text/css" href="gtml.css">
</head>

<body text="#000033">

<!-- ---------- Title line ---------- -->

<center>
  <table border="0" width="95%" bgcolor="#ffffcc" cellpadding="5" cellspacing="0" align="center">
    <tr>
      <td align="left">
      <font size="2" face='Arial,Helvetica'>
      &nbsp;
      </font>
      </td>
      <td align="center"><font color="#000066" face="Verdana,Arial,Helvetica" size="+3">
      <b>GTML - an HTML pre-processor</b>
      </td>
      <td align="right">
      <font size="2" face='Arial,Helvetica'>
      &nbsp;
      <a href="gtml_ref.html">&gt;&gt;</a>
      </font>
      </td>
    </tr>
</table>
</center>

<center>
<table width="75%" border="0" cellpadding="10">
  <tr valign="top">
    <td>

<a name="toc2"></a>
<p>
<ul>
  <li><a href="#intro">Introduction</a>
  <li><a href="#how">How does <code>GTML</code> work ?</a>
  <li><a href="#you">Is <code>GTML</code> for you ?</a>
  <li><a href="#features"><code>GTML</code> features.</a>
  <li><a href="#download">Downloading <code>GTML</code></a>
  <li><a href="#running">Running <code>GTML</code></a>
  <li><a href="#other">Other HTML pre-processors</a>
  <li><a href="#license">Terms of license</a>
  <li><a href="#history">A little bit of <code>GTML</code> history</a>
</ul>

<p><hr>

<a name="intro"></a>
<p>HTML is a powerful markup language for individual Web pages, but it
has some serious limitations for maintaining entire Web <em>sites</em>
(i.e. a collection of Web pages which needs to be kept consistent).

<p><code>GTML</code> is an HTML pre-processor which adds some extra features
specially designed for maintaining multiple Web pages.


<a name="how"></a>
<h2>How does it work?</h2>

<p>You embed <code>GTML</code> commands among the HTML in your source files.
<code>GTML</code> reads and processes the <code>GTML</code> commands, but leaves the
rest of the text unchanged (so it will work straight away on your
existing Web pages).

<p>HTML files generated by <code>GTML</code> are just like any other HTML files.
Because <code>GTML</code> doesn't attempt to interpret your HTML commands in
any way, it's fully compatible with <em>all</em> versions of HTML, and
doesn't require any specific browser or server.


<a name="you"></a>
<h2>Is <code>GTML</code> for you?</h2>

<p>If you write the HTML in your Web pages by hand using a simple text
editor, then you'll find <code>GTML</code> useful. If, on the other hand,
you use a sophisticated graphical tool to generate your HTML, you
probably won't be able to use <code>GTML</code>. There are three reasons for this:
<ul>
  <li>Your sophisticated tool won't understand the <code>GTML</code>
      commands, and might even complain violently about them.
  <li><code>GTML</code> operates in a command-line <em>batch</em> mode, and your
      sophisticated tool probably operates from a graphical environment.
  <li>The <em>source</em> for <code>GTML</code> is in files ending in <strong>.gtm</strong>
      (or <strong>.gtml</strong>), and it generates the <strong>.html</strong>
      files. Your sophisticated tool probably generates the <strong>.html</strong>
      files itself. 
</ul>


<a name="features"></a>
<h2>Features</h2>

<p>Here are some of the things you can do with <code>GTML</code>:
<ul>
  <li>Create a <em>project file</em> with the names of all your Web pages, so
      you can update them all with one simple click or command. 
  <li>Process only files which sources have changed directly, or with the help
      of makefiles. 
  <li>Generate a <code>makefile</code> to control the process of your Web pages,
      based on their dependencies.
      <img src="new.gif" alt="[** NEW **]">
  <li>Give a specific alias to a filename, useable as constants, so that it is
      easy to move files and have links preserved.
  <li>Specify a tree-like hierarchy of Web pages, so you can add Next,
      Previous and Up links automatically to your site.
  <li>Automatically generate a map of your site, with the possibility of
      customizing the way this table of contents will look like.
      <img src="new.gif" alt="[** NEW **]">
  <li>Use named constants for HTML fragments to save typing, ensure
      consistency and make changes easily. 
  <li>Use environment variables as named constants.
  <li>Include header, footer and other common files into all your HTML
      files. <em>This doesn't require Server-Side Includes</em>. 
  <li>Include timestamps (in any format you like) to show the time of last
      process, or of last modification. 
  <li>Use conditional commands to create different versions of the output
      under different circumstances. 
  <li>Generate output to different directories to generate different versions
      of your site (for example, a Frames version and a non-Frames version). 
  <li>Change extensions of output files from <strong>.html</strong> to whatever
      you want, so that you may, for instance, use MultiViews options of
      Apache server, or create non-HTML files.
      <img src="new.gif" alt="[** NEW **]">
  <li>Guard special characters `&lt;', `&gt;' and `&amp;' in normal text so
      that they don't get confused with HTML commands.
  <li>Define your own characters translations, so that you may easily input
      your non-ASCII characters into <code>GTML</code> source.
      <img src="new.gif" alt="[** NEW **]">
  <li>Embed <code>Perl</code> or <code>shell</code> code into your source, so
      that you may easily generate pages with computed information.
      <img src="new.gif" alt="[** NEW **]">
  <li>Generate pages with all superfluous HTML code removed, so that readers
      retrieve them faster and may save bandwidth.
      <img src="new.gif" alt="[** NEW **]">
</ul>

<p>All the <code>GTML</code> features and commands are described on the
<a href="gtml_ref.html"><code>GTML</code> Reference page</a>. 


<a name="download"></a>
<h2>Downloading <code>GTML</code></h2>

<p><code>GTML</code> is written in Perl. If you don't have Perl, it's easy to
<a href="http://www.perl.com/pace/pub/perldocs/latest.html">obtain it</a> on
<a href="http://www.perl.com">perl.com</a>. 

<p>There are two methods to download <code>GTML</code>:
<ul>
  <li><a href="gtml">Download <code>GTML</code></a> Perl script, and save it to a file called
      <code><strong>gtml.pl</strong></code>. <em>If you're running this under UNIX, edit
      the first line to point to the location of your version of
      Perl</em>, and give the execute right to the file. 
  <li>Download <code>GTML</code> archives containing Perl script as well as
      documentations. Archives are available in
      <a href="ftp://ftp.lifl.fr/pub/users/beaufils/gtml/gtml.zip">zip format</a>
      or <a href="ftp://ftp.lifl.fr/pub/users/beaufils/gtml/gtml.tar.gz">gzipped tar format</a>.
</ul>

<p>The home page of <code>GTML</code> is at <code><strong><a href="http://sourceforge.net/projects/gtml/">http://sourceforge.net/projects/gtml/</a></strong></code>,
and archives may be found at <code><strong><a href="ftp://ftp.lifl.fr/pub/users/beaufils/gtml/">ftp://ftp.lifl.fr/pub/users/beaufils/gtml/</a></strong></code>.


<a name="running"></a>
<h2>Running <code>GTML</code></h2>

<p><code>GTML</code> source files end in <strong>.gtm</strong> (or <strong>.gtml</strong>), not
<strong>.html</strong>. If you're using <code>GTML</code> on existing HTML files, simply
rename them with the ending <strong>.gtm</strong> (or <strong>.gtml</strong>).

<p><code>GTML</code> is run from the command line, like this:
<pre>
     perl gtml.pl fred.gtm harry.gtm bill.gtm
</pre>

<p>(The UNIX version won't need the <code>Perl</code> at the front, so long as
the script is executable.)

<p>The output of this command will be in <code><strong>fred.html</strong></code>,
<code><strong>harry.html</strong></code> and <code><strong>bill.html</strong></code>. 

<p>If you have a <a href="gtml_ref.html#project"><code>GTML</code> project file</a>,
you include this on the command line. In this case, it's not necessary to list
any of the files in the project as well. 

<p>Remember that you <a href="gtml_ref.html#optiond">can use <code>-D</code></a> on the
command line to create named constants. You can have as many <code>-D</code>
options as you like. Make sure they appear <em>before</em> the file names to
which they apply. For example, if you say:
<pre>
     perl gtml.pl -DNAME=Fred fred.gtm harry.gtm -DTYPE=car bill.gtm
</pre>
then <code>NAME</code> is defined for all three files and <code>TYPE</code>
is defined for <code><strong>bill.gtm</strong></code> only.

<p>By default, <code>GTML</code> will try to process some
<a href="gtml_ref.html#project">project file</a>. It will look at these <em>configuration</em>
files in this order:
<ul>
  <li><code><strong>$HOME/.gtmlrc</strong></code>
  <li><code><strong>$HOME/gtml.conf</strong></code>
  <li><code><strong>.gtmlrc</strong></code>
  <li><code><strong>gtml.conf</strong></code>
</ul>

<p>Thoses files, if they exist, are parsed before command line is processed.

<p>You may have a look at the source of the documentation pages of <code>GTML</code> in
the <a href="src">source directory</a>. The project file is called
<a href="src/gtml.gtp"><code><strong>gtml.gtp</strong></code></a>.


<a name="other"></a>
<h2>Other HTML pre-processors</h2>

<p>Here is a list of other HTML pre-processors that I know of, in
case <code>GTML</code> will not satisfy your needs:
<ul>
  <li><a href="http://chakotay.ist.org">Chpp</a>
  <li><a href="http://frontier.userland.com">Frontier</a>
  <li><a href="http://www.metahtml.com">Meta-HTML</a>
  <li><a href="http://www.php.net">PHP</a>
  <li><a href="http://www.qml.org/">QML</a>
  <li><a href="http://artho.com/webtools">Webtools</a>
  <li><a href="http://www.engelschall.com/sw/wml/">WML</a>
  <li><a href="http://www.geocities.com/Tokyo/1474/wpp">Wpp</a>
</ul>


<a name="license"></a>
<h2>Licensing</h2>

<p><code>GTML</code> is distributed under the <a href="COPYING">GNU General Public License</a>
(GPL). 

<p>Copyright &copy; 1996-1999
<a href="http://www.pobox.com/~gihan">Gihan Perera</a>
 (<a href="mailto:gihan@pobox.com">gihan@pobox.com</a>)

<p>Copyright &copy; 1999
<a href="http://www.lifl.fr/~beaufils">Bruno Beaufils</a>
 (<a href="mailto:beaufils@lifl.fr">beaufils@lifl.fr</a>)

<p>This program is free software; you can redistribute it and/or modify it
under the terms of the GNU General Public License as published by the Free
Software Foundation; either version 2 of the License, or (at your option) any
later version.

<p>This program is distributed in the hope that it will be useful, but WITHOUT
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
FOR A PARTICULAR PURPOSE.  See the
<a href="http://www.gnu.org/copyleft/gpl.html">GNU General Public License</a>
for more details.


<a name="history"></a>
<h2>Some history</h2>

<p>For a long time I was looking for a way of maintaining some of the sites 
that I set up for the research team which I am member of. I wanted to get a 
tool which would enable me to easily change the look and feel of all pages of 
a site, and easily move pages of a site from one location to another.

<p>I then used all my favourite search engines on the web, and found some
pages, describing such tools. I tried some. They all missed something, from ease
of use, to important features. When I tried <code>GTML</code>, from Gihan, I found
it was pretty cool, but lacking some important features that I needed.

<p>I wrote to Gihan asking him to add those features which I needed, since I 
had no Perl programming skill. He told me that he doesn't have time to do that
 in the near future. So I decided to read his code, and to learn Perl with his
script.

<p>The script was pretty well written and I learnt Perl, or at least understand
how <code>GTML</code> worked very fast. It was then easy to add the features that I needed in it. I then asked Gihan if he would mind if I distribute <code>GTML</code> under the
GNU General Public License, since his license policy was not as open as GPL,
and he accepted.

<p>Then I just updated some of the docs, prepared an archive, in the
<a href="http://www.gnu.org">GNU</a> spirit, and that was it.

<p>My biggest question was to understand where the name of the tool come from,
and after some reflexions I got two possible answers:
<ul>
  <li>`<code><strong>G</strong></code>' is the letter just before H, and <code>GTML</code> source production
      comes just before HTML file one.
  <li>`<code><strong>G</strong></code>' is the first letter of Gihan's first name.
</ul>

<p>Well this is not a question anymore, Gihan told me the truth. Guess
what? I found it: the first of my two previous hypotheses is the right  
one. (Well I hope that as time goes by it will be interpreted as GNU
<code>:-)</code>  

<p>After I distributed it on my web pages, and after announcing it only on
<a href="http://www.freshmeat.net">Freshmeat</a>,
I got some feedback from users coming from all around the world. I added some
features which were asked of me, but realized that the source of the script
needed some reorganization, and that there were some bugs in <code>GTML</code>.

<blockquote>
I have done this source reorganization, and so have been able to fix bugs,
and add a lot of fancy features. So now I'm waiting for users' feedback, in 
order to verify that I did not add bugs <code>:-)</code>, and that <code>GTML</code> is now
sufficiently stable.
</blockquote>

<p>In one month or so I hope to be able to say that it does. So I
<em>really</em> need your help for that, please <em>give me some feedback!</em>.

<p>I will not add any features, before the next <em>stable</em> release.

<p>I hope my version of <code>GTML</code> will help you as it helps me.

<p>--Bruno, <em>31 August 1999</em>

    </td>
  </tr>
</table>
</center>

<center>
<table borde="0" width="100%" align="center">
  <tr>
    <td align="left">
    <font size="2" face="Arial,Helvetica" color="#000066">
    This page has been accessed <!--#echo var="URL_COUNT"--> times since
    <!--#echo var="URL_COUNT_RESET"-->.
    </font>
    </td>
    <td align="right">
    <font size="2" face="Arial,Helvetica">
    &nbsp;
    <a href="sitemap.html">Sitemap</a>
    &nbsp;
    <a href="gtml_ref.html">Reference &gt;&gt;</a>
    </font>
    </td>
  </tr>
</table>
</center>

<center>
<hr width="100%">
<table align="center" width="100%" border="0">
  <tr>
    <td align="left" valign="top">
    <font size="2" face="Arial,Helvetica" color="#000066">
    <a href="http://sourceforge.net/projects/gtml/">GTML home page</a><br>
    <em>Last modification: 1999/9/12 at 19:44</em><br>
    </font>
    </td>
    <td align="right">
    <font size="2" face="Arial,Helvetica" color="#000066">
    Copyright &copy; 1996-1999 <a href="http://www.pobox.com/~gihan">Gihan Perera</a>&nbsp;
    (<a href="mailto:gihan@pobox.com">gihan@pobox.com</a>)<br>
    Copyright &copy; 1999 <a href="http://www.lifl.fr/~beaufils">Bruno Beaufils</a>&nbsp;
    (<a href="mailto:beaufils@lifl.fr">beaufils@lifl.fr</a>)<br>
    Copyright &copy; 2004 <a href="http://home.comcast.net/~andrex">Andrew E. Schulman</a>&nbsp;
    (<a href="mailto:schulman@users.sourceforge.net">schulman@users.sourceforge.net</a>)<br>
    </font>
    </td>
  </tr>
</table>
</center>

</body>

</html>

<!-- Local Variables: -->
<!-- mode: html-helper-mode -->
<!-- End: -->