#140 Manage Block Types includes phpslash

NEXT RELEASE
closed-accepted
blocks (19)
5
2002-02-21
2002-02-20
Anonymous
No

In the adminBlock screen, phpslash is currently
(incorrectly?) included in the available Block Types...

This diff adds the appropriate check:

420a421
> ( 0 !=
strcasecmp($eachfile,'Block_render_phpslash.class') )
AND // Dont show the template class

The loop now reads:
while( $eachfile = $fulldirlist->read()) {
$each = $this->psl['classdir'] . "/" .
$eachfile;
if( (is_file($each)) AND
( $each != ".") AND
( $each != "..") AND
( $each != "CVS") AND
( 0 !=
strcasecmp($eachfile,'Block_render_phpslash.class') )
AND // Dont show the template class
( preg_match('/Block_render_/i', $each)) ) {

Another point is - I'm not sure what the ".", ".." and
"CVS" tests achieve here since we are already doing an
is_file() and they would fail the preg_match. Could
they be deleted?

Discussion

  • Joe Stewart

    Joe Stewart - 2002-02-21

    Logged In: YES
    user_id=77269

    This problem has been corrected in the CVS. Please update
    your copy of PHPSlash, or wait for the next release.

    Made the changes to Block_i.class.
    Block_render_phpslash.class has been deleted from the cvs
    and won't be a part of the next release.

     
  • Joe Stewart

    Joe Stewart - 2002-02-21
    • labels: --> blocks
    • milestone: --> NEXT RELEASE
    • assigned_to: nobody --> joestewart
    • status: open --> closed-accepted
     

Log in to post a comment.