This also fixes a bug in the tokenizing FSM in etc.c that prevented the !doctype element from being recognized; the fix is necessary because HTML5 detection depends on checking the !doctype element.
Perl's hash variables are not ordered so each
time we run the CGI script for the help page
we may get a different order.
This caused bindings and names to appear
differently on each reload.
To fix this sort by keys when generating the
shortcut tables.
Fixes#133
- Begin a sentence on a new line.
- Split long lines (> 80).
- Fix warnings from "mandoc -Tlint"
- Remove space at end of lines.
- Change a HYPHEN-MINUS (code 0x55, 2D) to a dash (minus) if it matches
" -[:alpha:]" or \[aq]-[:alpha:] (for options).
- Use the macros .MT/.ME for e-mail addresses
Origin: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=963801#5
When w3m is launched, if no other options are specified, it attempts to
read HTTP_HOME and WWW_HOME from the environment and upon finding a
value for one of these load the url specified. Once launched, though,
w3m provides no convenience for navigating to the home page.
Here, that ability is added. A new command GOTO_HOME is defined with a
default key binding of C-_.
The XHTML standard encompasses the XML standard.
From the beginning, the XML standard [1] has always included required
support for five character entities:
1. the ampersand (&) as &
2. the left angle bracket (<) as <
3. the right angle bracket (>) as >
4. the double-quote character (") as "
5. the apostrophe or single-quote character (') as '
See section "2.4 Character Data and Markup" of the XML standard [1]
for further details.
Add support for the character single-quote character entity (')
in order to fully support XHTML pages.
[1]: https://www.w3.org/TR/REC-xml/
Signed-off-by: Kyle J. McKay <mackyle@gmail.com>
Since Google gives usable search results to Lynx but not to w3m, and
many other sites block Lynx but /not/ w3m, we want to be able to set
the User Agent string on a per-site basis.
Adding on command line the user agent add a duplicate header:
```
./w3m -header "User-Agent: Mozilla" http://localhost:9999
GET / HTTP/1.0
User-Agent: w3m/0.5.3+git20190105
Accept: text/html, text/*;q=0.5, image/*, application/*, message/*, x-scheme-handler/*, audio/*, video/*, inode/*
Accept-Encoding: gzip, compress, bzip, bzip2, deflate
Accept-Language: en;q=1.0
Host: localhost:9999
Pragma: no-cache
Cache-control: no-cache
User-Agent: Mozilla
```
As a result most server will take the first given; the default
w3m_version or the one defined on config `user_agent`
With this patch we can now override `User-Agent` from command line