Re: htdig: Templates?


Jesse op den Brouw (jesse@crytonII.st.hhs.nl)
Wed, 14 Jan 1998 12:06:51 +0100


Here is what you need: someone else wrote it to list
some time ago. I digged it up now. Have fun!
--jesse

Jim Serio wrote:
>
> I posted this last month with no response. If anyone
> can tell me at least how and where to deinfe the
> template, that would be great. The documentation
> makes reference to the templates but does not
> say where you initially define the custom templates.
>

cut here--------------------------------------------------------------
>From the file: htsearch/TemplateList.cc you can extract the builtin-long
template:

==============================long-test.html======================
<dl><dt><strong><a href="$(URL)">$(TITLE)</a></strong>$(STARSLEFT)
</dt><dd>$(EXCERPT)<br>
<br><STRONG>IT WORKS!!!</STRONG><br>
<i><a href="$(URL)">$(URL)</a></i>
<font size=-1>$(MODIFIED), $(SIZE) bytes</font>
</dd></dl>
=========================end long-test.html=====================

Save this as "long-test.html" into your common directory, then put the
line
in your htdig.conf file:

template_map: Test test /full/path/to/file/long-test.html

Now add the option to select "Test" within the standard search.html:
Right after: <option value=builtin-short>Short
Add: <option value=test>Test

This should give you exactly the same results as the builtin template,
but
with the line "IT WORKS!!!" between the excerpt and the URL (that part
is
NOT in the source code :-) ). I found that I HAD to have the full-path
listed in the config file, or it would bomb. YMMV.

Hope it helps

Steve
sjd@mindspring.com
again--------------------------------------------------------------------------

---------------------------------------------------------------------
J. op den Brouw Johanna Westerdijkplein 75
Haagse Hogeschool 2521 EN DEN HAAG
Faculty of Engineering Netherlands
Electrical Engineering +31 70 4458936
-------------------- J.E.J.opdenBrouw@st.hhs.nl ---------------------

Linux - because reboots are for hardware changes
----------------------------------------------------------------------
To unsubscribe from the htdig mailing list, send a message to
htdig-request@sdsu.edu containing the single word "unsubscribe" in
the body of the message.



This archive was generated by hypermail 2.0b3 on Sat Jan 02 1999 - 16:25:31 PST