OpenPKG CVS Repository
http://cvs.openpkg.org/
____________________________________________________________________________
Server: cvs.openpkg.org Name: Ralf S. Engelschall
Root: /e/openpkg/cvs Email: [EMAIL PROTECTED]
Module: openpkg-web Date: 27-Feb-2004 21:03:29
Branch: HEAD Handle: 2004022720032900
Added files:
openpkg-web feedback.cgi feedback.cgi.wml feedback.wml
Log:
add feedback page to CVS
Summary:
Revision Changes Path
1.1 +120 -0 openpkg-web/feedback.cgi
1.1 +8 -0 openpkg-web/feedback.cgi.wml
1.1 +310 -0 openpkg-web/feedback.wml
____________________________________________________________________________
patch -p0 <<'@@ .'
Index: openpkg-web/feedback.cgi
============================================================================
$ cvs diff -u -r0 -r1.1 feedback.cgi
--- /dev/null 2004-02-27 21:03:29.000000000 +0100
+++ feedback.cgi 2004-02-27 21:03:29.000000000 +0100
@@ -0,0 +1,120 @@
+#!/e/openpkg/sw/bin/perl -w
+##
+## feedback.cgi -- Send feedback mail
+## Copyright (c) 1999-2003 Ralf S. Engelschall, All Rights Reserved.
+##
+
+use CGI;
+
+# switch to unbuffered I/O
+$|++;
+
+my $cgi = new CGI;
+
+# generate a webpage
+sub send_page {
+ my ($text) = @_;
+
+ $O = '';
+ $O .= "Content-type: text/html\n" .
+ "Connection: close\n" .
+ "\n";
+ open(FP, "<feedback.cgi.head.html");
+ $O .= $_ while (<FP>);
+ close(FP);
+ $O .= $text;
+ open(FP, "<feedback.cgi.foot.html");
+ $O .= $_ while (<FP>);
+ close(FP);
+ print $O;
+}
+
+# let us catch runtime errors...
+eval {
+
+# check for parameter consistency
+die "You supplied no Personal Name."
+ if ($cgi->param("person-name") eq '');
+die "Hmmm... <tt>".$cgi->param('person-email')."</tt> doesn't look like a valid
RFC822 mail address."
+ if ($cgi->param("person-email") ne '' and $cgi->param("person-email") !~
m|^[a-zA-Z0-9_=%,.~+-]+@([a-zA-Z0-9]+)(\.[a-zA-Z0-9]+)*$|);
+
+# generate mail
+my $mail = '';
+$mail .= "From: \"".$cgi->param('person-name')."\"
<".$cgi->param('person-email').">\n";
+$mail .= "Reply-To: ".$cgi->param('person-email')."\n";
+$mail .= "Subject: OpenPKG Community Feedback\n";
+$mail .= "To: [EMAIL PROTECTED]";
+$mail .= "\n";
+$mail .= "Remote Client Information:\n";
+foreach my $var (qw(
+ REMOTE_ADDR
+ HTTP_USER_AGENT
+)) {
+ $mail .= sprintf(" %-21s", "$var:") . $ENV{$var} . "\n";
+}
+$mail .= "\n";
+$mail .= "Feedback Form Information:\n";
+foreach my $item (qw(
+ person-name
+ person-email
+ organisation-name
+ organisation-url
+ organisation-class
+ heard-month
+ heard-year
+ heard-media
+ usage-phase
+ usage-platforms
+ usage-machines
+ usage-multiinstance
+ usage-environment
+ usage-release
+ feedback-reqpackage
+ feedback-like
+ feedback-dislike
+ advocacy-statement
+)) {
+ my $text = join(", ", $cgi->param($item));
+ $text =~ s|\r?\n$||s;
+ $text =~ s|\n|"\n"." ".(" " x 21)|sge;
+ $mail .= sprintf(" %-21s", "$item:") . $text . "\n";
+}
+$mail .= "\n";
+
+# send out mail
+open(MAIL, "|/e/openpkg/sw/sbin/sendmail -oi -oee [EMAIL PROTECTED]") || die;
+print MAIL $mail;
+close(MAIL);
+
+# generate result page
+my $mail_html = $mail;
+$mail_html =~ s|&|&|sg;
+$mail_html =~ s|<|<|sg;
+$mail_html =~ s|>|>|sg;
+&send_page(
+ "Thanks. Your feedback was successfully parsed " .
+ "and forwarded to the OpenPKG project."
+ # "leader via Email in the following format:" .
+ # "<p>" .
+ # "<table width=100% cellpadding=5 bgcolor=\"#e5e0d5\"><tr><td>" .
+ # "<pre>$mail_html</pre>\n" .
+ # "</td></tr></table>"
+);
+
+# die gracefully
+exit(0);
+
+# ...the runtime error handler:
+};
+if ($@) {
+ my $text = $@;
+ $text =~ s|at /.*||;
+ &send_page(
+ "A fatal error occured while processing the contents of your " .
+ "feedback. Please check the error message below, go back to" .
+ "the form and fix the problem." .
+ "<p>\n" .
+ "<font color=\"#cc3333\"><b>$text</b></font>\n"
+ );
+}
+
@@ .
patch -p0 <<'@@ .'
Index: openpkg-web/feedback.cgi.wml
============================================================================
$ cvs diff -u -r0 -r1.1 feedback.cgi.wml
--- /dev/null 2004-02-27 21:03:29.000000000 +0100
+++ feedback.cgi.wml 2004-02-27 21:03:29.000000000 +0100
@@ -0,0 +1,8 @@
+#!wml -oPAGE_HEADuPAGE_BODY:feedback.cgi.head.html
-oPAGE_FOOT:feedback.cgi.foot.html
+
+#use "page.inc" page=feedback
+
+<title>Community Feedback</title>
+
+<h1>Community Feedback</h1>
+
@@ .
patch -p0 <<'@@ .'
Index: openpkg-web/feedback.wml
============================================================================
$ cvs diff -u -r0 -r1.1 feedback.wml
--- /dev/null 2004-02-27 21:03:29.000000000 +0100
+++ feedback.wml 2004-02-27 21:03:29.000000000 +0100
@@ -0,0 +1,310 @@
+
+#use "page.inc" page=feedback
+
+<title>Community Feedback</title>
+
+<h1>Community Feedback</h1>
+
+Feedback from our community is very important to us. So if you want
+to support the OpenPKG project, please fill out the feedback form. It
+allows us to better understand our community and also develop
+the OpenPKG project according to your wishes.
+
+<p>
+The feedback form content is directly sent to the OpenPKG team for
+individual consideration and is treated confidentially. As an exception,
+if you explicitly include a personal <i>Public Advocacy Statement</i>
+(see last point in form), your information might be publically quoted by the OpenPKG
+project.
+
+<p>
+<style type="text/css">
+table.feedback {
+ width: 100%;
+ margin: 2px;
+ padding: 0px;
+ border: 0;
+}
+.feedback td.Q {
+ width: 40%;
+ background-color: #e5e5e5;
+ -moz-border-radius: 10px 0 0 10px;
+ padding: 4px 10px 4px 20px;
+}
+.feedback td.A {
+ width: 60%;
+ border-bottom: 1px solid #e5e5e5;
+}
+.feedback td.QM {
+ width: 40%;
+ background-color: #e5e0d5;
+ -moz-border-radius: 10px 0 0 10px;
+ padding: 4px 10px 4px 20px;
+}
+.feedback td.AM {
+ width: 60%;
+ border-bottom: 1px solid #e5e0d5;
+}
+.feedback td.QS {
+ width: 40%;
+ background-color: #e5e0d5;
+ -moz-border-radius: 10px 0 0 10px;
+ padding: 4px 10px 4px 20px;
+}
+.feedback td.AS {
+ width: 60%;
+ border-bottom: 1px solid #e5e5e5;
+}
+span.hint {
+ font-size: 80%;
+ color: #666666;
+}
+input.submit {
+ font-weight: bold;
+ background-color: #e5e0d5;
+ width: 100%;
+}
+</style>
+<center>
+<form action="feedback.cgi" method="POST">
+<table class="feedback">
+ <tr>
+ <td class=QM>
+ What is your <b>name</b>?
+ </td>
+ <td class=AM>
+ <input type=text name="person-name" size=40 value="">
+ <br><span class=hint>(mandatory, e.g., "John Doe")</span>
+ </td>
+ </tr>
+ <tr>
+ <td class=Q>
+ What is your <b>email</b> address?
+ </td>
+ <td class=A>
+ <input type=text name="person-email" size=40 value="">
+ <br><span class=hint>(optional, e.g., "[EMAIL PROTECTED]")</span>
+ </td>
+ </tr>
+ <tr>
+ <td class=Q>
+ What is your <b>organisation</b>?
+ </td>
+ <td class=A>
+ <input type=text name="organisation-name" size=40 value="">
+ <br><span class=hint>(optional, e.g., "Example Enterprises, Inc.")</span>
+ </td>
+ </tr>
+ <tr>
+ <td class=Q>
+ What is your <b>organisation URL</b>?
+ </td>
+ <td class=A>
+ <input type=text name="organisation-url" size=40 value="">
+ <br><span class=hint>(optional, e.g., "http://www.example.com/")</span>
+ </td>
+ </tr>
+ <tr>
+ <td class=Q>
+ What is your <b>organisation class</b>?
+ </td>
+ <td class=A>
+ <select name="organisation-class">
+ <option value="">----</option>
+ <option value="com">Commercial</option>
+ <option value="edu">Educational</option>
+ <option value="gov">Government</option>
+ <option value="mil">Military</option>
+ <option value="med">Medical</option>
+ <option value="prv">Private/Home</option>
+ <option value="oth">Other</option>
+ </select>
+ <br><span class=hint>(optional)</span>
+ </td>
+ </tr>
+ <tr>
+ <td class=Q>
+ <b>When</b> did you <b>first hear</b> about OpenPKG?
+ </td>
+ <td class=A>
+ <select name="heard-month">
+ <option value="" selected>---</option>
+ <option value="01">Jan</option>
+ <option value="02">Feb</option>
+ <option value="03">Mar</option>
+ <option value="04">Apr</option>
+ <option value="05">May</option>
+ <option value="06">Jun</option>
+ <option value="07">Jul</option>
+ <option value="08">Aug</option>
+ <option value="09">Sep</option>
+ <option value="10">Oct</option>
+ <option value="11">Nov</option>
+ <option value="12">Dec</option>
+ </select>
+ <select name="heard-year">
+ <option value="">----</option>
+ <option value="2000">2000</option>
+ <option value="2001">2001</option>
+ <option value="2002">2002</option>
+ <option value="2003">2003</option>
+ </select>
+ <br><span class=hint>(optional)</span>
+ </td>
+ </tr>
+ <tr>
+ <td class=Q>
+ <b>Where</b> did you <b>first hear</b> about OpenPKG?
+ </td>
+ <td class=A>
+ <select name="heard-media">
+ <option value="" selected>----</option>
+ <option value="internet">Internet</option>
+ <option value="magazine">Magazine</option>
+ <option value="friend">Friend</option>
+ </select>
+ <br><span class=hint>(optional)</span>
+ </td>
+ </tr>
+ <tr>
+ <td class=Q>
+ To which <b>degree</b> do you use OpenPKG?
+ </td>
+ <td class=A>
+ <select name="usage-phase">
+ <option value="" selected>----</option>
+ <option value="info">Information</option>
+ <option value="eval">Evaluation</option>
+ <option value="prod">Production</option>
+ </select>
+ <br><span class=hint>(optional)</span>
+ </td>
+ </tr>
+ <tr>
+ <td class=Q>
+ On which <b>platform(s)</b> do you use OpenPKG?
+ </td>
+ <td class=A>
+ <input type=checkbox name="usage-platforms"
value="freebsd"> FreeBSD
+ <input type=checkbox name="usage-platforms"
value="linux"> GNU/Linux
+ <input type=checkbox name="usage-platforms" value="solaris"> Sun Solaris
+ <br>
+ <input type=checkbox name="usage-platforms" value="other"> Other:
+ <input type=text name="usage-platforms" size=30 value="">
+ <br><span class=hint>(optional)</span>
+ </td>
+ </tr>
+ <tr>
+ <td class=Q>
+ On <b>how many machines</b> do you use OpenPKG?
+ </td>
+ <td class=A>
+ <select name="usage-machines">
+ <option value="" selected>---</option>
+ <option value="1">1</option>
+ <option value="2-5">2-5</option>
+ <option value="5-10">5-10</option>
+ <option value="10-20">10-20</option>
+ <option value="20-50">20-50</option>
+ <option value="50-100">50-100</option>
+ <option value="100-500">100-500</option>
+ <option value="500-1000">500-1000</option>
+ <option value="1000-...">1000-...</option>
+ </select>
+ <br><span class=hint>(optional)</span>
+ </td>
+ </tr>
+ <tr>
+ <td class=Q>
+ Do you <b>run multiple instances</b> of OpenPKG on single machines?
+ </td>
+ <td class=A>
+ <select name="usage-multiinstance">
+ <option value="" selected>---</option>
+ <option value="yes">Yes</option>
+ <option value="no">No</option>
+ </select>
+ <br><span class=hint>(optional)</span>
+ </td>
+ </tr>
+ <tr>
+ <td class=Q>
+ In which <b>environment</b> do you deploy OpenPKG instances?
+ </td>
+ <td class=A>
+ <input type=checkbox name="usage-environment"
value="system"> System-wide for all users<br>
+ <input type=checkbox name="usage-environment" value="user"> Locally for
a single non-privileged user
+ <br><span class=hint>(optional)</span>
+ </td>
+ </tr>
+ <tr>
+ <td class=Q>
+ Which <b>releases</b> of OpenPKG do you use?
+ </td>
+ <td class=A>
+ <input type=checkbox name="usage-release"
value="1.0"> 1.0-RELEASE
+ <input type=checkbox name="usage-release"
value="1.1"> 1.1-RELEASE
+ <br>
+ <input type=checkbox name="usage-release"
value="1.2"> 1.2-RELEASE
+ <input type=checkbox name="usage-release"
value="1.3"> 1.3-RELEASE
+ <br>
+ <input type=checkbox name="usage-release"
value="2.0"> 2.0-RELEASE
+ <input type=checkbox name="usage-release" value="CUR"> CURRENT
+ <br><span class=hint>(optional)</span>
+ </td>
+ </tr>
+ <tr>
+ <td class=Q>
+ Which additional <b>unpackaged</b> Open Source software
+ products would you like to have packaged by OpenPKG?
+ </td>
+ <td class=A>
+ <textarea name="feedback-reqpackage" cols=40 rows=4></textarea>
+ <br><span class=hint>(optional)</span>
+ </td>
+ </tr>
+ <tr>
+ <td class=Q>
+ What do you <b>like most</b> about OpenPKG? That is, what
+ should be <b>kept</b> as is?
+ </td>
+ <td class=A>
+ <textarea name="feedback-like" cols=40 rows=4></textarea>
+ <br><span class=hint>(optional)</span>
+ </td>
+ </tr>
+ <tr>
+ <td class=Q>
+ What do you <b>dislike most</b> about OpenPKG?
+ What should be <b>improved</b>?
+ What <b>missing features</b> would you like to have?
+ </td>
+ <td class=A>
+ <textarea name="feedback-dislike" cols=40 rows=4></textarea>
+ <br><span class=hint>(optional)</span>
+ </td>
+ </tr>
+ <tr>
+ <td class=QS>
+ Your OpenPKG <b>Public Advocacy Statement</b>:
+ <br>
+ <span class="hint">
+ (if provided, includes the approval for quotation by the OpenPKG project,
possibly on our forthcoming <a
+ href="advocacy.html">Community Advocacy</a> page).
+ </span>
+ </td>
+ <td class=AS>
+ <textarea name="advocacy-statement" cols=40 rows=4></textarea>
+ <br><span class=hint>(optional)</span>
+ </td>
+ </tr>
+ <tr>
+ <td colspan=2>
+ <input class="submit" type=submit value="Submit!">
+ </td>
+ </tr>
+</tr>
+</table>
+</form>
+</center>
+
@@ .
______________________________________________________________________
The OpenPKG Project www.openpkg.org
CVS Repository Commit List [EMAIL PROTECTED]