Skip to content

Commit 6ab1946

Browse files
committed
add charset in the document if specified in IndexOptions
bz #69930 git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1931451 13f79535-47bb-0310-9956-ffa450edef68
1 parent 07f8d6c commit 6ab1946

1 file changed

Lines changed: 5 additions & 1 deletion

File tree

modules/generators/mod_autoindex.c

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -177,7 +177,11 @@ static void emit_preamble(request_rec *r, int xhtml, const char *title)
177177
if (xhtml) {
178178
ap_rvputs(r, DOCTYPE_XHTML_1_0T,
179179
"<html xmlns=\"http://www.w3.org/1999/xhtml\">\n"
180-
" <head>\n <title>Index of ", title,
180+
" <head>\n", NULL);
181+
if(d->charset != NULL) {
182+
ap_rvputs(r, " <meta http-equiv=\"Content-Type\" content=\"text/html; charset=", d->charset, "\" />\n", NULL);
183+
}
184+
ap_rvputs(r, " <title>Index of ", title,
181185
"</title>\n", NULL);
182186
} else {
183187
ap_rvputs(r, DOCTYPE_HTML_4_01,

0 commit comments

Comments
 (0)