[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Phpgroupware-cvs] dj adddirectory.php delete.php deletedirectory.... [V
From: |
Dave Hall |
Subject: |
[Phpgroupware-cvs] dj adddirectory.php delete.php deletedirectory.... [Version-0_9_16-branch] |
Date: |
Tue, 24 Oct 2006 06:53:06 +0000 |
CVSROOT: /sources/phpgroupware
Module name: dj
Branch: Version-0_9_16-branch
Changes by: Dave Hall <skwashd> 06/10/24 06:53:06
Modified files:
. : adddirectory.php delete.php deletedirectory.php
directories.php download.php edit.php
editdirectory.php import.php index.php
request.php scan.php show.php view.php
templates/default: import.tpl
Log message:
more cleanups and fixes
CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/dj/adddirectory.php?cvsroot=phpgroupware&only_with_tag=Version-0_9_16-branch&r1=1.3.2.1&r2=1.3.2.1.2.1
http://cvs.savannah.gnu.org/viewcvs/dj/delete.php?cvsroot=phpgroupware&only_with_tag=Version-0_9_16-branch&r1=1.5&r2=1.5.4.1
http://cvs.savannah.gnu.org/viewcvs/dj/deletedirectory.php?cvsroot=phpgroupware&only_with_tag=Version-0_9_16-branch&r1=1.4&r2=1.4.4.1
http://cvs.savannah.gnu.org/viewcvs/dj/directories.php?cvsroot=phpgroupware&only_with_tag=Version-0_9_16-branch&r1=1.5.2.1&r2=1.5.2.1.2.1
http://cvs.savannah.gnu.org/viewcvs/dj/download.php?cvsroot=phpgroupware&only_with_tag=Version-0_9_16-branch&r1=1.2&r2=1.2.4.1
http://cvs.savannah.gnu.org/viewcvs/dj/edit.php?cvsroot=phpgroupware&only_with_tag=Version-0_9_16-branch&r1=1.8&r2=1.8.4.1
http://cvs.savannah.gnu.org/viewcvs/dj/editdirectory.php?cvsroot=phpgroupware&only_with_tag=Version-0_9_16-branch&r1=1.3.2.1&r2=1.3.2.1.2.1
http://cvs.savannah.gnu.org/viewcvs/dj/import.php?cvsroot=phpgroupware&only_with_tag=Version-0_9_16-branch&r1=1.11.2.1.2.1&r2=1.11.2.1.2.2
http://cvs.savannah.gnu.org/viewcvs/dj/index.php?cvsroot=phpgroupware&only_with_tag=Version-0_9_16-branch&r1=1.22&r2=1.22.4.1
http://cvs.savannah.gnu.org/viewcvs/dj/request.php?cvsroot=phpgroupware&only_with_tag=Version-0_9_16-branch&r1=1.7&r2=1.7.4.1
http://cvs.savannah.gnu.org/viewcvs/dj/scan.php?cvsroot=phpgroupware&only_with_tag=Version-0_9_16-branch&r1=1.6.2.1&r2=1.6.2.1.2.1
http://cvs.savannah.gnu.org/viewcvs/dj/show.php?cvsroot=phpgroupware&only_with_tag=Version-0_9_16-branch&r1=1.8&r2=1.8.4.1
http://cvs.savannah.gnu.org/viewcvs/dj/view.php?cvsroot=phpgroupware&only_with_tag=Version-0_9_16-branch&r1=1.10&r2=1.10.4.1
http://cvs.savannah.gnu.org/viewcvs/dj/templates/default/import.tpl?cvsroot=phpgroupware&only_with_tag=Version-0_9_16-branch&r1=1.2.6.1&r2=1.2.6.2
Patches:
Index: adddirectory.php
===================================================================
RCS file: /sources/phpgroupware/dj/adddirectory.php,v
retrieving revision 1.3.2.1
retrieving revision 1.3.2.1.2.1
diff -u -b -r1.3.2.1 -r1.3.2.1.2.1
--- adddirectory.php 27 Feb 2003 21:48:38 -0000 1.3.2.1
+++ adddirectory.php 24 Oct 2006 06:53:05 -0000 1.3.2.1.2.1
@@ -9,20 +9,20 @@
* Free Software Foundation; either version 2 of the License, or (at your *
* option) any later version. *
\**************************************************************************/
-/* $Id: adddirectory.php,v 1.3.2.1 2003/02/27 21:48:38 gugux Exp $ */
+/* $Id: adddirectory.php,v 1.3.2.1.2.1 2006/10/24 06:53:05 skwashd Exp $ */
$GLOBALS['phpgw_info']["flags"]["currentapp"] = 'dj';
- include('../header.inc.php');
+ include_once('../header.inc.php');
$GLOBALS['phpgw']->template->set_file(array('form' =>
'directory_form.tpl'));
$GLOBALS['phpgw']->template->set_block('form','add','addhandle');
$GLOBALS['phpgw']->template->set_block('form','edit','edithandle');
- $submit = $HTTP_POST_VARS['submit'];
+ $submit = $_POST['submit'];
if ($submit)
{
- $dir_name = $HTTP_POST_VARS['dir_name'];
+ $dir_name =
$GLOBALS['phpgw']->db->db_addslashes($_POST['dir_name']);
$errorcount = 0;
@@ -54,9 +54,18 @@
}
}
- if ($errorcount) {
$GLOBALS['phpgw']->template->set_var('message',$GLOBALS['phpgw']->common->error_list($error));
}
- if (($submit) && (! $error) && (! $errorcount)) {
$GLOBALS['phpgw']->template->set_var('message',lang('Directory %1 has been
added !', $dir_name)); }
- if ((! $submit) && (! $error) && (! $errorcount)) {
$GLOBALS['phpgw']->template->set_var('message',''); }
+ if ($errorcount)
+ {
+
$GLOBALS['phpgw']->template->set_var('message',$GLOBALS['phpgw']->common->error_list($error));
+ }
+ if (($submit) && (! $error) && (! $errorcount))
+ {
+ $GLOBALS['phpgw']->template->set_var('message',lang('Directory
%1 has been added !', $dir_name));
+ }
+ if ((! $submit) && (! $error) && (! $errorcount))
+ {
+ $GLOBALS['phpgw']->template->set_var('message','');
+ }
$GLOBALS['phpgw']->template->set_var('title_directory',lang('Add
Directory'));
$GLOBALS['phpgw']->template->set_var('actionurl',$GLOBALS['phpgw']->link('/dj/adddirectory.php'));
Index: delete.php
===================================================================
RCS file: /sources/phpgroupware/dj/delete.php,v
retrieving revision 1.5
retrieving revision 1.5.4.1
diff -u -b -r1.5 -r1.5.4.1
--- delete.php 15 Sep 2001 12:02:51 -0000 1.5
+++ delete.php 24 Oct 2006 06:53:05 -0000 1.5.4.1
@@ -10,9 +10,9 @@
* option) any later version. *
\**************************************************************************/
- /* $Id: delete.php,v 1.5 2001/09/15 12:02:51 milosch Exp $ */
+ /* $Id: delete.php,v 1.5.4.1 2006/10/24 06:53:05 skwashd Exp $ */
- $confirm = $HTTP_POST_VARS['confirm'];
+ $confirm = $_POST['confirm'];
if ($confirm)
{
$GLOBALS['phpgw_info']['flags'] = array(
@@ -22,9 +22,9 @@
}
$GLOBALS['phpgw_info']['flags']['currentapp'] = 'dj';
- include('../header.inc.php');
+ include_once('../header.inc.php');
- $song_id = $HTTP_POST_VARS['song_id'] ? $HTTP_POST_VARS['song_id'] :
$HTTP_GET_VARS['song_id'];
+ $song_id = $_POST['song_id'] ? $_POST['song_id'] : $_GET['song_id'];
if (!$song_id)
{
Index: deletedirectory.php
===================================================================
RCS file: /sources/phpgroupware/dj/deletedirectory.php,v
retrieving revision 1.4
retrieving revision 1.4.4.1
diff -u -b -r1.4 -r1.4.4.1
--- deletedirectory.php 15 Sep 2001 12:02:51 -0000 1.4
+++ deletedirectory.php 24 Oct 2006 06:53:05 -0000 1.4.4.1
@@ -9,9 +9,9 @@
* Free Software Foundation; either version 2 of the License, or (at your *
* option) any later version. *
\**************************************************************************/
- /* $Id: deletedirectory.php,v 1.4 2001/09/15 12:02:51 milosch Exp $ */
+ /* $Id: deletedirectory.php,v 1.4.4.1 2006/10/24 06:53:05 skwashd Exp $ */
- $confirm = $HTTP_POST_VARS['confirm'];
+ $confirm = $_POST['confirm'];
if ($confirm)
{
$GLOBALS['phpgw_info']['flags'] = array(
@@ -21,9 +21,9 @@
}
$GLOBALS['phpgw_info']['flags']['currentapp'] = 'dj';
- include('../header.inc.php');
+ include_once('../header.inc.php');
- $dir_id = $HTTP_POST_VARS['dir_id'] ? $HTTP_POST_VARS['dir_id'] :
$HTTP_GET_VARS['dir_id'];
+ $dir_id = $_POST['dir_id'] ? $_POST['dir_id'] : $_GET['dir_id'];
if(!$GLOBALS['phpgw']->acl->check('run',1,'admin'))
{
Index: directories.php
===================================================================
RCS file: /sources/phpgroupware/dj/directories.php,v
retrieving revision 1.5.2.1
retrieving revision 1.5.2.1.2.1
diff -u -b -r1.5.2.1 -r1.5.2.1.2.1
--- directories.php 27 Feb 2003 21:48:38 -0000 1.5.2.1
+++ directories.php 24 Oct 2006 06:53:05 -0000 1.5.2.1.2.1
@@ -9,14 +9,14 @@
* Free Software Foundation; either version 2 of the License, or (at your *
* option) any later version. *
\**************************************************************************/
- /* $Id: directories.php,v 1.5.2.1 2003/02/27 21:48:38 gugux Exp $ */
+ /* $Id: directories.php,v 1.5.2.1.2.1 2006/10/24 06:53:05 skwashd Exp $ */
$GLOBALS['phpgw_info']['flags'] = array(
'currentapp' => 'dj',
'enable_nextmatchs_class' => True
);
- include('../header.inc.php');
+ include_once('../header.inc.php');
$GLOBALS['phpgw']->template->set_file(array('dir_list_t' =>
'listdirectories.tpl'));
$GLOBALS['phpgw']->template->set_block('dir_list_t','dir_list','list');
@@ -61,7 +61,7 @@
$querymethod = " WHERE dir_name like '%$query%'";
}
- $db2 = $GLOBALS['phpgw']->db;
+ $db2 =& $GLOBALS['phpgw']->db;
$sql = "SELECT * FROM phpgw_dj_directories $querymethod order by
dir_name $sort";
$db2->query($sql,__LINE__,__FILE__);
Index: download.php
===================================================================
RCS file: /sources/phpgroupware/dj/download.php,v
retrieving revision 1.2
retrieving revision 1.2.4.1
diff -u -b -r1.2 -r1.2.4.1
--- download.php 20 Jun 2001 00:23:28 -0000 1.2
+++ download.php 24 Oct 2006 06:53:05 -0000 1.2.4.1
@@ -10,9 +10,9 @@
* option) any later version. *
\**************************************************************************/
- /* $Id: download.php,v 1.2 2001/06/20 00:23:28 milosch Exp $ */
+ /* $Id: download.php,v 1.2.4.1 2006/10/24 06:53:05 skwashd Exp $ */
- $phpgw_info['flags'] = array(
+ $GLOBALS['phpgw_info']['flags'] = array(
'currentapp' => 'dj',
'enable_browser_class' => True,
'noheader' => True,
@@ -20,21 +20,21 @@
'noappheader' => True,
'noappfooter' => True
);
- include('../header.inc.php');
+ include_once('../header.inc.php');
$sep = SEP;
if (!$song_id)
{
- Header("Location: " . $phpgw->link("/dj/index.php"));
- $phpgw->common->phpgw_exit();
+ Header("Location: " . $GLOBALS['phpgw']->link("/dj/index.php"));
+ $GLOBALS['phpgw']->common->phpgw_exit();
}
else
{
- $sql = "SELECT song_name FROM phpgw_dj_songlist WHERE song_id="
. $song_id;
- $phpgw->db->query($sql);
- $phpgw->db->next_record();
- $filename = $phpgw->db->f(0);
+ $sql = "SELECT song_name FROM phpgw_dj_songlist WHERE song_id="
. (int) $song_id;
+ $GLOBALS['phpgw']->db->query($sql);
+ $GLOBALS['phpgw']->db->next_record();
+ $filename = $GLOBALS['phpgw']->db->f(0);
if ($filename)
{
@@ -44,7 +44,7 @@
fclose($fp);
}
-
$phpgw->browser->content_header($filename,'application/octet-stream',filesize($filename));
+
$GLOBALS['phpgw']->browser->content_header($filename,'application/octet-stream',filesize($filename));
echo $content;
}
}
Index: edit.php
===================================================================
RCS file: /sources/phpgroupware/dj/edit.php,v
retrieving revision 1.8
retrieving revision 1.8.4.1
diff -u -b -r1.8 -r1.8.4.1
--- edit.php 7 Jul 2001 18:04:44 -0000 1.8
+++ edit.php 24 Oct 2006 06:53:05 -0000 1.8.4.1
@@ -10,25 +10,25 @@
* option) any later version. *
\**************************************************************************/
- /* $Id: edit.php,v 1.8 2001/07/07 18:04:44 milosch Exp $ */
+ /* $Id: edit.php,v 1.8.4.1 2006/10/24 06:53:05 skwashd Exp $ */
- $phpgw_info['flags'] = array(
+ $GLOBALS['phpgw_info']['flags'] = array(
'currentapp' => 'dj',
'noheader' => True,
'nonavbar' => True,
'enable_categories_class' => True
);
- include('../header.inc.php');
+ include_once('../header.inc.php');
if (!$song_id)
{
- Header('Location: ' . $phpgw->link('/dj/index.php'));
- $phpgw->common->phpgw_exit();
+ Header('Location: ' . $GLOBALS['phpgw']->link('/dj/index.php'));
+ $GLOBALS['phpgw']->common->phpgw_exit();
}
if ($submit && $song_id)
{
- $genre = $phpgw->categories->id2name($cat_id);
+ $genre = $GLOBALS['phpgw']->categories->id2name($cat_id);
if ($song_status)
{
@@ -50,13 +50,13 @@
. "song_status='" . addslashes($song_status) . "'"
. " WHERE song_id=" . $song_id;
- $phpgw->db->query($sql);
+ $GLOBALS['phpgw']->db->query($sql);
- Header('Location: ' . $phpgw->link('/dj/view.php',"song_id=" .
$song_id));
- $phpgw->common->phpgw_exit();
+ Header('Location: ' .
$GLOBALS['phpgw']->link('/dj/view.php',"song_id=" . $song_id));
+ $GLOBALS['phpgw']->common->phpgw_exit();
}
- $phpgw->common->phpgw_header();
+ $GLOBALS['phpgw']->common->phpgw_header();
echo parse_navbar();
$t = CreateObject('phpgwapi.Template',PHPGW_APP_TPL);
@@ -69,29 +69,29 @@
if ($new_cat) { $cat_id = $new_cat; }
$t->set_var('lang_action',lang('Edit song'));
- $t->set_var('action_url',$phpgw->link('/dj/edit.php'));
+ $t->set_var('action_url',$GLOBALS['phpgw']->link('/dj/edit.php'));
- $phpgw->db->query("SELECT * FROM phpgw_dj_songlist WHERE
song_id='$song_id'");
- $phpgw->db->next_record();
+ $GLOBALS['phpgw']->db->query("SELECT * FROM phpgw_dj_songlist WHERE
song_id='$song_id'");
+ $GLOBALS['phpgw']->db->next_record();
- $t->set_var('song_name',$phpgw->db->f('song_name'));
- $t->set_var('song_title',$phpgw->db->f('song_title'));
- $t->set_var('song_artist',$phpgw->db->f('song_artist'));
- $t->set_var('song_album',$phpgw->db->f('song_album'));
- $t->set_var('song_year',$phpgw->db->f('song_year'));
- $t->set_var('song_comment',$phpgw->db->f('song_comment'));
- $cat_id = $phpgw->categories->name2id($phpgw->db->f('song_genre'));
+ $t->set_var('song_name',$GLOBALS['phpgw']->db->f('song_name'));
+ $t->set_var('song_title',$GLOBALS['phpgw']->db->f('song_title'));
+ $t->set_var('song_artist',$GLOBALS['phpgw']->db->f('song_artist'));
+ $t->set_var('song_album',$GLOBALS['phpgw']->db->f('song_album'));
+ $t->set_var('song_year',$GLOBALS['phpgw']->db->f('song_year'));
+ $t->set_var('song_comment',$GLOBALS['phpgw']->db->f('song_comment'));
+ $cat_id =
$GLOBALS['phpgw']->categories->name2id($GLOBALS['phpgw']->db->f('song_genre'));
$t->set_var('genre_option',cat_option($cat_id,True,False));
- $t->set_var('song_size',nicesize($phpgw->db->f('song_size')));
- $t->set_var('song_length',date('i:s',$phpgw->db->f('song_length')));
- $t->set_var('song_bitrate',$phpgw->db->f('song_bitsize') .
lang('kb/s'));
- $t->set_var('song_samplerate',$phpgw->db->f('song_samplerate') .
lang('hz'));
- $t->set_var('song_frames',$phpgw->db->f('song_frames'));
- $t->set_var('song_emphasis',$phpgw->db->f('song_emphasis'));
- $t->set_var('song_cmode',$phpgw->db->f('song_cmode'));
- $t->set_var('song_version',$phpgw->db->f('song_version'));
- $t->set_var('song_layer',$phpgw->db->f('song_layer'));
- if ($phpgw->db->f('song_crc'))
+
$t->set_var('song_size',nicesize($GLOBALS['phpgw']->db->f('song_size')));
+
$t->set_var('song_length',date('i:s',$GLOBALS['phpgw']->db->f('song_length')));
+ $t->set_var('song_bitrate',$GLOBALS['phpgw']->db->f('song_bitsize') .
lang('kb/s'));
+
$t->set_var('song_samplerate',$GLOBALS['phpgw']->db->f('song_samplerate') .
lang('hz'));
+ $t->set_var('song_frames',$GLOBALS['phpgw']->db->f('song_frames'));
+ $t->set_var('song_emphasis',$GLOBALS['phpgw']->db->f('song_emphasis'));
+ $t->set_var('song_cmode',$GLOBALS['phpgw']->db->f('song_cmode'));
+ $t->set_var('song_version',$GLOBALS['phpgw']->db->f('song_version'));
+ $t->set_var('song_layer',$GLOBALS['phpgw']->db->f('song_layer'));
+ if ($GLOBALS['phpgw']->db->f('song_crc'))
{
$t->set_var('song_crc',lang('disabled'));
}
@@ -100,7 +100,7 @@
$t->set_var('song_crc',lang('enabled'));
}
- if ($phpgw->db->f('song_copyright'))
+ if ($GLOBALS['phpgw']->db->f('song_copyright'))
{
$t->set_var('song_copyright',lang('Yes'));
}
@@ -109,7 +109,7 @@
$t->set_var('song_copyright',lang('No'));
}
- if($phpgw->db->f('song_original'))
+ if($GLOBALS['phpgw']->db->f('song_original'))
{
$t->set_var('song_original',lang('Yes'));
}
@@ -118,7 +118,7 @@
$t->set_var('song_original',lang('No'));
}
- if($phpgw->db->f('song_status') == 'A')
+ if($GLOBALS['phpgw']->db->f('song_status') == 'A')
{
$t->set_var('song_status',' checked');
$t->set_var('lang_status',lang('Unselect to make unavailable'));
@@ -128,7 +128,7 @@
$t->set_var('song_status','');
$t->set_var('lang_status',lang('Select to make available'));
}
- if($phpgw->db->f('song_cycle_status') == 'A')
+ if($GLOBALS['phpgw']->db->f('song_cycle_status') == 'A')
{
$t->set_var('song_cycle_status',lang('Available'));
}
@@ -171,14 +171,14 @@
$t->set_var('lang_cancel',lang('cancel'));
$t->set_var('lang_request',lang('request'));
$t->set_var('lang_submit',lang('submit'));
- $t->set_var('cancel_link','<form method="POST" action="' .
$phpgw->link('/dj/index.php') . '">');
- $t->set_var('request_link',$phpgw->link('/dj/request.php','song_id=' .
$song_id));
+ $t->set_var('cancel_link','<form method="POST" action="' .
$GLOBALS['phpgw']->link('/dj/index.php') . '">');
+
$t->set_var('request_link',$GLOBALS['phpgw']->link('/dj/request.php','song_id='
. $song_id));
- $t->set_var('delete_link','<form method="POST"
action="'.$phpgw->link('/dj/delete.php','song_id=' . $song_id) . '">');
+ $t->set_var('delete_link','<form method="POST"
action="'.$GLOBALS['phpgw']->link('/dj/delete.php','song_id=' . $song_id) .
'">');
$t->set_var('delete_button','<input type="submit" name="delete"
value="' . lang('Delete') . '">');
$t->pparse('out','form');
$t->pparse('out','footer');
- $phpgw->common->phpgw_footer();
+ $GLOBALS['phpgw']->common->phpgw_footer();
?>
Index: editdirectory.php
===================================================================
RCS file: /sources/phpgroupware/dj/editdirectory.php,v
retrieving revision 1.3.2.1
retrieving revision 1.3.2.1.2.1
diff -u -b -r1.3.2.1 -r1.3.2.1.2.1
--- editdirectory.php 28 Jan 2003 22:36:04 -0000 1.3.2.1
+++ editdirectory.php 24 Oct 2006 06:53:05 -0000 1.3.2.1.2.1
@@ -9,14 +9,14 @@
* Free Software Foundation; either version 2 of the License, or (at your *
* option) any later version. *
\**************************************************************************/
- /* $Id: editdirectory.php,v 1.3.2.1 2003/01/28 22:36:04 gugux Exp $ */
+ /* $Id: editdirectory.php,v 1.3.2.1.2.1 2006/10/24 06:53:05 skwashd Exp $ */
$GLOBALS['phpgw_info']['flags']['currentapp'] = 'dj';
- include('../header.inc.php');
+ include_once('../header.inc.php');
- $submit = $HTTP_POST_VARS['submit'];
- $dir_id = $HTTP_POST_VARS['dir_id'] ? $HTTP_POST_VARS['dir_id'] :
$HTTP_GET_VARS['dir_id'];
- $dir_name = $HTTP_POST_VARS['dir_name'] ? $HTTP_POST_VARS['dir_name'] :
$HTTP_GET_VARS['dir_name'];
+ $submit = $_POST['submit'];
+ $dir_id = $_POST['dir_id'] ? $_POST['dir_id'] : $_GET['dir_id'];
+ $dir_name = $_POST['dir_name'] ? $_POST['dir_name'] : $_GET['dir_name'];
if (!$dir_id)
{
Index: import.php
===================================================================
RCS file: /sources/phpgroupware/dj/import.php,v
retrieving revision 1.11.2.1.2.1
retrieving revision 1.11.2.1.2.2
diff -u -b -r1.11.2.1.2.1 -r1.11.2.1.2.2
--- import.php 24 Oct 2006 06:23:06 -0000 1.11.2.1.2.1
+++ import.php 24 Oct 2006 06:53:05 -0000 1.11.2.1.2.2
@@ -10,14 +10,14 @@
* option) any later version. *
\**************************************************************************/
- /* $Id: import.php,v 1.11.2.1.2.1 2006/10/24 06:23:06 skwashd Exp $ */
+ /* $Id: import.php,v 1.11.2.1.2.2 2006/10/24 06:53:05 skwashd Exp $ */
$GLOBALS['phpgw_info']['flags'] = array
(
'currentapp' => 'dj',
'enable_browser_class' => True
);
- include('../header.inc.php');
+ include_once('../header.inc.php');
$sep = SEP;
Index: index.php
===================================================================
RCS file: /sources/phpgroupware/dj/index.php,v
retrieving revision 1.22
retrieving revision 1.22.4.1
diff -u -b -r1.22 -r1.22.4.1
--- index.php 25 Sep 2001 01:23:16 -0000 1.22
+++ index.php 24 Oct 2006 06:53:05 -0000 1.22.4.1
@@ -10,14 +10,15 @@
* option) any later version. *
\**************************************************************************/
- /* $Id: index.php,v 1.22 2001/09/25 01:23:16 milosch Exp $ */
+ /* $Id: index.php,v 1.22.4.1 2006/10/24 06:53:05 skwashd Exp $ */
- $GLOBALS['phpgw_info']['flags'] = array(
+ $GLOBALS['phpgw_info']['flags'] = array
+ (
'enable_nextmatchs_class' => True,
'enable_categories_class' => True,
'currentapp' => 'dj'
);
- include('../header.inc.php');
+ include_once('../header.inc.php');
$data = $GLOBALS['phpgw']->session->appsession('session_data','dj');
get_form($data);
Index: request.php
===================================================================
RCS file: /sources/phpgroupware/dj/request.php,v
retrieving revision 1.7
retrieving revision 1.7.4.1
diff -u -b -r1.7 -r1.7.4.1
--- request.php 15 Sep 2001 12:05:51 -0000 1.7
+++ request.php 24 Oct 2006 06:53:05 -0000 1.7.4.1
@@ -10,39 +10,44 @@
* option) any later version. *
\**************************************************************************/
- /* $Id: request.php,v 1.7 2001/09/15 12:05:51 milosch Exp $ */
+ /* $Id: request.php,v 1.7.4.1 2006/10/24 06:53:05 skwashd Exp $ */
$GLOBALS['phpgw_info']['flags'] = array(
'currentapp' => 'dj',
'enable_nextmatchs_class' => True
);
- include('../header.inc.php');
+ include_once('../header.inc.php');
- $song_id = $HTTP_POST_VARS['song_id'] ? $HTTP_POST_VARS['song_id'] :
$HTTP_GET_VARS['song_id'];
- $songlist = $HTTP_POST_VARS['songlist'] ? $HTTP_POST_VARS['songlist'] :
$HTTP_GET_VARS['songlist'];
+ $song_id = (int) isset($_REQUEST['song_id']) ? $_REQUEST['song_id']
: 0;
+ $songlist = isset($_REQUEST['songlist']) ? $_REQUEST['songlist'] : '';
if ($song_id)
{
- $GLOBALS['phpgw']->db->query("SELECT * FROM phpgw_dj_songlist
WHERE song_id='$song_id'",__LINE__,__FILE__);
+ $GLOBALS['phpgw']->db->query("SELECT * FROM phpgw_dj_songlist
WHERE song_id = $song_id",__LINE__,__FILE__);
$GLOBALS['phpgw']->db->next_record();
$song_name = $GLOBALS['phpgw']->db->f('song_name');
- $GLOBALS['phpgw']->db->query("INSERT INTO phpgw_dj_que
(que_song) VALUES ('" . addslashes($song_name) . "')",__LINE__,__FILE__);
+ $GLOBALS['phpgw']->db->query("INSERT INTO phpgw_dj_que
(que_song) VALUES ('" . $GLOBALS['phpgw']->db->db_addslashes($song_name) .
"')",__LINE__,__FILE__);
}
- elseif($songlist)
+ else if ( count($songlist) )
{
$list = unserialize(rawurldecode($songlist));
- while (list($key,$song_id) = @each($list))
+ if ( !is_array($list) )
+ {
+ $list = array();
+ }
+
+ foreach ( $list as $song_id )
{
//echo '<br>' . $song_id;
- $GLOBALS['phpgw']->db->query("SELECT * FROM
phpgw_dj_songlist WHERE song_id='$song_id'",__LINE__,__FILE__);
+ $GLOBALS['phpgw']->db->query('SELECT * FROM
phpgw_dj_songlist WHERE song_id=' . (int)$song_id,__LINE__,__FILE__);
$GLOBALS['phpgw']->db->next_record();
- $song_name = $GLOBALS['phpgw']->db->f('song_name');
+ $song_name = $GLOBALS['phpgw']->db->f('song_name',
true);
- $GLOBALS['phpgw']->db->query("INSERT INTO phpgw_dj_que
(que_song) VALUES ('" . addslashes($song_name) . "')",__LINE__,__FILE__);
+ $GLOBALS['phpgw']->db->query("INSERT INTO phpgw_dj_que
(que_song) VALUES ('" . $GLOBALS['phpgw']->db->db_addslashes($song_name) .
"')",__LINE__,__FILE__);
}
}
@@ -62,13 +67,13 @@
$GLOBALS['phpgw']->db->query("select * from phpgw_dj_que order by
que_id asc",__LINE__,__FILE__);
while ($GLOBALS['phpgw']->db->next_record())
{
- $db2->query("select * from phpgw_dj_songlist where song_name='"
. addslashes($GLOBALS['phpgw']->db->f('que_song')) . "'",__LINE__,__FILE__);
+ $db2->query("select * from phpgw_dj_songlist where song_name='"
. $GLOBALS['phpgw']->db->db_addslashes($GLOBALS['phpgw']->db->f('que_song')) .
"'",__LINE__,__FILE__);
$db2->next_record();
$totaltime = $totaltime + $db2->f('song_length');
$GLOBALS['phpgw']->nextmatchs->template_alternate_row_color($GLOBALS['phpgw']->template);
-
$GLOBALS['phpgw']->template->set_var('row_title',trim($db2->f('song_title')));
-
$GLOBALS['phpgw']->template->set_var('row_artist',trim($db2->f('song_artist')));
+
$GLOBALS['phpgw']->template->set_var('row_title',trim($db2->f('song_title',
true)));
+
$GLOBALS['phpgw']->template->set_var('row_artist',trim($db2->f('song_artist',
true)));
$GLOBALS['phpgw']->template->set_var('row_year',trim($db2->f('song_year')));
$GLOBALS['phpgw']->template->set_var('row_genre',trim($db2->f('song_genre')));
$GLOBALS['phpgw']->template->set_var('row_time',date('i:s',$db2->f('song_length')));
Index: scan.php
===================================================================
RCS file: /sources/phpgroupware/dj/scan.php,v
retrieving revision 1.6.2.1
retrieving revision 1.6.2.1.2.1
diff -u -b -r1.6.2.1 -r1.6.2.1.2.1
--- scan.php 27 Feb 2003 21:48:38 -0000 1.6.2.1
+++ scan.php 24 Oct 2006 06:53:05 -0000 1.6.2.1.2.1
@@ -10,13 +10,13 @@
* option) any later version. *
\**************************************************************************/
- /* $Id: scan.php,v 1.6.2.1 2003/02/27 21:48:38 gugux Exp $ */
+ /* $Id: scan.php,v 1.6.2.1.2.1 2006/10/24 06:53:05 skwashd Exp $ */
$GLOBALS['phpgw_info']['flags'] = array(
'currentapp' => 'dj',
'enable_browser_class' => True
);
- include('../header.inc.php');
+ include_once('../header.inc.php');
$cats = CreateObject('phpgwapi.categories');
$num = 0;
Index: show.php
===================================================================
RCS file: /sources/phpgroupware/dj/show.php,v
retrieving revision 1.8
retrieving revision 1.8.4.1
diff -u -b -r1.8 -r1.8.4.1
--- show.php 30 Sep 2001 06:31:55 -0000 1.8
+++ show.php 24 Oct 2006 06:53:05 -0000 1.8.4.1
@@ -10,18 +10,18 @@
* option) any later version. *
\**************************************************************************/
- /* $Id: show.php,v 1.8 2001/09/30 06:31:55 milosch Exp $ */
+ /* $Id: show.php,v 1.8.4.1 2006/10/24 06:53:05 skwashd Exp $ */
$GLOBALS['phpgw_info']['flags'] = array(
'noheader' => True,
'nonavbar' => True,
'currentapp' => 'dj'
);
- include('../header.inc.php');
+ include_once('../header.inc.php');
- $request = $HTTP_POST_VARS['request'] ? $HTTP_POST_VARS['request'] :
$HTTP_GET_VARS['request'];
- $addshow = $HTTP_POST_VARS['addshow'] ? $HTTP_POST_VARS['addshow'] :
$HTTP_GET_VARS['addshow'];
- $songlist = $HTTP_POST_VARS['songlist'] ? $HTTP_POST_VARS['songlist'] :
$HTTP_GET_VARS['songlist'];
+ $request = $_POST['request'] ? $_POST['request'] : $_GET['request'];
+ $addshow = $_POST['addshow'] ? $_POST['addshow'] : $_GET['addshow'];
+ $songlist = $_POST['songlist'] ? $_POST['songlist'] : $_GET['songlist'];
if ($request)
{
Index: view.php
===================================================================
RCS file: /sources/phpgroupware/dj/view.php,v
retrieving revision 1.10
retrieving revision 1.10.4.1
diff -u -b -r1.10 -r1.10.4.1
--- view.php 15 Sep 2001 12:02:51 -0000 1.10
+++ view.php 24 Oct 2006 06:53:05 -0000 1.10.4.1
@@ -10,13 +10,13 @@
* option) any later version. *
\**************************************************************************/
- /* $Id: view.php,v 1.10 2001/09/15 12:02:51 milosch Exp $ */
+ /* $Id: view.php,v 1.10.4.1 2006/10/24 06:53:05 skwashd Exp $ */
$GLOBALS['phpgw_info']['flags'] = array(
'currentapp' => 'dj',
'enable_categories_class' => True
);
- include('../header.inc.php');
+ include_once('../header.inc.php');
if (!$song_id)
{
Index: templates/default/import.tpl
===================================================================
RCS file: /sources/phpgroupware/dj/templates/default/import.tpl,v
retrieving revision 1.2.6.1
retrieving revision 1.2.6.2
diff -u -b -r1.2.6.1 -r1.2.6.2
--- templates/default/import.tpl 24 Oct 2006 06:23:07 -0000 1.2.6.1
+++ templates/default/import.tpl 24 Oct 2006 06:53:06 -0000 1.2.6.2
@@ -34,11 +34,6 @@
<td width="8%">
<div align="left">
<form action="{cancel_url}" method="post">
- <input type="hidden" name="sort" value="{sort}">
- <input type="hidden" name="order" value="{order}">
- <input type="hidden" name="filter" value="{filter}">
- <input type="hidden" name="query" value="{query}">
- <input type="hidden" name="start" value="{start}">
<input type="submit" name="Cancel" value="{lang_cancel}">
</form>
</div>
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Phpgroupware-cvs] dj adddirectory.php delete.php deletedirectory.... [Version-0_9_16-branch],
Dave Hall <=