Update of /cvsroot/phpslash/phpslash-ft/class
In directory usw-pr-cvs1:/tmp/cvs-serv27781/phpslash-ft/class
Modified Files:
Block.class Block_i.class
Log Message:
individual block permissions
Index: Block.class
===================================================================
RCS file: /cvsroot/phpslash/phpslash-ft/class/Block.class,v
retrieving revision 1.11
retrieving revision 1.12
diff -C2 -d -r1.11 -r1.12
*** Block.class 6 Feb 2002 18:47:43 -0000 1.11
--- Block.class 7 Mar 2002 21:07:20 -0000 1.12
***************
*** 12,16 ****
/* Var's to be constructed in constructor */
! var $db, $block_info, $parser, $parsedData, $parser_arr, $block_ary, $_PSL;
/**
--- 12,16 ----
/* Var's to be constructed in constructor */
! var $db, $block_info, $parser, $parsedData, $parser_arr, $block_ary, $_PSL, $perm;
/**
***************
*** 25,29 ****
function Block() {
/* Constructor: Create sub-objects here, etc... */
! global $_PSL;
$this->db = new slashDB;
--- 25,29 ----
function Block() {
/* Constructor: Create sub-objects here, etc... */
! global $_PSL, $perm;
$this->db = new slashDB;
***************
*** 31,35 ****
$this->psl = $_PSL;
!
/* Array to store block info in */
$this->block_info = array();
--- 31,36 ----
$this->psl = $_PSL;
! $this->perm = $perm;
!
/* Array to store block info in */
$this->block_info = array();
***************
*** 394,400 ****
}
}
!
! return getFancyBox($width, $temptitle, $this->block_info["cache_data"],$link, $box_type);
!
}
--- 395,403 ----
}
}
! if( !is_string($this->block_info['block_options']['perms'])) {
! return getFancyBox($width, $temptitle, $this->block_info["cache_data"],$link, $box_type);
! } elseif ($this->perm->have_perm($this->block_info['block_options']['perms'])) {
! return getFancyBox($width, $temptitle, $this->block_info["cache_data"],$link, $box_type);
! }
}
***************
*** 583,585 ****
} /* End class Block */
! ?>
\ No newline at end of file
--- 586,588 ----
} /* End class Block */
! ?>
Index: Block_i.class
===================================================================
RCS file: /cvsroot/phpslash/phpslash-ft/class/Block_i.class,v
retrieving revision 1.15
retrieving revision 1.16
diff -C2 -d -r1.15 -r1.16
*** Block_i.class 21 Feb 2002 18:08:36 -0000 1.15
--- Block_i.class 7 Mar 2002 21:07:20 -0000 1.16
***************
*** 323,327 ****
function getBlocks($ary, $column="") {
!
// debug("Block_i.class::getBlocks::ary", $ary);
--- 323,327 ----
function getBlocks($ary, $column="") {
!
// debug("Block_i.class::getBlocks::ary", $ary);
***************
*** 333,339 ****
$output = "";
for ($i=0; $i < count($this->block_ary); $i++) {
!
! $output .= $this->parseBlock($this->block_ary[$i], $column);
!
}
--- 333,342 ----
$output = "";
for ($i=0; $i < count($this->block_ary); $i++) {
!
! if( !isset($this->block_ary[$i]['block_options']['perms'])) {
! $output .= $this->parseBlock($this->block_ary[$i], $column);
! } elseif ($this->perm->have_perm($this->block_ary[$i]['block_options']['perms'])) {
! $output .= $this->parseBlock($this->block_ary[$i], $column);
! }
}
|