0) { $sql="SELECT a.comments FROM ".$xoopsDB->prefix("xcgal_albums")." as a, ".$xoopsDB->prefix("xcgal_pictures")." as p WHERE a.aid=p.aid AND p.pid=".$com_itemid.""; $result = $xoopsDB->query($sql); $CURRENT_ALBUM_DATA = $xoopsDB->fetchArray($result); } if (USER_CAN_POST_COMMENTS && $CURRENT_ALBUM_DATA['comments'] == 'YES') include XOOPS_ROOT_PATH.'/include/comment_reply.php'; else redirect_header('index.php',2,"You aren't allowed to post comments for this pic."); ?>