* lib/webrick/httpservlet/filehandler.rb (set_dir_list): share title and h1.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@40859 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
nobu 2013-05-20 13:41:10 +00:00
Родитель 57d8faeab4
Коммит 83fa035d24
1 изменённых файлов: 5 добавлений и 2 удалений

Просмотреть файл

@ -439,12 +439,15 @@ module WEBrick
res['content-type'] = "text/html" res['content-type'] = "text/html"
title = "Index of #{HTMLUtils::escape(req.path)}"
res.body = <<-_end_of_html_ res.body = <<-_end_of_html_
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN"> <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">
<HTML> <HTML>
<HEAD><TITLE>Index of #{HTMLUtils::escape(req.path)}</TITLE></HEAD> <HEAD>
<TITLE>#{title}</TITLE>
</HEAD>
<BODY> <BODY>
<H1>Index of #{HTMLUtils::escape(req.path)}</H1> <H1>#{title}</H1>
_end_of_html_ _end_of_html_
res.body << "<PRE>\n" res.body << "<PRE>\n"