Service links, per draft-wilde-service-link-rel

master
Stephane Bortzmeyer 3 years ago
parent 8dd39e5270
commit 5761bf723e
  1. 1
      DNSLG/Formatter.py
  2. 3
      DNSLG/__init__.py

@ -719,6 +719,7 @@ html_template = """<?xml version="1.0" encoding="utf-8"?>
<title tal:content="title"/>
<link tal:condition="css" rel="stylesheet" type="text/css" tal:attributes="href css"/>
<link rel="author" href="http://www.bortzmeyer.org/static/moi.html"/>
<link rel="service-doc" href="https://www.bortzmeyer.org/dns-lg-usage.html"/>
<link tal:condition="opensearch" rel="search"
type="application/opensearchdescription+xml"
tal:attributes="href opensearch"

@ -40,7 +40,8 @@ def send_response(start_response, status, output, type):
# produces an Expires: HTTP header. See issue #13
response_headers = [('Content-type', type),
('Content-Length', str(len(output))),
('Allow', 'GET')]
('Allow', 'GET'),
('Link', '<https://www.bortzmeyer.org/dns-lg-usage.html>; rel="service-doc"; type="text/html"']
start_response(status, response_headers)
def punycode_of(domain):

Loading…
Cancel
Save