]> sjero.net Git - wget/blobdiff - doc/wget.texi
[svn] Implemented and documented new -E / --html-extension / html_extension option.
[wget] / doc / wget.texi
index c61e0c7b7c8f642674814de2d60db2ffb833484f..816e79eb36d8bb35ae03fac3f9c3527c6fe6464d 100644 (file)
@@ -706,6 +706,27 @@ current directory).
 @section HTTP Options
 
 @table @samp
+@cindex .html extension
+@item -E
+@itemx --html-extension
+If a file of type @samp{text/html} is downloaded and the URL does not
+end with the regexp "\.[Hh][Tt][Mm][Ll]?", this option will cause the
+suffix @samp{.html} to be appended to the local filename.  This is
+useful, for instance, when you're you're mirroring a remote site that
+uses @samp{.asp} pages, but you want the mirrored pages to be viewable
+on your stock Apache server.  Another good use for this is when you're
+downloading the output of CGIs.  A URL like
+@samp{http://site.com/article.cgi?25} will be saved as
+@file{article.cgi?25.html}.
+
+Note that filenames changed in this way will be re-downloaded every time
+you re-mirror a site, because wget can't tell that the local
+@file{@var{X}.html} file corresponds to remote URL @samp{@var{X}} (since
+it doesn't yet know that the URL produces output of type
+@samp{text/html}.  To prevent this re-downloading, you must use
+@samp{-k} and @samp{-K} so that the original version of the file will be
+saved as @file{@var{X}.orig} (@xref{Recursive Retrieval Options}).
+
 @cindex http user
 @cindex http password
 @cindex authentication
@@ -1785,6 +1806,10 @@ Turn globbing on/off -- the same as @samp{-g}.
 @item header = @var{string}
 Define an additional header, like @samp{--header}.
 
+@item html_extension = on/off
+Add a @samp{.html} extension to @samp{text/html} files without it, like
+@samp{-E}.
+
 @item http_passwd = @var{string}
 Set @sc{http} password.