Files
httrack/html/dev.html
Xavier Roche 58e8aec88f The doc footer drops the patents chicklet, and two pages escape the check (#1157)
* The doc footer drops the patents chicklet, and two pages escape the check

The shipped doc footer had drifted from httrack.com's: no End Software
Patents chicklet, no <small> around the copyright line so it rendered a
size larger than the site's, and a .5rem top margin holding it off the
panel's black edge. doc.css now takes site.css's .sitefooter shape (flex
row, line-height 1.3, no top margin), with the chicklet at the far end.

The chicklet ships as html/images/esp_chicklet.png and is referenced
relatively rather than by the site's absolute src, since these pages are
read off the install directory where that would be a broken image and an
outbound request from a local page. The link points at the canonical
https://endsoftwarepatents.org/innovating-without-patents/, where the
site's http URL lands after two redirects, and uses target="_blank"
because _new is not a target keyword.

The footer also becomes its own doc-chrome region, as the masthead did in
#1154. It used to sit inside the generated bottom region, which index.html
and guide.html do not have: both build their own sidebar and take the
masthead alone, so their footers were hand-maintained and unchecked.
Corrupting index.html's footer text passes --check on master and fails
after this; a page that loses the markers is reported rather than crashing
the generator.

The year stays hardcoded: --check diffs the regenerated chrome against the
shipped bytes, so computing it would red CI every 1st of January.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Signed-off-by: Xavier Roche <roche@httrack.com>

* Report a malformed chrome region per page instead of aborting the run

A page whose region markers are half-present reached region()'s bare
SystemExit, which named no page and stopped the sweep, so a drift on any
later page went unreported. Catch it per page, print the page, and carry
on. A duplicate marker pair is now rejected too: region() substitutes the
first pair only, so a trailing second one shipped unchecked on any region,
the masthead included.

Also add rel="noopener" to the chicklet link, and reword two comments: the
footer's contrast note no longer claims .8em now that <small> nests inside
it, and doc.css points at site.css's .sitefooter as the shape it mirrors.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Signed-off-by: Xavier Roche <roche@httrack.com>

---------

Signed-off-by: Xavier Roche <roche@httrack.com>
Co-authored-by: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-08-11 11:28:05 +00:00

119 lines
4.2 KiB
HTML

<!DOCTYPE html>
<html lang="en">
<head>
<!-- doc-chrome:head -->
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="description" content="Using HTTrack from a script, from the callbacks, or through the libhttrack library.">
<link rel="stylesheet" href="doc.css">
<script src="doc.js" defer></script>
<!-- /doc-chrome:head -->
<title>Programming with HTTrack</title>
</head>
<body>
<!-- doc-chrome:top -->
<!-- doc-chrome:masthead -->
<a class="skip" href="#main">Skip to content</a>
<header class="masthead">
<img src="images/wordmark.svg" width="400" height="36" alt="HTTrack Website Copier">
<div class="tagline">Free software offline browser</div>
</header>
<!-- /doc-chrome:masthead -->
<div class="wrap">
<nav class="toc" aria-label="Documentation">
<h2>On this page</h2>
<ul>
<li><a href="#programming">Programming</a></li>
<li><a href="#technical-references">Technical references</a></li>
</ul>
<h2>Start here</h2>
<ul>
<li><a href="guide.html">Interface guide</a></li>
<li><a href="faq.html">FAQ and troubleshooting</a></li>
<li><a href="abuse.html">Using HTTrack responsibly</a></li>
</ul>
<h2>Command line</h2>
<ul>
<li><a href="cmdguide.html">Command-line guide</a></li>
<li><a href="httrack.man.html">Option reference</a></li>
<li><a href="filters.html">Filter syntax</a></li>
</ul>
<h2>Developers</h2>
<ul>
<li><a href="dev.html" aria-current="page" class="here">Programming</a></li>
<li><a href="library.html">libhttrack API</a></li>
<li><a href="plug.html">Callbacks</a></li>
<li><a href="scripting.html">Scripting</a></li>
<li><a href="cache.html">Cache format</a></li>
<li><a href="changes.html">Change report format</a></li>
</ul>
<h2>More</h2>
<ul>
<li><a href="fcguide.html">Users Guide (3.10)</a></li>
<li><a href="contact.html">Contact and credits</a></li>
<li><a href="index.html">All documentation</a></li>
</ul>
</nav>
<main id="main">
<!-- /doc-chrome:top -->
<h1>HTTrack Programming page</h1>
<br>
HTTrack can be used as a third-party program in batch files, or as library.
Depending on your needs, you may look:
<br><br>
<h3 id="programming">Programming</h3>
<ul>
<li><a href="scripting.html">Simple use: scripting examples using the httrack commandline program</a></li><br>
You can use tens of options (see <tt>httrack --help</tt>) to control precisely the mirror, and used embedded commands in httrack.
<br><br>
<li><a href="plug.html">More complex use: plugging external C functions to the httrack library</a></li><br>
For advanced functions, you may have to use external C wrappers ; for example when adding advanced crawl features, such as "tuned" filestructure type
<br><i>Important note: please read the license information of httrack before developing add-ons</i><br />
See also the page <a href="plug_330.html">for versions prior to 3.41</a>
<br><br>
<li><a href="library.html">Advanced use: using the library</a></li><br>
The library can be used to write graphical GUIs for httrack, or to run mirrors from a program.
<br><i>Important note: please read the license information of httrack before developing add-ons</i>
</ul>
<h3 id="technical-references">Technical references</h3>
<ul>
<li><a href="cache.html">Cache format</a></li><br>
HTTrack stores original HTML data and references to downloaded files in a cache, located in the hts-cache directory.
This page describes the HTTrack cache format.
<li><a href="changes.html">Change report format</a></li><br>
With --changes, HTTrack writes hts-changes.json describing what the crawl left new, changed, unchanged and gone
compared to the previous mirror. This page describes that file.
</ul>
<br><br>
<!-- doc-chrome:bottom -->
</main>
</div>
<dialog id="zoom" aria-label="Enlarged image"><img src="" alt=""></dialog>
<!-- /doc-chrome:bottom -->
<!-- doc-chrome:footer -->
<footer>
<small>&copy; 1998-2026 Xavier Roche &amp; other contributors - Web Design: Leto Kauler.</small>
<a href="https://endsoftwarepatents.org/innovating-without-patents/" target="_blank" rel="noopener" title="This site is innovating without patents!"><img src="images/esp_chicklet.png" width="91" height="17" alt="End Software Patents"></a>
</footer>
<!-- /doc-chrome:footer -->
</body>
</html>