Skip to content

Commit

Permalink
* #221 To upgrade your db please execute: sqlite3 db/database.db "alt…
Browse files Browse the repository at this point in the history
…er table feeds add column title text"

* #303 basic check for validating .torrent
* #217 Set focus on username field at login screen 
* truncate rss items to fit
* et_EE update
* #220 hu_HU update
* #79 - Feeds view too long 
* wtorrent#35 - custom title to rss feed
* #370 - URL upload causes "File does not exist!"
* xmlrpc lib update


git-svn-id: http://wtorrent-project.googlecode.com/svn/trunk@100 5a4c1571-8183-a91d-cfd1-48c08a65d015
  • Loading branch information
yllar committed Oct 18, 2009
1 parent aecb5af commit 283c051
Show file tree
Hide file tree
Showing 10 changed files with 453 additions and 264 deletions.
2 changes: 1 addition & 1 deletion wtorrent/cls/install.cls.php
Expand Up @@ -190,7 +190,7 @@ private function saveConfig($options)
$db->modify('CREATE TABLE tor_passwd(id integer primary key, user text, passwd text, admin integer, dir text, force_dir integer)');
$db->modify('INSERT INTO tor_passwd VALUES(1, ?, ?, 1, \'\', 0)', $options['user'], md5($options['passwd']));
$db->modify('CREATE TABLE torrents(hash string, user int, private int)');
$db->modify('CREATE TABLE feeds(id integer primary key, url text, user integer)');
$db->modify('CREATE TABLE feeds(id integer primary key, url text, title text, user integer)');
$db->modify('CREATE TABLE cookie(id integer primary key, userid integer, value text, hostname text)');
} else {
$this->addMessage($this->_str['db_create_err']);
Expand Down
25 changes: 24 additions & 1 deletion wtorrent/lib/cls/Web.cls.php
Expand Up @@ -16,7 +16,7 @@
along with this program. If not, see <http://www.gnu.org/licenses/>.
Original class done by David Marco Martinez
Modified by Roger Pau Monné
Modified by Roger Pau Monné
*/
abstract class Web
{
Expand Down Expand Up @@ -321,6 +321,29 @@ protected function addMessage($message)
{
$this->message[] = $message;
}
/**
* Get a string parameter or $default if not set
*/
protected function getParam($name, $default = '', $realm = null)
{
if ($realm == null)
{
$realm = $this->_request;
}
return strval(empty($realm[$name]) ? $default : $realm[$name]);
}
/**
* Get an int parameter or $default if not set
*/
protected function getParamInt($name, $default = '', $realm = null)
{
if ($realm == null)
{
$realm = $this->_request;
}
return intval(!isset($realm[$name]) ? $default : $realm[$name]);
}

abstract protected function construct( );
}
?>

0 comments on commit 283c051

Please sign in to comment.