Fix repolist search links with virtual root
Signed-off-by: Geoff Johnstone <geoff.johnstone@googlemail.com> Signed-off-by: Lars Hjemli <hjemli@gmail.com>
This commit is contained in:
parent
8071e18dcb
commit
9735835c0e
@ -94,7 +94,7 @@ int is_in_url(struct cgit_repo *repo)
|
|||||||
|
|
||||||
void print_sort_header(const char *title, const char *sort)
|
void print_sort_header(const char *title, const char *sort)
|
||||||
{
|
{
|
||||||
htmlf("<th class='left'><a href='./?s=%s", sort);
|
htmlf("<th class='left'><a href='%s?s=%s", cgit_rooturl(), sort);
|
||||||
if (ctx.qry.search) {
|
if (ctx.qry.search) {
|
||||||
html("&q=");
|
html("&q=");
|
||||||
html_url_arg(ctx.qry.search);
|
html_url_arg(ctx.qry.search);
|
||||||
|
@ -3,6 +3,7 @@
|
|||||||
|
|
||||||
extern char *cgit_httpscheme();
|
extern char *cgit_httpscheme();
|
||||||
extern char *cgit_hosturl();
|
extern char *cgit_hosturl();
|
||||||
|
extern char *cgit_rooturl();
|
||||||
extern char *cgit_repourl(const char *reponame);
|
extern char *cgit_repourl(const char *reponame);
|
||||||
extern char *cgit_fileurl(const char *reponame, const char *pagename,
|
extern char *cgit_fileurl(const char *reponame, const char *pagename,
|
||||||
const char *filename, const char *query);
|
const char *filename, const char *query);
|
||||||
|
Loading…
Reference in New Issue
Block a user