mirror of https://github.com/kiwix/libkiwix.git
This change fixes two issues: 1. Presence of URL-specific special symbols (such as ? or #) in the book and/or article name resulted in a wrong suggestion link. This is fixed by URI-encoding the book name and the path, too. 2. Presence of a single quote symbol in the book and/or article name resulted in invalid javascript code in the href attribute of the suggestion link. The single quote (') symbol is not URL-encoded (unlike its double quote counterpart). As a result, enclosing a URL-encoded string in single quotes may result in invalid javascript. Using double quotes instead is safe, since both double quote (") and backslash (\) symbols (which are the only special symbols for such quoting) undergo URL-encoding. |
||
---|---|---|
.. | ||
data | ||
book.cpp | ||
httplib.h | ||
kiwixserve.cpp | ||
library.cpp | ||
library_server.cpp | ||
lrucache.cpp | ||
manager.cpp | ||
meson.build | ||
name_mapper.cpp | ||
opds_catalog.cpp | ||
otherTools.cpp | ||
pathTools.cpp | ||
regex.cpp | ||
server.cpp | ||
server_helper.cpp | ||
server_search.cpp | ||
server_testing_tools.h | ||
stringTools.cpp | ||
tagParsing.cpp |