cvs: pearweb / package.php package.xml /public_html account-info.php

From: Date: Thu, 04 Jan 2007 10:33:02 +0000
Subject: cvs: pearweb / package.php package.xml /public_html account-info.php
Groups: php.pear.cvs php.pear.core 
Request: Send a blank email to pear-core+get-5328@lists.php.net to get a copy of this message
mj Thu Jan 4 10:33:02 2007 UTC Modified files: /pearweb package.php package.xml /pearweb/public_html account-info.php Log: * Start of streamlining thie different user-related URLs by switching the wishlist URL format from /wishlist.php/<handle> to /user/<handle>/wishlist. http://cvs.php.net/viewvc.cgi/pearweb/package.php?r1=1.53&r2=1.54&diff_format=u Index: pearweb/package.php diff -u pearweb/package.php:1.53 pearweb/package.php:1.54 --- pearweb/package.php:1.53 Sun Dec 31 09:38:03 2006 +++ pearweb/package.php Thu Jan 4 10:33:01 2007 @@ -28,6 +28,7 @@ $a->addPackageDepWithChannel('required', 'PEAR', 'pear.php.net', '1.4.11'); $a->addPackageDepWithChannel('required', 'Archive_Tar', 'pear.php.net', '1.3.1'); $a->addPackageDepWithChannel('required', 'HTTP_Request', 'pear.php.net', '1.2.2'); +$a->addPackageDepWithChannel('required', 'HTTP', 'pear.php.net', '1.4.0'); // used only in cron jobs $a->addPackageDepWithChannel('required', 'VFS', 'pear.php.net', '0.1.0'); $a->addPackageDepWithChannel('required', 'DB', 'pear.php.net', '1.6.5'); http://cvs.php.net/viewvc.cgi/pearweb/package.xml?r1=1.86&r2=1.87&diff_format=u Index: pearweb/package.xml diff -u pearweb/package.xml:1.86 pearweb/package.xml:1.87 --- pearweb/package.xml:1.86 Thu Dec 28 00:06:59 2006 +++ pearweb/package.xml Thu Jan 4 10:33:01 2007 @@ -667,6 +667,11 @@ <min>1.2.2</min> </package> <package> + <name>HTTP</name> + <channel>pear.php.net</channel> + <min>1.4.0</min> + </package> + <package> <name>VFS</name> <channel>pear.php.net</channel> <min>0.1.0</min> http://cvs.php.net/viewvc.cgi/pearweb/public_html/account-info.php?r1=1.45&r2=1.46&diff_format=u Index: pearweb/public_html/account-info.php diff -u pearweb/public_html/account-info.php:1.45 pearweb/public_html/account-info.php:1.46 --- pearweb/public_html/account-info.php:1.45 Sat Dec 16 23:07:44 2006 +++ pearweb/public_html/account-info.php Thu Jan 4 10:33:02 2007 @@ -15,19 +15,20 @@ +----------------------------------------------------------------------+ | Authors: | +----------------------------------------------------------------------+ - $Id: account-info.php,v 1.45 2006/12/16 23:07:44 cellog Exp $ + $Id: account-info.php,v 1.46 2007/01/04 10:33:02 mj Exp $ */ /** * Details about PEAR accounts */ require_once 'Damblan/URL.php'; +require_once 'HTTP.php'; $site = new Damblan_URL(); -$params = array('handle' => ''); +$params = array('handle' => '', 'action' => ''); $site->getElements($params); -$handle = strtolower($params['handle']); +$handle = htmlspecialchars(strtolower($params['handle'])); /* * Redirect to the accounts list if no handle was specified @@ -44,7 +45,24 @@ error_handler($handle . ' is not a valid account name.', 'Invalid Account'); } -$handle = htmlspecialchars($handle); +switch ($params['action']) { + case "wishlist" : + if (!empty($row['wishlist'])) { + HTTP::redirect($row['wishlist']); + } else { + PEAR::raiseError(htmlspecialchars($row['name']) . " has not registered a wishlist"); + } + break; + + case "bugs" : + HTTP::redirect("/bugs/search.php?handle=" . $handle . "&cmd=display"); + break; + + case "rss" : + HTTP::redirect("/feeds/user_" . $handle . ".rss"); + break; + +} response_header('User Information :: ' . htmlspecialchars($row['name'])); @@ -132,7 +150,7 @@ if ($row['wishlist']) { echo '<li>Wishlist: &nbsp;'; - print_link('http://' . htmlspecialchars($_SERVER['HTTP_HOST']) . '/wishlist.php/' . $handle); + print_link('http://' . htmlspecialchars($_SERVER['HTTP_HOST']) . '/user/' . $handle . '/wishlist'); echo "</li>\n"; }

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