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