svn: /pear/pearweb/trunk/public_html/pepr/ pepr-votes-show.php

From: Date: Sun, 27 Mar 2011 03:09:17 +0000
Subject: svn: /pear/pearweb/trunk/public_html/pepr/ pepr-votes-show.php
Groups: php.pear.cvs php.pear.core 
Request: Send a blank email to pear-core+get-9834@lists.php.net to get a copy of this message
clockwerx Sun, 27 Mar 2011 03:09:17 +0000 Revision: http://svn.php.net/viewvc?view=revision&revision=309728 Log: Minor cleanup Changed paths: U pear/pearweb/trunk/public_html/pepr/pepr-votes-show.php Modified: pear/pearweb/trunk/public_html/pepr/pepr-votes-show.php =================================================================== --- pear/pearweb/trunk/public_html/pepr/pepr-votes-show.php 2011-03-27 02:19:04 UTC (rev 309727) +++ pear/pearweb/trunk/public_html/pepr/pepr-votes-show.php 2011-03-27 03:09:17 UTC (rev 309728) @@ -24,8 +24,9 @@ * Obtain the common functions and classes. */ require_once 'pepr/pepr.php'; +require_once 'HTML/QuickForm.php'; -if (!$proposal =& proposal::get($dbh, @$_GET['id'])) { +if (!isset($_GET['id']) || !($proposal = proposal::get($dbh, $_GET['id']))) { response_header('PEPr :: Votes :: Invalid Request'); echo "<h1>Proposal Votes</h1>\n"; report_error('The requested proposal does not exist.'); @@ -33,13 +34,12 @@ exit; } -include_once 'HTML/QuickForm.php'; response_header('PEPr :: Votes :: ' . htmlspecialchars($proposal->pkg_name)); echo '<h1>Proposal Votes for "' . htmlspecialchars($proposal->pkg_name) . "\"</h1>\n"; if ($auth_user && $proposal->mayVote($dbh, $auth_user->handle)) { - $form =& new HTML_QuickForm('vote', 'post', + $form = new HTML_QuickForm('vote', 'post', 'pepr-votes-show.php?id=' . $proposal->id); $form->removeAttribute('name');

« previous php.pear.core (#9834) next »