Skip to content

Commit dd446aa

Browse files
likelionJanWielemaker
authored andcommittedJan 3, 2025
DOC: spellchecked documentation
1 parent 1d11086 commit dd446aa

34 files changed

+89
-89
lines changed
 

‎README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ both HTTP and HTTPS connections and handle all request methods.
1010

1111
## Server library
1212

13-
The main server libraris are
13+
The main server libraries are
1414

1515
- `library(http/thread_httpd)` implements the server
1616
- `library(http/http_dispatch)` implements binding locations

‎ax.pl

+1-1
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@
6161
% Only provide the attribute if it is available. This is
6262
% mutually exclusive with =required=. This is the default.
6363
% - url(+URL)
64-
% Can be used to ovcerrule or extend the ax_alias/2.
64+
% Can be used to overrule or extend the ax_alias/2.
6565
% - count(+Count)
6666
% Maximum number of values to provide
6767
%

‎cgi_stream.c

+2-2
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ with the request, deciding on:
7373
Now, the stream is placed in full buffering mode (SIO_FBUF). If the
7474
transfer encoding is 'chunked' it immediately calls the hook using
7575
'send_header' to emit the current header. Output continues. In chunked
76-
mode sending the chunks, otherwisse collecting the data. On close, it
76+
mode sending the chunks, otherwise collecting the data. On close, it
7777
writes an empty block (chunked mode) or (normal mode) calls the hook
7878
'send_header' which now has access to the content-length, followed by
7979
the data.
@@ -434,7 +434,7 @@ cgi_discard(term_t cgi)
434434
*******************************/
435435

436436
/* - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
437-
Call hook on the data we collected sofar. The hook is called with the
437+
Call hook on the data we collected so far. The hook is called with the
438438
following additional arguments:
439439
440440
* Event-type (header, data)

‎graphql.pl

+3-3
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,7 @@
9494
% Desc = "SWI-Prolog package implementing a SourceHut GraphQL API client.".
9595
% ```
9696
%
97-
% Options is a list whose elemenets are one of the following:
97+
% Options is a list whose elements are one of the following:
9898
% - token(+Token)
9999
% Token is string that will be used as an OAuth2.0 token. See also
100100
% graphql_auth_token_hook/2.
@@ -284,7 +284,7 @@
284284
% A list of associations of Prolog variable names, given as atoms,
285285
% to _GraphQL values_.
286286
%
287-
% Occurences of the special lexical construct "<Name>" (that is,
287+
% Occurrences of the special lexical construct "<Name>" (that is,
288288
% ASCII 60, then the codes of the atom Name, then ASCII 62) in
289289
% Source are expanded in Document to the _GraphQL value_ Value.
290290
% This option can be used to interpolate GraphQL documents with
@@ -1040,7 +1040,7 @@
10401040
%
10411041
% Options are a list whose elements are one of:
10421042
% - separator(+Sep)
1043-
% Sep is a list of codes to be used for separating adjancent
1043+
% Sep is a list of codes to be used for separating adjacent
10441044
% GraphQL values in Codes. Defaults to a single space.
10451045
% This option can be used to separate values with commas
10461046
% (which are optional throughout GraphQL) by passing

‎html_head.pl

+2-2
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@
8282
2. Replace multiple members by `aggregate' scripts or css files.
8383
see use_agregates/4.
8484
3. Order all resources by demanding that their dependencies
85-
preceede the resource itself. Note that the ordering of
85+
precede the resource itself. Note that the ordering of
8686
resources in the dependency list is *ignored*. This implies
8787
that if the order matters the dependency list must be split
8888
and only the primary dependency must be added.
@@ -555,7 +555,7 @@
555555
%! html_include(+PathOrList)// is det.
556556
%
557557
% Include to HTML resources that must be in the HTML <head>
558-
% element. Currently onlu supports =|.js|= and =|.css|= files.
558+
% element. Currently only supports =|.js|= and =|.css|= files.
559559
% Extend this to support more header material. Do not use this
560560
% predicate directly. html_requires//1 is the public interface to
561561
% include HTML resources.

‎html_write.pl

+3-3
Original file line numberDiff line numberDiff line change
@@ -836,7 +836,7 @@
836836
% Quote the value according to the rules for tag-attributes
837837
% included in double-quotes. Note that -like html_quoted//1-,
838838
% attributed values printed through html//1 are quoted
839-
% atomatically.
839+
% automatically.
840840
%
841841
% @tbd Assumes UTF-8 encoding of the output.
842842

@@ -908,7 +908,7 @@
908908
%! html_receive(+Id, :Handler)// is det.
909909
%
910910
% This extended version of html_receive//1 causes Handler to be
911-
% called to process all messages posted to the channal at the time
911+
% called to process all messages posted to the channel at the time
912912
% output is generated. Handler is called as below, where
913913
% `PostedTerms` is a list of Module:Term created from calls to
914914
% html_post//2. Module is the context module of html_post and Term
@@ -938,7 +938,7 @@
938938
% Collect posted tokens and copy them into the receiving
939939
% mailboxes. Mailboxes may produce output for each other, but not
940940
% cyclic. The current scheme to resolve this is rather naive: It
941-
% simply permutates the mailbox resolution order until it found a
941+
% simply permutes the mailbox resolution order until it found a
942942
% working one. Before that, it puts =head= and =script= boxes at
943943
% the end.
944944

‎htmx.pl

+1-1
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@
5353
HTML fragment that extends or replaces an element on the page. This
5454
allows us to program a most functionality interactive seen in modern web
5555
applications using the powerful SWI-Prolog HTML generation framework
56-
rather than having to write a JSON backend and accompagnying JavaScript
56+
rather than having to write a JSON backend and accompanying JavaScript
5757
frontend that runs in the browser.
5858
5959
Below is a minimal, yet fully functional application

‎http.doc

+5-5
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,7 @@ This library provides http_open/3 and friends. It
9999
is a library for opening an endpoint identified by an HTTP URL as a
100100
Prolog stream. The general skeleton for using this library
101101
is given below, where \nopredref{process}{1} processes the data from the
102-
HTTP server.\footnote{One may opt to use cleanup/2 intead of
102+
HTTP server.\footnote{One may opt to use cleanup/2 instead of
103103
setup_call_cleanup/3 to allow for aborting while http_open/3 is waiting
104104
for the connection.}
105105

@@ -458,7 +458,7 @@ message.
458458

459459
Options fall into three categories: those that handle presence of
460460
the parameter, those that guide conversion and restrict types and
461-
those that support automatic generation of documention. First,
461+
those that support automatic generation of documentation. First,
462462
the presence-options:
463463

464464
\begin{description}
@@ -933,7 +933,7 @@ present. If the dispatch module is used (see \secref{httpdispatch}),
933933
spawning is normally specified as an option to the http_handler/3
934934
registration.
935935

936-
We recomment the use of thread pools. They allow registration of a set
936+
We recommend the use of thread pools. They allow registration of a set
937937
of threads using common characteristics, specify how many can be active
938938
and what to do if all threads are active. A typical application may
939939
define a small pool of threads with large stacks for computation
@@ -1098,7 +1098,7 @@ not start with \chr{/}.
10981098

10991099
This problem can also be solved using the contributed Apache module
11001100
\const{proxy_html} that can be instructed to rewrite URLs embedded in
1101-
HTML documents. In our experience, this is not troublefree as URLs can
1101+
HTML documents. In our experience, this is not trouble-free as URLs can
11021102
appear in many places in generated documents. JavaScript can create
11031103
URLs on the fly, which makes rewriting virtually impossible.
11041104

@@ -1301,7 +1301,7 @@ The example below generates a URL that references the predicate
13011301
set_lang/1 in the application with given parameters. The http_handler/3
13021302
declaration binds \const{/setlang} to the predicate set_lang/1 for which
13031303
we provide a very simple implementation. The code between \const{...}
1304-
is part of an HTML page showing the english flag which, when pressed,
1304+
is part of an HTML page showing the English flag which, when pressed,
13051305
calls \term{set_lang}{Request} where \arg{Request} contains the search
13061306
parameter \mbox{\const{lang} = \const{en}}. Note that the HTTP location
13071307
(path) \const{/setlang} can be moved without affecting this code.

‎http_authenticate.pl

+2-2
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@
6666
% to Type. Type identifies the required authentication technique:
6767
%
6868
% * basic(+PasswordFile)
69-
% Use HTTP =Basic= authetication and verify the password
69+
% Use HTTP =Basic= authentication and verify the password
7070
% from PasswordFile. PasswordFile is a file holding
7171
% usernames and passwords in a format compatible to
7272
% Unix and Apache. Each line is record with =|:|=
@@ -92,7 +92,7 @@
9292
%
9393
% @param Fields is a list of fields from the password-file entry.
9494
% The first element is the user. The hash is skipped.
95-
% @tbd Should we also cache failures to reduce the risc of
95+
% @tbd Should we also cache failures to reduce the risk of
9696
% DoS attacks?
9797

9898
http_authenticate(basic(File), Request, [User|Fields]) :-

‎http_cookie.pl

+1-1
Original file line numberDiff line numberDiff line change
@@ -233,7 +233,7 @@
233233
%
234234
% Query current cookie database. If Name is given, it is matched
235235
% case insensitive against the known cookies. If it is unbound,
236-
% the cookie name is returned in its oiginal case (case
236+
% the cookie name is returned in its original case (case
237237
% preserving).
238238

239239
cookie_current_cookie(ClientId, Name, Value, Options) :-

‎http_cors.pl

+2-2
Original file line numberDiff line numberDiff line change
@@ -46,11 +46,11 @@
4646
4747
This small module allows for enabling Cross-Origin Resource Sharing
4848
(CORS) for a specific request. Typically, CORS is enabled for API
49-
services that you want to have useable from browser client code that is
49+
services that you want to have usable from browser client code that is
5050
loaded from another domain. An example are the LOD and SPARQL services
5151
in ClioPatria.
5252
53-
Because CORS is a security risc (see references), it is disabled by
53+
Because CORS is a security risk (see references), it is disabled by
5454
default. It is enabled through the setting http:cors. The value of this
5555
setting is a list of domains that are allowed to access the service.
5656
Because * is used as a wildcard match, the value [*] allows access from

‎http_digest.pl

+3-3
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@
5858
5959
This library implements HTTP _Digest Authentication_ as per RFC2617.
6060
Unlike _Basic Authentication_, digest authentication is based on
61-
challenge-reponse and therefore does not need to send the password over
61+
challenge-response and therefore does not need to send the password over
6262
the (insecure) connection. In addition, it provides a count mechanism
6363
that ensure that old credentials cannot be reused, which prevents
6464
attackers from using old credentials with a new request. Digest
@@ -369,12 +369,12 @@
369369

370370
%! http_digest_authenticate(+Request, -User, -UserFields, +Options)
371371
%
372-
% Validate the client reponse from the Request header. On success,
372+
% Validate the client response from the Request header. On success,
373373
% User is the validated user and UserFields are additional fields
374374
% from the password file. Options include:
375375
%
376376
% - passwd_file(+File)
377-
% Validate passwords agains the given password file. The
377+
% Validate passwords against the given password file. The
378378
% file is read using http_current_user/3 from
379379
% library(http/http_authenticate).
380380
% - stale(-Stale)

‎http_dirindex.pl

+1-1
Original file line numberDiff line numberDiff line change
@@ -121,7 +121,7 @@
121121
% Sort the files in the directory listing by Field. Field
122122
% is one of =name= (default), =size= or =time=.
123123
% * order(+AscentDescent)
124-
% Sorting order. Default is =ascending=. The altenative is
124+
% Sorting order. Default is =ascending=. The alternative is
125125
% =descending=
126126
% * name(:RenderName)
127127
% DCG used to render a name in the table. The File is passed.

‎http_dispatch.pl

+6-6
Original file line numberDiff line numberDiff line change
@@ -160,7 +160,7 @@
160160
% Options is a list containing the following options:
161161
%
162162
% - authentication(+Type)
163-
% Demand authentication. Authentication methods are pluggable. The
163+
% Demand authentication. Authentication methods are plugable. The
164164
% library http_authenticate.pl provides a plugin for user/password
165165
% based =Basic= HTTP authentication.
166166
%
@@ -624,7 +624,7 @@
624624
% returned location is the path up to the first variable, e.g.,
625625
% =|/user/|= in the example above.
626626
%
627-
% User code is adviced to use http_link_to_id/3 which can also add
627+
% User code is advised to use http_link_to_id/3 which can also add
628628
% query parameters to the URL. This predicate is a helper for
629629
% http_link_to_id/3.
630630
%
@@ -768,7 +768,7 @@
768768
% ```
769769
%
770770
% @arg HandleID is either an atom, possibly module qualified
771-
% predicate or a compound term if the hander is defined using
771+
% predicate or a compound term if the handler is defined using
772772
% a pattern. See http_handler/3 and http_location_by_id/2.
773773
%
774774
% @arg Parameters is one of
@@ -1071,7 +1071,7 @@
10711071
% * static_gzip(+Boolean)
10721072
% If `true` (default `false`) and, in addition to the plain
10731073
% file, there is a ``.gz`` file that is not older than the
1074-
% plain file and the client acceps =gzip= encoding, send
1074+
% plain file and the client accepts =gzip= encoding, send
10751075
% the compressed file with ``Transfer-encoding: gzip``.
10761076
%
10771077
% * cached_gzip(+Boolean)
@@ -1327,7 +1327,7 @@
13271327

13281328
%! path_tree(-Tree) is det.
13291329
%
1330-
% Compile paths into a tree. The treee is multi-rooted and
1330+
% Compile paths into a tree. The tree is multi-rooted and
13311331
% represented as a list of nodes, where each node has the form:
13321332
%
13331333
% node(PathOrPrefix, Action, Options, Children)
@@ -1337,7 +1337,7 @@
13371337
% worker thread holds a copy of the tree. If handler facts are
13381338
% changed the _generation_ is incremented using next_generation/0
13391339
% and each worker thread will re-compute the tree on the next
1340-
% ocasion.
1340+
% occasion.
13411341

13421342
path_tree(Tree) :-
13431343
current_generation(G),

‎http_dyn_workers.pl

+1-1
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@
8282
%! http:schedule_workers(+Dict)
8383
%
8484
% Called if there is no immediately free worker to handle the
85-
% incomming request. The request is forwarded to the thread
85+
% incoming request. The request is forwarded to the thread
8686
% =|__http_scheduler|= as the hook is called in time critical code.
8787

8888
:- multifile

‎http_error.pl

+1-1
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@
4949
can be controlled by
5050
5151
- nodebug(http(error))
52-
After disabling the http(error) debug channal, errors are only sent
52+
After disabling the http(error) debug channel, errors are only sent
5353
to the client. See nodebug/1 and debug/1.
5454
- set_setting(http:client_backtrace, false)
5555
Stop sending stack traces to the client. Note that sending the stack

‎http_files.pl

+1-1
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@
5757
be created using the following code sample, which starts a server at
5858
port 8080 that serves files from the current directory ('.'). Note that
5959
the handler needs a `prefix` option to specify that it must handle all
60-
paths that begin with the registed location of the handler.
60+
paths that begin with the registered location of the handler.
6161
6262
```
6363
:- use_module(library(http/http_server)).

‎http_header.pl

+5-5
Original file line numberDiff line numberDiff line change
@@ -484,7 +484,7 @@
484484
%! status_has_content(+StatusTerm, -HTTPCode)
485485
%
486486
% True when StatusTerm is a status that usually comes with an
487-
% expanatory content message.
487+
% explanatory content message.
488488

489489
status_has_content(created(_Location)).
490490
status_has_content(moved(_To)).
@@ -871,7 +871,7 @@
871871
%
872872
% Decide on the transfer encoding from the Request and the CGI
873873
% header. The behaviour depends on the setting
874-
% http:chunked_transfer. If =never=, even explitic requests are
874+
% http:chunked_transfer. If =never=, even explicit requests are
875875
% ignored. If =on_request=, chunked encoding is used if requested
876876
% through the CGI header and allowed by the client. If
877877
% =if_possible=, chunked encoding is used whenever the client
@@ -933,7 +933,7 @@
933933

934934
%! content_length_in_encoding(+Encoding, +In, -Bytes)
935935
%
936-
% Determine hom many bytes are required to represent the data from
936+
% Determine how many bytes are required to represent the data from
937937
% stream In using the given encoding. Fails if the data cannot be
938938
% represented with the given encoding.
939939

@@ -1786,7 +1786,7 @@
17861786

17871787
%! read_field_value(-Codes)//
17881788
%
1789-
% Read a field eagerly upto the next whitespace
1789+
% Read a field eagerly up to the next whitespace
17901790

17911791
read_field_value([H|T]) -->
17921792
[H],
@@ -2749,7 +2749,7 @@
27492749

27502750
%! address//
27512751
%
2752-
% Emit the HTML for the server address on behalve of error and
2752+
% Emit the HTML for the server address on behalf of error and
27532753
% status messages (non-200 replies). Default is
27542754
%
27552755
% ==

‎http_multipart_plugin.pl

+1-1
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@
6060
%! http_client:http_convert_data(+In, +Fields, -Data, +Options) is semidet.
6161
%
6262
% Convert =|multipart/form-data|= messages for http_read_data/3.
63-
% This plugin adds the folling options to http_read_data/3:
63+
% This plugin adds the following options to http_read_data/3:
6464
%
6565
% * form_data(+AsForm)
6666
% If the content-type is =|multipart/form-data|=, return the

‎http_open.pl

+2-2
Original file line numberDiff line numberDiff line change
@@ -993,7 +993,7 @@
993993
%
994994
% Parse the header lines for the headers(-List) option. Invalid
995995
% header lines are skipped, printing a warning using
996-
% pring_message/2.
996+
% print_message/2.
997997

998998
parse_headers([], []) :- !.
999999
parse_headers([Line|Lines], Headers) :-
@@ -1782,7 +1782,7 @@
17821782
%
17831783
% This hook is used by the HTTP client library to define default
17841784
% options based on the the broken-down request-URL. The following
1785-
% example redirects all trafic, except for localhost over a proxy:
1785+
% example redirects all traffic, except for localhost over a proxy:
17861786
%
17871787
% ```
17881788
% :- multifile

0 commit comments

Comments
 (0)