-rw-r--r-- | ui-shared.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/ui-shared.c b/ui-shared.c index 137e469..3d5030b 100644 --- a/ui-shared.c +++ b/ui-shared.c | |||
@@ -529,17 +529,17 @@ void cgit_print_docstart(struct cgit_context *ctx) | |||
529 | html("<link rel='shortcut icon' href='"); | 529 | html("<link rel='shortcut icon' href='"); |
530 | html_attr(ctx->cfg.favicon); | 530 | html_attr(ctx->cfg.favicon); |
531 | html("'/>\n"); | 531 | html("'/>\n"); |
532 | } | 532 | } |
533 | if (host && ctx->repo) { | 533 | if (host && ctx->repo) { |
534 | html("<link rel='alternate' title='Atom feed' href='"); | 534 | html("<link rel='alternate' title='Atom feed' href='"); |
535 | html(cgit_httpscheme()); | 535 | html(cgit_httpscheme()); |
536 | html_attr(cgit_hosturl()); | 536 | html_attr(cgit_hosturl()); |
537 | html_attr(cgit_fileurl(ctx->repo->url, "atom", ctx->qry.path, | 537 | html_attr(cgit_fileurl(ctx->repo->url, "atom", ctx->qry.vpath, |
538 | fmt("h=%s", ctx->qry.head))); | 538 | fmt("h=%s", ctx->qry.head))); |
539 | html("' type='application/atom+xml'/>\n"); | 539 | html("' type='application/atom+xml'/>\n"); |
540 | } | 540 | } |
541 | if (ctx->cfg.head_include) | 541 | if (ctx->cfg.head_include) |
542 | html_include(ctx->cfg.head_include); | 542 | html_include(ctx->cfg.head_include); |
543 | html("</head>\n"); | 543 | html("</head>\n"); |
544 | html("<body>\n"); | 544 | html("<body>\n"); |
545 | if (ctx->cfg.header) | 545 | if (ctx->cfg.header) |
@@ -616,18 +616,18 @@ int print_archive_ref(const char *refname, const unsigned char *sha1, | |||
616 | 616 | ||
617 | void cgit_add_hidden_formfields(int incl_head, int incl_search, | 617 | void cgit_add_hidden_formfields(int incl_head, int incl_search, |
618 | const char *page) | 618 | const char *page) |
619 | { | 619 | { |
620 | char *url; | 620 | char *url; |
621 | 621 | ||
622 | if (!ctx.cfg.virtual_root) { | 622 | if (!ctx.cfg.virtual_root) { |
623 | url = fmt("%s/%s", ctx.qry.repo, page); | 623 | url = fmt("%s/%s", ctx.qry.repo, page); |
624 | if (ctx.qry.path) | 624 | if (ctx.qry.vpath) |
625 | url = fmt("%s/%s", url, ctx.qry.path); | 625 | url = fmt("%s/%s", url, ctx.qry.vpath); |
626 | html_hidden("url", url); | 626 | html_hidden("url", url); |
627 | } | 627 | } |
628 | 628 | ||
629 | if (incl_head && ctx.qry.head && ctx.repo->defbranch && | 629 | if (incl_head && ctx.qry.head && ctx.repo->defbranch && |
630 | strcmp(ctx.qry.head, ctx.repo->defbranch)) | 630 | strcmp(ctx.qry.head, ctx.repo->defbranch)) |
631 | html_hidden("h", ctx.qry.head); | 631 | html_hidden("h", ctx.qry.head); |
632 | 632 | ||
633 | if (ctx.qry.sha1) | 633 | if (ctx.qry.sha1) |
@@ -723,17 +723,17 @@ void cgit_print_pageheader(struct cgit_context *ctx) | |||
723 | if (ctx->repo->readme) | 723 | if (ctx->repo->readme) |
724 | reporevlink("about", "about", NULL, | 724 | reporevlink("about", "about", NULL, |
725 | hc(ctx, "about"), ctx->qry.head, NULL, | 725 | hc(ctx, "about"), ctx->qry.head, NULL, |
726 | NULL); | 726 | NULL); |
727 | html("</td><td class='form'>"); | 727 | html("</td><td class='form'>"); |
728 | html("<form class='right' method='get' action='"); | 728 | html("<form class='right' method='get' action='"); |
729 | if (ctx->cfg.virtual_root) | 729 | if (ctx->cfg.virtual_root) |
730 | html_url_path(cgit_fileurl(ctx->qry.repo, "log", | 730 | html_url_path(cgit_fileurl(ctx->qry.repo, "log", |
731 | ctx->qry.path, NULL)); | 731 | ctx->qry.vpath, NULL)); |
732 | html("'>\n"); | 732 | html("'>\n"); |
733 | cgit_add_hidden_formfields(1, 0, "log"); | 733 | cgit_add_hidden_formfields(1, 0, "log"); |
734 | html("<select name='qt'>\n"); | 734 | html("<select name='qt'>\n"); |
735 | html_option("grep", "log msg", ctx->qry.grep); | 735 | html_option("grep", "log msg", ctx->qry.grep); |
736 | html_option("author", "author", ctx->qry.grep); | 736 | html_option("author", "author", ctx->qry.grep); |
737 | html_option("committer", "committer", ctx->qry.grep); | 737 | html_option("committer", "committer", ctx->qry.grep); |
738 | html("</select>\n"); | 738 | html("</select>\n"); |
739 | html("<input class='txt' type='text' size='10' name='q' value='"); | 739 | html("<input class='txt' type='text' size='10' name='q' value='"); |