mirror of
https://git.zx2c4.com/cgit
synced 2025-07-12 19:24:30 +02:00
about: always ensure page has a trailing slash
Otherwise we can't easily embed links to other /about/ pages. Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
This commit is contained in:
parent
13c2d3df04
commit
d7034806a4
5 changed files with 26 additions and 2 deletions
|
@ -689,6 +689,14 @@ void cgit_print_http_headers(void)
|
|||
exit(0);
|
||||
}
|
||||
|
||||
void cgit_redirect(const char *url, bool permanent)
|
||||
{
|
||||
htmlf("Status: %d %s\n", permanent ? 301 : 302, permanent ? "Moved" : "Found");
|
||||
htmlf("Location: %s\n", url);
|
||||
htmlf("\n");
|
||||
exit(0);
|
||||
}
|
||||
|
||||
static void print_rel_vcs_link(const char *url)
|
||||
{
|
||||
html("<link rel='vcs-git' href='");
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue