Update of /cvsroot/phpslash/phpslash-ft/class
In directory usw-pr-cvs1:/tmp/cvs-serv10154/phpslash-ft/class
Modified Files:
Infolog.class functions.inc Story.class
Log Message:
infolog uses _PSL now
Index: Infolog.class
===================================================================
RCS file: /cvsroot/phpslash/phpslash-ft/class/Infolog.class,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -d -r1.1 -r1.2
*** Infolog.class 2001/05/15 22:36:15 1.1
--- Infolog.class 2001/12/11 15:33:21 1.2
***************
*** 11,22 ****
class Infolog {
! var $templ;
! var $db;
!
/*
* CONSTRUCTORS
*/
function Infolog () {
! global $basedir,$rootdir, $templatedir;
/* Start a db */
--- 11,23 ----
class Infolog {
! var $templ, $db, $psl;
!
/*
* CONSTRUCTORS
*/
function Infolog () {
! global $_PSL;
!
! $this->psl = $_PSL;
/* Start a db */
***************
*** 24,28 ****
/* Templates */
! $this->templ = new Template($templatedir);
$this->templ->debug = 0;
$this->templ->set_file(array(
--- 25,29 ----
/* Templates */
! $this->templ = new Template($this->psl['templatedir']);
$this->templ->debug = 0;
$this->templ->set_file(array(
***************
*** 36,40 ****
function pageOut() {
- global $PHP_SELF;
$this->templ->set_block("infolog","row","rows");
--- 37,40 ----
***************
*** 42,46 ****
while ($this->db->next_record()) {
$this->templ->set_var(array(
! ACTION_URL => $PHP_SELF,
INFOLOG_ID => $this->db->Record[id],
INFOLOG_TIME => $this->db->Record[time],
--- 42,46 ----
while ($this->db->next_record()) {
$this->templ->set_var(array(
! ACTION_URL => $this->psl['phpself'],
INFOLOG_ID => $this->db->Record[id],
INFOLOG_TIME => $this->db->Record[time],
***************
*** 51,55 ****
}
$this->templ->set_var(array(
! ACTION_URL => $PHP_SELF
));
$this->templ->parse(OUT,array("infolog"));
--- 51,55 ----
}
$this->templ->set_var(array(
! ACTION_URL => $this->psl['phpself']
));
$this->templ->parse(OUT,array("infolog"));
Index: functions.inc
===================================================================
RCS file: /cvsroot/phpslash/phpslash-ft/class/functions.inc,v
retrieving revision 1.83
retrieving revision 1.84
diff -C2 -d -r1.83 -r1.84
*** functions.inc 2001/12/06 20:16:44 1.83
--- functions.inc 2001/12/11 15:33:21 1.84
***************
*** 241,247 ****
Function : logwrite()
Use: : Logs actions for admin evaluation later (adds time to entry)
! Parameters : $description => A short description of the loged data
(ie: Admin Login, Story Added)
! $data => The actualt data to log
(ie: admin login by $author_name ($author_id)
(ie: Story $story_title added by $author_name)
--- 241,247 ----
Function : logwrite()
Use: : Logs actions for admin evaluation later (adds time to entry)
! Parameters : $description => A short description of the logged data
(ie: Admin Login, Story Added)
! $data => The actual data to log
(ie: admin login by $author_name ($author_id)
(ie: Story $story_title added by $author_name)
***************
*** 249,255 ****
function logwrite($description,$data) {
! global $infolog_enable;
! if ($infolog_enable) {
// Init vars (we don't like warnings :)
$fdate = date("Y-m-d H:i:s",time());
--- 249,255 ----
function logwrite($description,$data) {
! global $_PSL;
! if ($_PSL[use_infolog]) {
// Init vars (we don't like warnings :)
$fdate = date("Y-m-d H:i:s",time());
Index: Story.class
===================================================================
RCS file: /cvsroot/phpslash/phpslash-ft/class/Story.class,v
retrieving revision 1.24
retrieving revision 1.25
diff -C2 -d -r1.24 -r1.25
*** Story.class 2001/12/07 21:23:25 1.24
--- Story.class 2001/12/11 15:33:21 1.25
***************
*** 1151,1156 ****
}
!
! logwrite("Story Admin", "$author_name ($author_id) added new story $story_id");
$this->template->parse(OUT,array("newstory"));
$this->template->p(OUT);
--- 1151,1156 ----
}
! $description = sprintf( "%s (%s) added new story %s as userid %s", $this->auth->auth['uname'], $this->auth->auth['uid'], $story_id, $user_id);
! logwrite("Story Admin", $description);
$this->template->parse(OUT,array("newstory"));
$this->template->p(OUT);
|