remove all of the CVS "$Id: xxx" lines that GIT doesn't do anything with
[privoxy.git] / doc / webserver / submit / index.php
1 <?php
2 //  File :   doc/webserver/submit/index.php
3 //
4 //  Purpose  :  Submit form for ads and such
5 //
6 //  Written by and Copyright (C) 2001 the SourceForge
7 //  Privoxy team. http://www.privoxy.org/
8 //
9 //  Based on the Internet Junkbuster originally written
10 //  by and Copyright (C) 1997 Anonymous Coders and
11 //  Junkbusters Corporation.  http://www.junkbusters.com
12 //
13 //  This program is free software; you can redistribute it
14 //  and/or modify it under the terms of the GNU General
15 //  Public License as published by the Free Software
16 //  Foundation; either version 2 of the License, or (at
17 //  your option) any later version.
18 //
19 //  This program is distributed in the hope that it will
20 //  be useful, but WITHOUT ANY WARRANTY; without even the
21 //  implied warranty of MERCHANTABILITY or FITNESS FOR A
22 //  PARTICULAR PURPOSE.  See the GNU General Public
23 //  License for more details.
24 //
25 //  The GNU General Public License should be included with
26 //  this file.  If not, you can view it at
27 //  http://www.gnu.org/copyleft/gpl.html
28 //  or write to the Free Software Foundation, Inc., 59
29 //  Temple Place - Suite 330, Boston, MA  02111-1307, USA.
30 //
31 //
32 $headers = getallheaders();
33 ?>
34 <html>
35   <head>
36     <title>Privoxy|Submit</title>
37     <link rel="stylesheet" type="text/css" href="../p_web.css">
38 </head>
39
40 <h1>Privoxy Feedback</h1>
41
42 <p>Compared to <a
43 href="http://sourceforge.net/tracker/?group_id=11118&atid=111118">bug
44 reports</a> or <a
45 href="http://sourceforge.net/tracker/?atid=361118&group_id=11118&func=browse">feature
46 requests</a>, this page is intended to optimize the blocking behavior
47 of Privoxy. Therefor we need your feedback.</p><p> If you have
48 observed and advertisement, that was not blocked or an image that was
49 incorrectly blocked, please use the forms below to report this.</p>
50
51 <h2>New Advertisement</h2>
52
53 <!-- testing mail sending
54 // <?
55 //$ret_val=mail("stefan@waldherr.org", "Subject", "Message"); echo $ret_val;
56 ?>
57 -->
58
59
60 <?
61 $cfile  = "counter-data.inc";
62 $localip = "127.0.0.1";
63 $serverip = "127.0.0.1";
64 # Enter information on the next line, but only after you read
65 # the "c-readme.txt" file.
66 $browser_id = "";
67 if (file_exists ($cfile)) {
68         $fp = fopen ($cfile,"r+");
69         $data = fgets ($fp,25);
70         $ip = chop (substr($data,0,15));
71         $count = substr($data,15);
72 # Unremark the second "if" statement and remark the first one if
73 # your site is on a hosted server and you have a dynamic IP, but
74 # only after you read "c-readme.txt" file.
75         if ($REMOTE_ADDR == $localip or $REMOTE_ADDR == $serverip)
76 #       if ($REMOTE_ADDR == substr_count($HTTP_USER_AGENT,$browser_id) > 0)
77                 $np = $ip;
78         else
79                 $np = $REMOTE_ADDR;
80         if ($np != $ip)
81                 $count += 1;
82         rewind ($fp);
83         fputs ($fp,substr($np."        ",0,15).$count);
84         fclose ($fp);
85         echo $count;
86 }
87 else {
88         $fp = fopen($cfile,"w");
89         $np = $REMOTE_ADDR;
90         $count = "1";
91         fputs ($fp,substr($np."        ",0,15).$count);
92         fclose ($fp);
93         echo $count;
94 }
95 ?>
96
97
98 <p>
99 <form action="http://privox.org/submit/confirmad.php" method="post">
100 <table border="0" cellpadding="0" cellspacing="4">
101
102 <tr>
103 <td align="right">Your name:</td>
104 <td>
105 <input name="submit_name" value="anonymous" type="text" size="30" maxlength="30">
106 </td>
107 <td>optional</td>
108 </tr>
109
110 <tr>
111 <td align="right">Your email address:</td>
112 <td>
113 <input name="submit_email" value="anonymous" type="text" size="30" maxlength="30">
114 </td>
115 <td>optional</td>
116 </tr>
117
118 <tr>
119 <td align="right">Website, where I observed an ad:</td>
120 <td>
121 <input name="submit_url" value="prefilled" type="text" size="45" maxlength="255">
122 </td>
123 <td>Please change, if necessary</td>
124 </tr>
125
126 <tr>
127 <td align="right">How annoying is the ad:</td>
128 <td>
129 <select name="submit_annoy" size="1">
130 <option value="A0">Nice, not to have</option>
131 <option selected value="A1">Should be removed</option>
132 <option value="A2">Must be removed</option>
133 </select>
134 </td>
135 <td>Please select one</td>
136 </tr>
137
138 <tr>
139 <td align="right">Privoxy Version:</td>
140 <td>
141 <input name="submit_pversion" value="prefilled" readonly type="text" size="30" maxlength="30">
142 </td>
143 <td>Automatically determined</td>
144 </tr>
145
146 <tr>
147 <td align="right">Action File:</td>
148 <td>
149 <input name="submit_actionfile" value="prefilled" readonly type="text" size="30" maxlength="30">
150 </td>
151 <td>Automatically determined</td>
152 </tr>
153
154 <tr>
155 <td align="right">Action File Version:</td>
156 <td>
157 <input name="submit_actionversion" value="prefilled" readonly type="text" size="30" maxlength="30">
158 </td>
159 <td>Automatically determined</td>
160 </tr>
161
162 <tr>
163 <td align="right">Remarks:</td>
164 <td>
165 <textarea name="submit_remarks" cols="35" rows="3">
166 None.
167 </textarea>
168 </td>
169 <td>Please change, if necessary</td>
170 </tr>
171
172 <tr>
173 <td align="right"></td>
174 <td>
175 <input type="hidden" name="submit_targeturl" value="/submit/confirmad.php">
176 <input type=submit value="Submit">
177 </td>
178 <td></td>
179 </tr>
180
181 </table>
182 </form>
183 </p>
184
185 <h2>Incorrect blocking</h2>
186 <p>We soon present a form where you can submit websites, where the
187 default action file was too agressive.</p>
188
189 <h2>Misc</h2>
190 <p>Bla bla bla</p>
191
192 </body>
193 </html>