If edit buttons on the show-url-info CGI page are hidden, explain why.
[privoxy.git] / templates / show-url-info
1 ########################################################################
2 #
3 # File        :  $Source: /cvsroot/ijbswa/current/templates/show-url-info,v $
4 #
5 # Purpose     :  Template for Privoxy's show-url-info CGI page.
6 #
7 # Copyright   :  Written by and Copyright (C) 2001-2007 the SourceForge
8 #                Privoxy team. http://www.privoxy.org/
9 #
10 #                This program is free software; you can redistribute it 
11 #                and/or modify it under the terms of the GNU General
12 #                Public License as published by the Free Software
13 #                Foundation; either version 2 of the License, or (at
14 #                your option) any later version.
15 #
16 #                This program is distributed in the hope that it will
17 #                be useful, but WITHOUT ANY WARRANTY; without even the
18 #                implied warranty of MERCHANTABILITY or FITNESS FOR A
19 #                PARTICULAR PURPOSE.  See the GNU General Public
20 #                License for more details.
21 #
22 #                The GNU General Public License should be included with
23 #                this file.  If not, you can view it at
24 #                http://www.gnu.org/copyleft/gpl.html
25 #                or write to the Free Software Foundation, Inc., 59
26 #                Temple Place - Suite 330, Boston, MA  02111-1307, USA.
27 #
28 # Revisions   :
29 #    $Log: show-url-info,v $
30 #    Revision 1.22  2007/12/08 14:29:06  fabiankeil
31 #    Use CSS to let the URL and pattern input fields scale with
32 #    the browser width and try to prevent vertical scroll bars
33 #    if the width is less than 80 characters. Closes #1843596,
34 #    thanks to Gerry Murphy and Lee.
35 #
36 #    Revision 1.21  2007/11/15 19:11:11  fabiankeil
37 #    Reword HTTPS URL information.
38 #
39 #    Revision 1.20  2007/07/21 12:19:50  fabiankeil
40 #    If show-url-info is called with an URL that Privoxy
41 #    would reject as invalid, don't show unresolved forwarding
42 #    variables, "final matches" or claim the site's secure.
43 #
44 #    Revision 1.19  2007/02/10 16:55:22  fabiankeil
45 #    - Show forwarding settings on the show-url-info page
46 #    - Fix some HTML syntax errors.
47 #
48 #
49 #########################################################################
50 # USING HTML TEMPLATES:
51 # ---------------------
52 #
53 # Template files are written win plain HTML, with a few
54 # additions:
55
56 # - Lines that start with a '#' character like this one
57 #   are ignored
58 #
59 # - Each item in the below list of exported symbols will
60 #   be replaced by dynamically generated text, if they
61 #   are enclosed in '@'-characters. E.g. The string @version@
62 #   will be replaced by the version number of Privoxy.
63 #
64 # - One special application of this is to make whole blocks
65 #   of the HTML template disappear if the condition <name>
66 #   is not given. Simply enclose the block between the two
67 #   strings @if-<name>start and if-<name>-end@. The strings
68 #   should be placed in HTML comments (<!-- -->), so the
69 #   html structure won't be messed when the magic happens.
70 #   
71 # USABLE SYMBOLS IN THIS TEMPLATE:
72 # --------------------------------
73 #
74 #  my-ip-addr:
75 #    The IP-address that the client used to reach Privoxy
76 #  my-hostname:
77 #    The hostname associated with my-ip-addr
78 #  admin-address:
79 #    The email address of the Privoxy administrator, as configured
80 #    in the config file
81 #  default-cgi:
82 #    The URL for Privoxy's "main menu" builtin CGI page
83 #  menu:
84 #    List of <li> elements linking to the other available CGIs
85 #  version:
86 #    Privoxy's version number
87 #  code-status:
88 #    Privoxy's development status: "alpha", "beta", or "stable".
89 #  homepage:
90 #    The Privoxy web site.
91 #
92 # CONDITIONAL SYMBOLS FOR THIS TEMPLATE AND THEIR DEPANDANT SYMBOLS:
93 # ------------------------------------------------------------------
94 #
95 #  unstable:
96 #    this is an alpha or beta release of the proxy software
97 #  have-adminaddr-info:
98 #    An e-mail address for the local Privoxy adminstrator has
99 #    been specified and is available through the "admin-address"
100 #    symbol
101 #  have-proxy-info:
102 #    A URL for online documentation about this proxy has been
103 #    specified and is available through the "proxy-info-url"
104 #    symbol
105 #  have-help-info:
106 #    If either have-proxy-info is true or have-adminaddr-info is
107 #    true, have-help-info is true.  Used to conditionally include
108 #    a grey box for any and all help info.
109 #  url-given:
110 #    The CGI was called with a url parameter. In that case, the
111 #    following symbols are available:
112 #    url:
113 #      The given URL
114 #    default:
115 #      The system default for actions
116 #    matches:
117 #      The list of all matches in the actions file that this URL
118 #      produced, along with the actions that were triggered by
119 #      these matches
120 #    final:
121 #      The actions that are associated with the URL at the end of
122 #      the matching process
123 #  no-forwarder: Requests to url will be made directly.
124 #  http-forwarder:
125 #      Requests to url will be made through a HTTP proxy
126 #      forward-host:
127 #         The IP address or its hostname
128 #      forward-port.
129 #         The proxy port
130 #  socks-forwarder:
131 #      Requests to url will be made through a socks proxy
132 #      socks-type:
133 #         The socks type: socks4 or socks4a
134 #      gateway-host:
135 #         The IP address or its hostname
136 #      gateway-port:
137 #         The proxy port.
138 #
139 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
140 <html>
141
142 <head>
143   <title>Privoxy@@my-hostname@ URL Info</title>
144   <meta http-equiv="Content-Style-Type" content="text/css">
145   <meta http-equiv="Content-Script-Type" content="text/javascript">
146   <meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
147   <meta name="robots" content="noindex,nofollow">
148   <link rel="stylesheet" type="text/css" href="@default-cgi@send-stylesheet">
149   <link rel="shortcut icon" href="@default-cgi@favicon.ico" type="image/x-icon">
150 </head>
151
152 <body>
153
154   <table summary="" cellpadding="20" cellspacing="10" border="0" width="100%">
155     <tr>
156       <td class="title">
157
158 #include mod-title
159
160       </td>
161     </tr>
162
163 <!-- @if-unstable-start -->
164 # This will only appear if CODE_STATUS is "alpha" or "beta". See configure.in
165     <tr>
166       <td class="warning">
167
168 #include mod-unstable-warning
169
170       </td>
171     </tr>
172 <!-- if-unstable-end@ -->
173
174 <!-- @if-url-given-start -->
175     <tr>
176       <td class="box">
177 <!-- @if-valid-url-start -->
178         <h2>Forwarding settings:</h2>
179         <p>
180           Requests for <a href="@url@">@url@</a> will be <!--
181
182 # "Interesting" formatting to prevent white space at the end of the sentence.
183
184           @if-no-forwarder-start -->
185
186              made <b>directly</b>, no forwarding settings apply<!--
187
188           if-no-forwarder-end@--><!--
189           @if-http-forwarder-start --><!-- @if-socks-forwarder-start -->
190
191              first <!--
192
193           if-socks-forwarder-end@ --><!-- if-http-forwarder-end@ --><!--
194           @if-socks-forwarder-start -->
195
196              forwarded through <b>@socks-type@-proxy @gateway-host@:@gateway-port@</b><!--
197
198           if-socks-forwarder-end@ --><!--
199           @if-http-forwarder-start --><!-- @if-socks-forwarder-start -->
200
201              and then <!--
202
203           if-socks-forwarder-end@ --><!-- if-http-forwarder-end@ --><!--
204           @if-http-forwarder-start -->
205
206              forwarded through <b>HTTP-proxy @forward-host@:@forward-port@</b><!--
207
208           if-http-forwarder-end@ -->.
209       </td>
210     </tr>
211     <tr>
212       <td class="box">
213 <!-- @if-https-start -->
214         <h2>NOTE:</h2>
215         <p>This is a HTTPS URL, so the part after the "/" is ignored
216           as Privoxy doesn't see the path for real HTTPS requests either.</p>
217 <!-- if-https-end@ -->
218 <!-- if-valid-url-end@ -->
219         <h2>Matches for <a href="@url@">@url@</a>:</h2>
220         @matches@
221 <!-- @if-cgi-editor-is-disabled-start -->
222         <p>
223           The CGI editor is currently disabled, thus no edit buttons are shown.<br>
224           Please have a look at the
225            <a href="@user-manual@config.html#ENABLE-EDIT-ACTIONS">enable-edit-actions documentation</a>
226           to learn how to enable it and what the risks are.
227         </p>
228 <!--  if-cgi-editor-is-disabled-end@ -->
229       </td>
230     </tr>
231 <!-- @if-valid-url-start -->
232     <tr>
233       <td class="box">
234         <h2>Final results:</h2>
235         <p><b>@final@</b></p>
236       </td>
237     </tr>
238 <!-- if-valid-url-end@ -->
239 <!-- if-url-given-end@ -->
240
241 <!-- @if-privoxy-is-toggled-off-start -->
242
243     <tr>
244       <td class="warning">
245         <h2>Warning:</h2>
246         <p>
247           <strong>Privoxy is currently toggled off. Matching actions will not apply
248           unless you <a href="@default-cgi@toggle?set=enable">toggle Privoxy on</a> first.</strong>
249         </p>
250       </td>
251     </tr>
252 <!-- if-privoxy-is-toggled-off-end@ -->
253
254     <tr>
255       <td class="box">
256         <h2>Look up the actions for a 
257 <!-- @if-url-given-start -->new<!-- if-url-given-end@ -->
258           URL:</h2>
259         <form method="GET" action="@default-cgi@show-url-info">
260           <p>
261             <input type="text" name="url" size="80" value="@url@" class="url"> 
262             <input type="submit" value="Go">
263           </p>
264         </form>
265       </td>
266     </tr>
267
268     <tr>
269       <td class="box">
270         <h2>More Privoxy:</h2>
271         <ul>@menu@<li><a href="@user-manual@">Documentation</a></li></ul>
272       </td>
273     </tr>
274
275     <tr>
276       <td class="info">
277
278 #include mod-support-and-service
279
280       </td>
281     </tr>
282
283 <!-- @if-have-help-info-start -->
284     <tr>
285       <td class="info">
286
287 #include mod-local-help
288
289       </td>
290     </tr>
291 <!-- if-have-help-info-end@ -->
292
293   </table>
294
295 </body>
296 </html>