summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--BitBoard.php23
-rw-r--r--BitBoardPost.php27
-rw-r--r--BitBoardTopic.php16
-rw-r--r--admin/admin_bitboards_inc.php32
-rw-r--r--ajax.php4
-rw-r--r--board.php124
-rw-r--r--post.php6
-rw-r--r--styles/bitboards.css12
-rw-r--r--templates/board.tpl92
-rw-r--r--templates/post.tpl25
-rw-r--r--templates/topic.tpl24
-rw-r--r--templates/topic_move.tpl6
12 files changed, 173 insertions, 218 deletions
diff --git a/BitBoard.php b/BitBoard.php
index 15a7e56..44071ac 100644
--- a/BitBoard.php
+++ b/BitBoard.php
@@ -1,7 +1,7 @@
<?php
/**
-* $Header: /cvsroot/bitweaver/_bit_boards/BitBoard.php,v 1.6 2006/07/27 23:00:39 hash9 Exp $
-* $Id: BitBoard.php,v 1.6 2006/07/27 23:00:39 hash9 Exp $
+* $Header: /cvsroot/bitweaver/_bit_boards/BitBoard.php,v 1.7 2006/07/29 15:09:59 hash9 Exp $
+* $Id: BitBoard.php,v 1.7 2006/07/29 15:09:59 hash9 Exp $
*/
/**
@@ -10,7 +10,7 @@
*
* @date created 2004/8/15
* @author spider <spider@steelsun.com>
-* @version $Revision: 1.6 $ $Date: 2006/07/27 23:00:39 $ $Author: hash9 $
+* @version $Revision: 1.7 $ $Date: 2006/07/29 15:09:59 $ $Author: hash9 $
* @class BitBoard
*/
@@ -373,6 +373,21 @@ class BitBoard extends LibertyAttachable {
$whereSql .= " AND UPPER( lc.`title` )like ? ";
$bindVars[] = '%' . strtoupper( $find ). '%';
}
+
+ $pagination=true;
+ if (!empty($pParamHash['paginationOff'])) {
+ $pagination=false;
+ }
+
+ if (!empty($pParamHash['boards']) && is_array($pParamHash['boards'])) {
+ $whereSql .= " AND lc.`content_id` IN ( ".implode( ',',array_fill( 0,count( $pParamHash['boards'] ),'?' ) )." )";
+ $bindVars = array_merge ( $bindVars, $pParamHash['boards'] );
+ }
+ if (!empty($pParamHash['nboards']) && is_array($pParamHash['nboards'])) {
+ $whereSql .= " AND lc.`content_id` NOT IN ( ".implode( ',',array_fill( 0,count( $pParamHash['nboards'] ),'?' ) )." )";
+ $bindVars = array_merge ( $bindVars, $pParamHash['nboards'] );
+ }
+
$track = $gBitSystem->isFeatureActive('bitboards_thread_track');
$track = true;
if ($track) {
@@ -417,7 +432,7 @@ WHERE map.`board_content_id`=lc.`content_id` AND ((s_lc.`user_id` < 0) AND (s.`a
$query_cant = "select count(*)
FROM `".BIT_DB_PREFIX."forum_board` ts INNER JOIN `".BIT_DB_PREFIX."liberty_content` lc ON( lc.`content_id` = ts.`content_id` ) $joinSql
WHERE lc.`content_type_guid` = ? $whereSql";
- $result = $this->mDb->query( $query, $bindVars, $max_records, $offset );
+ $result = $this->mDb->query( $query, $bindVars );
$ret = array();
while( $res = $result->fetchRow() ) {
$res['url']= BITBOARDS_PKG_URL."index.php?b={$res['board_id']}";
diff --git a/BitBoardPost.php b/BitBoardPost.php
index 00219d4..2a5b40c 100644
--- a/BitBoardPost.php
+++ b/BitBoardPost.php
@@ -1,7 +1,7 @@
<?php
/**
-* $Header: /cvsroot/bitweaver/_bit_boards/BitBoardPost.php,v 1.5 2006/07/26 22:45:29 hash9 Exp $
-* $Id: BitBoardPost.php,v 1.5 2006/07/26 22:45:29 hash9 Exp $
+* $Header: /cvsroot/bitweaver/_bit_boards/BitBoardPost.php,v 1.6 2006/07/29 15:10:00 hash9 Exp $
+* $Id: BitBoardPost.php,v 1.6 2006/07/29 15:10:00 hash9 Exp $
*/
/**
@@ -10,7 +10,7 @@
*
* @date created 2004/8/15
* @author spider <spider@steelsun.com>
-* @version $Revision: 1.5 $ $Date: 2006/07/26 22:45:29 $ $Author: hash9 $
+* @version $Revision: 1.6 $ $Date: 2006/07/29 15:10:00 $ $Author: hash9 $
* @class BitMBPost
*/
@@ -69,24 +69,6 @@ class BitBoardPost extends LibertyComment {
$ret = array();
$contentId = $this->mCommentId;
- $mid = "";
-
- $sort_order = "ASC";
- $mid = 'last_modified ASC';
- if (!empty($pSortOrder)) {
- if ($pSortOrder == 'commentDate_desc') {
- $mid = 'last_modified DESC';
- } else if ($pSortOrder == 'commentDate_asc') {
- $mid = 'last_modified ASC';
- } elseif ($pSortOrder == 'thread_asc') {
- $mid = 'thread_forward_sequence ASC';
- // thread newest first is harder...
- } elseif ($pSortOrder == 'thread_desc') {
- $mid = 'thread_reverse_sequence ASC';
- } else {
- $mid = $this->mDb->convert_sortmode( $pSortOrder );
- }
- }
$mid = 'thread_forward_sequence ASC';
$mid = 'order by ' . $mid;
@@ -102,9 +84,6 @@ class BitBoardPost extends LibertyComment {
$join1 = '';
}
-
-
-
if ($gBitSystem->isFeatureActive('bitboards_post_anon_moderation') && !($gBitUser->hasPermission('p_bitboards_edit') || $gBitUser->hasPermission('p_bitboards_post_edit'))) {
$whereSql .= " AND ((post.`approved` = 1) OR (lc.`user_id` >= 0))";
}
diff --git a/BitBoardTopic.php b/BitBoardTopic.php
index d61604d..09db205 100644
--- a/BitBoardTopic.php
+++ b/BitBoardTopic.php
@@ -1,7 +1,7 @@
<?php
/**
-* $Header: /cvsroot/bitweaver/_bit_boards/BitBoardTopic.php,v 1.8 2006/07/27 23:00:40 hash9 Exp $
-* $Id: BitBoardTopic.php,v 1.8 2006/07/27 23:00:40 hash9 Exp $
+* $Header: /cvsroot/bitweaver/_bit_boards/BitBoardTopic.php,v 1.9 2006/07/29 15:10:00 hash9 Exp $
+* $Id: BitBoardTopic.php,v 1.9 2006/07/29 15:10:00 hash9 Exp $
*/
/**
@@ -10,7 +10,7 @@
*
* @date created 2004/8/15
* @author spider <spider@steelsun.com>
-* @version $Revision: 1.8 $ $Date: 2006/07/27 23:00:40 $ $Author: hash9 $
+* @version $Revision: 1.9 $ $Date: 2006/07/29 15:10:00 $ $Author: hash9 $
* @class BitBoardTopic
*/
@@ -125,7 +125,7 @@ WHERE
}
/**
- * This function locks a thread
+ * This function locks a topic
**/
function lock($state) {
global $gBitSystem;
@@ -150,7 +150,7 @@ WHERE
}
/**
- * This function stickies a thread
+ * This function stickies a topic
**/
function sticky($state) {
global $gBitSystem;
@@ -175,7 +175,7 @@ WHERE
}
/**
- * This function moves a thread to a new messageboard
+ * This function moves a topic to a new messageboard
**/
function moveTo($board_id) {
$ret = FALSE;
@@ -237,8 +237,7 @@ WHERE
$bindVars = array_merge ( $bindVars, $find );
} elseif( is_string( $find ) ) {
// or a string
- $whereSql .= " AND UPPER( flc.`title` )like ? ";
- $bindVars[] = '%' . strtoupper( $find ). '%';
+ $whereSql .= " AND UPPER( lc.`title` ) LIKE '%". strtoupper( $find ). "%'";
}
if(!empty($pParamHash['b'])) {
@@ -265,7 +264,6 @@ WHERE SUBSTRING(s_lcom.`thread_forward_sequence`,1,10) LIKE SUBSTRING(lcom.`thre
}
$sort_sql = "flc.".$this->mDb->convert_sortmode( $sort_mode );
- //flc.*, first.*, th.*, last.*, llc.*
$query = "SELECT
lc.`user_id` AS flc_user_id,
diff --git a/admin/admin_bitboards_inc.php b/admin/admin_bitboards_inc.php
index ecc8654..84fdb81 100644
--- a/admin/admin_bitboards_inc.php
+++ b/admin/admin_bitboards_inc.php
@@ -1,5 +1,5 @@
<?php
-// $Header: /cvsroot/bitweaver/_bit_boards/admin/Attic/admin_bitboards_inc.php,v 1.5 2006/07/26 22:45:29 hash9 Exp $
+// $Header: /cvsroot/bitweaver/_bit_boards/admin/Attic/admin_bitboards_inc.php,v 1.6 2006/07/29 15:10:00 hash9 Exp $
// Copyright (c) 2005 bitweaver BitForum
// All Rights Reserved. See copyright.txt for details and a complete list of authors.
// Licensed under the GNU LESSER GENERAL PUBLIC LICENSE. See license.txt for details.
@@ -14,35 +14,13 @@ require_once( BITBOARDS_PKG_PATH.'BitBoard.php' );
require_once( BITBOARDS_PKG_PATH.'BitBoardForum.php' );
$formBitForumLists = array(
- "bitboards_list_bitforum_id" => array(
- 'label' => 'Id',
- 'note' => 'Display the bitboard id.',
- ),
- "bitboards_list_title" => array(
- 'label' => 'Title',
- 'note' => 'Display the title.',
- ),
- "bitboards_list_description" => array(
- 'label' => 'Description',
- 'note' => 'Display the description.',
- ),
- "bitboards_list_data" => array(
- 'label' => 'Text',
- 'note' => 'Display the text.',
- ),
- "bitboards_no_boards_perpage" => array(
- 'label' => 'No Boards Per Page',
- ),
- "bitboards_no_threads_perpage" => array(
- 'label' => 'No Threads Per Page',
- ),
'bitboards_thread_track' => array(
- 'label' => 'Enable Thread Status Tracking',
- 'note' => 'Allow users to see what threads have been changed since they last logged on',
+ 'label' => 'Enable Topic Status Tracking',
+ 'note' => 'Allow users to see what topic have been changed since they last logged on',
),
'bitboards_thread_notification' => array(
- 'label' => 'Enable Thread Reply Notification',
- 'note' => 'Allow users to be sent emails when threads they are interested in recive replies',
+ 'label' => 'Enable Topic Reply Notification',
+ 'note' => 'Allow users to be sent emails when topics they are interested in recive replies',
),
'bitboards_post_anon_moderation' => array(
'label' => 'Enable Forced Anon Post Moderation',
diff --git a/ajax.php b/ajax.php
index b04b5fe..2d830d8 100644
--- a/ajax.php
+++ b/ajax.php
@@ -4,8 +4,8 @@
*
* reqs:
* 1 - list all boards
- * 2 - switch lock state on a given thread
- * 3 - switch sticky state on a given thread
+ * 2 - switch lock state on a given topic
+ * 3 - switch sticky state on a given topic
*/
require_once( '../bit_setup_inc.php' );
diff --git a/board.php b/board.php
index f43c21a..e313f13 100644
--- a/board.php
+++ b/board.php
@@ -1,10 +1,15 @@
<?php
-// $Header: /cvsroot/bitweaver/_bit_boards/Attic/board.php,v 1.4 2006/07/12 16:57:33 hash9 Exp $
+// $Header: /cvsroot/bitweaver/_bit_boards/Attic/board.php,v 1.5 2006/07/29 15:10:00 hash9 Exp $
// Copyright (c) 2004 bitweaver Messageboards
// All Rights Reserved. See copyright.txt for details and a complete list of authors.
// Licensed under the GNU LESSER GENERAL PUBLIC LICENSE. See license.txt for details.
// Initialization
+require_once("../bit_setup_inc.php");
+require_once(PIGEONHOLES_PKG_PATH.'Pigeonholes.php');
+require_once( BITBOARDS_PKG_PATH.'BitBoardTopic.php' );
+require_once( BITBOARDS_PKG_PATH.'BitBoardPost.php' );
require_once( BITBOARDS_PKG_PATH.'BitBoard.php' );
+require_once( BITBOARDS_PKG_PATH.'BitBoardForum.php' );
// Is package installed and enabled
$gBitSystem->verifyPackage( 'bitboards' );
@@ -12,53 +17,92 @@ $gBitSystem->verifyPackage( 'bitboards' );
// Now check permissions to access this page
$gBitSystem->verifyPermission( 'p_bitboards_read' );
-/* mass-remove:
-the checkboxes are sent as the array $_REQUEST["checked[]"], values are the wiki-PageNames,
-e.g. $_REQUEST["checked"][3]="HomePage"
-$_REQUEST["submit_mult"] holds the value of the "with selected do..."-option list
-we look if any page's checkbox is on and if remove_bitboards is selected.
-then we check permission to delete bitboards.
-if so, we call histlib's method remove_all_versions for all the checked bitboards.
-*/
+$ns = array();
+$board_all_cids =array();
-if( isset( $_REQUEST["submit_mult"] ) && isset( $_REQUEST["checked"] ) && $_REQUEST["submit_mult"] == "remove_bitboards" ) {
+if($gBitSystem->isPackageActive('pigeonholes')) {
- // Now check permissions to remove the selected bitboard
- $gBitSystem->verifyPermission( 'p_bitboards_remove' );
+ $p = new Pigeonholes();
+ $s = new LibertyStructure();
- if( !empty( $_REQUEST['cancel'] ) ) {
- // user cancelled - just continue on, doing nothing
- } elseif( empty( $_REQUEST['confirm'] ) ) {
- $formHash['delete'] = TRUE;
- $formHash['submit_mult'] = 'remove_bitboards';
- foreach( $_REQUEST["checked"] as $del ) {
- $formHash['input'][] = '<input type="hidden" name="checked[]" value="'.$del.'"/>';
- }
- $gBitSystem->confirmDialog( $formHash, array( 'warning' => 'Are you sure you want to delete '.count( $_REQUEST["checked"] ).' Boards?', 'error' => 'This cannot be undone!' ) );
- } else {
- foreach( $_REQUEST["checked"] as $deleteId ) {
- $tmpPage = new BitMBBoard( $deleteId );
- if( !$tmpPage->load() || !$tmpPage->expunge() ) {
- array_merge( $errors, array_values( $tmpPage->mErrors ) );
+ $listHash = array('load_only_root'=> TRUE);
+ $l = $p->getList($listHash);
+ foreach ($l as $e) {
+ $d = $s->getSubTree( $e['structure_id'] );
+ $d_o = array();
+ foreach ($d as $c) {
+ $pos_var = &$d_o;
+ if($c['level']!=0) {
+ $pos = explode(".",$c['pos']);
+ $pos_var = &$d_o;
+ foreach ($pos as $pos_v) {
+ if (!isset($pos_var['children'])) {
+ $pos_var['children']=array();
+ }
+ if (!isset($pos_var['children'][$pos_v-1])) {
+ $pos_var['children'][$pos_v-1]=array();
+ }
+ $pos_var = &$pos_var['children'][$pos_v-1];
+ }
+ }
+ if (empty($pos_var['data'])) {
+ $pos_var['children']=array();
+ $pos_var['data']=$c;
+ $mlHash=array();
+ $mlHash['content_id']=$c['content_id'];
+ $mlHash['content_type_guid']='bitforum';
+ $pos_var['members']=$p->getMemberList($mlHash);
+ $board_cids =array();
+ foreach ($pos_var['members'] as $boardKey) {
+ $board_cids[] = $boardKey['content_id'];
+ }
+ if (count($board_cids)>0) {
+ $blHash = array('boards'=>$board_cids,'paginationOff'=>'y');
+ $b = new BitBoard();
+ $pos_var['members'] = $b->getList($blHash);
+ $pos_var['pagination']=$blHash['listInfo'];
+ $board_all_cids = array_merge($board_all_cids,$board_cids);
+ }
}
}
- if( !empty( $errors ) ) {
- $gBitSmarty->assign_by_ref( 'errors', $errors );
- }
+ $ns[]=$d_o;
}
+
+}
+
+$rest =array();
+if($gBitSystem->isPackageActive('pigeonholes')) {
+ $rest['data']['title']="Uncategoried Boards";
+} else {
+ $rest['data']['title']="Board List";
+}
+$rest['children']=array();
+$blHash = array('nboards'=>$board_all_cids,'paginationOff'=>'y');
+$b = new BitBoard();
+$rest['members'] = $b->getList($blHash);
+if (count($rest['members'])>0) {
+ $ns[] = $rest;
}
-// create new bitboard object
-$boards = new BitBoard();
-$boardsList = $boards->getList( $_REQUEST );
-$gBitSmarty->assign_by_ref( 'boardsList', $boardsList );
-/*if (!empty($_REQUEST['content_type_guid'])) {
- $gBitSmarty->assign_by_ref( 'cType', $gLibertySystem->mContentTypes[$_REQUEST['content_type_guid']] );
-}*/
-// getList() has now placed all the pagination information in $_REQUEST['listInfo']
-$gBitSmarty->assign_by_ref( 'listInfo', $_REQUEST['listInfo'] );
+$gBitSmarty->assign_by_ref('ns',$ns);
+
+function countBoards(&$a) {
+ $s = 0;
+ if (count($a['children'])==0) {
+ return 1;
+ }
+ foreach ($a['children'] as $c) {
+ $s += countBoards($c);
+ }
+ $a['sub_count']= $s;
+ return $s;
+}
+
+foreach ($ns as $k=> $a) {
+ $ns[$k]['sub_count']= countBoards($ns[$k]);
+}
-// Display the template
-$gBitSystem->display( 'bitpackage:bitboards/board.tpl', tra( 'Forums' ) );
+//$gBitSmarty->display( 'bitpackage:bitboards/cat_display.tpl');
+$gBitSystem->display( 'bitpackage:bitboards/board.tpl', tra( 'Boards' ) );
?>
diff --git a/post.php b/post.php
index 21a35fb..970b627 100644
--- a/post.php
+++ b/post.php
@@ -45,7 +45,7 @@ if (empty($thread->mInfo['th_root_id'])) {
$tb = new BitBoard(null,$thread->mInfo['board_content_id']);
header("Location: ".$tb->getDisplayUrl());
} else {
- $gBitSystem->fatalError(tra( "Invalid thread selection." ) );
+ $gBitSystem->fatalError(tra( "Invalid topic selection." ) );
}
}
$thread->readTopic();
@@ -62,6 +62,10 @@ $comments_return_url= BITBOARDS_PKG_URL."index.php?t={$thread->mRootId}";
$gComment = new BitBoardPost($_REQUEST['t']);
$gBitSmarty->assign('comment_template','bitpackage:bitboards/post_display.tpl');
+if( empty( $_REQUEST["comments_style"] ) ) {
+ $_REQUEST["comments_style"] = "flats";
+}
+
require_once (LIBERTY_PKG_PATH.'comments_inc.php');
$postComment['registration_date']=$gBitUser->mInfo['registration_date'];
diff --git a/styles/bitboards.css b/styles/bitboards.css
index 447ce5b..0712543 100644
--- a/styles/bitboards.css
+++ b/styles/bitboards.css
@@ -44,6 +44,17 @@
border-bottom:1px solid #339933;
}
+.mb-cat-list h2 {
+ margin: 2px;
+ margin-top: 0.3em;
+ margin-bottom: 0.3em;
+}
+
+.mb-cat-indent {
+ padding: 2px;
+ padding-left: 2em;
+}
+
.mb-table .header h1 {
background-image: none;
}
@@ -89,4 +100,5 @@
margin-left: 1.3em;
border: 1px #aaa solid;
background: #f7f7f7;
+ padding: 2px;
} \ No newline at end of file
diff --git a/templates/board.tpl b/templates/board.tpl
index ea7c254..ba3ed20 100644
--- a/templates/board.tpl
+++ b/templates/board.tpl
@@ -1,96 +1,18 @@
-{* $Header: /cvsroot/bitweaver/_bit_boards/templates/Attic/board.tpl,v 1.6 2006/07/27 23:00:40 hash9 Exp $ *}
+{* $Header: /cvsroot/bitweaver/_bit_boards/templates/Attic/board.tpl,v 1.7 2006/07/29 15:10:00 hash9 Exp $ *}
{strip}
<div class="floaticon">{bithelp}</div>
<div class="listing bitboard">
<div class="header">
- <h1>Forums</h1>
+ <h1>Boards</h1>
</div>
<div class="body">
- {minifind sort_mode=$sort_mode b=$smarty.request.b}
- {form id="checkform"}
- <input type="hidden" name="offset" value="{$control.offset|escape}" />
- <input type="hidden" name="sort_mode" value="{$control.sort_mode|escape}" />
-
- <table class="mb-table">
- {if !$gBitSystem->isFeatureActive('bitboards_thread_verbrose')}
- <th width="1">{if $boardsList.0.track.on}<small>UBSI</small>{/if}</td>
- <th style="text-align:left;white-space: nowrap;">Title</td><br />
- {if $gBitUser->hasPermission('p_bitboards_edit') || $gBitUser->hasPermission('p_bitboards_post_edit')}
- <th style="text-align: center;">Anon</td>
- {/if}
- <th style="text-align: center;">Topics</td>
- <th style="text-align: center;">Last Topic</td>
- <th style="text-align: center;">Poster</td>
- <th style="text-align: right;">Updated</td>
- {/if}
- {foreach item=board from=$boardsList}
- {if $board.title}
- {assign var=board_title value=$board.title|escape}
- {else}
- {assign var=board_title value=$board.content_id|escape}
- {assign var=board_title value="(Content $board_title)"}
- {/if}
- {cycle values="even,odd" print=false assign=cycle_var}
- <tr class="{$cycle_var} {if $board.unreg > 0} mb-{$cycle_var}-unapproved{/if}">
- <td class="actionicon" width="1px">{* thread tracking icons *}
- {if $board.track.on && $board.track.mod}
- {biticon ipackage=bitboard iname="track_new_l" iexplain="New Posts"}
- {elseif $board.track.on}
- {biticon ipackage=bitboard iname="track_old_l" iexplain="No New Posts"}
- {/if}
- </td>
- <td><a href="{$board.url}" title="{$board_title}">{$board_title}</a><div style="margin-left:2em;" class="small">{$board.parsed_data}</blockquote></td>
- {if $gBitSystem->isFeatureActive('bitboards_thread_verbrose')}
- {if $gBitUser->hasPermission('p_bitboards_edit') || $gBitUser->hasPermission('p_bitboards_post_edit')}
- <td style="text-align:right;">{if $board.unreg > 0}<a style="color: blue;" href="{$board.url}" title="{$board.title|escape}">{$board.unreg}&nbsp;Unregistered&nbsp;Posts</a>{/if}</td>
- {/if}
- <td style="text-align:right; color: blue;">{if $board.post_count > 0}{$board.post_count}&nbsp;Threads</a>{/if}</td>
- {else}
- {if $gBitUser->hasPermission('p_bitboards_edit') || $gBitUser->hasPermission('p_bitboards_post_edit')}
- <td style="text-align:center;">{if $board.unreg > 0}<a style="color: blue;" href="{$board.url}" title="{$board.title|escape}">{$board.unreg}</a>{/if}</td>
- {/if}
- <td style="text-align:center;">{if $board.post_count > 0}{$board.post_count}</a>{/if}</td>
- {if !empty($board.last)}
- <td style="text-align:center;"><a href="{$board.last.url}">{$board.last.title}</td>
- <td style="text-align:center;">{if $board.last.user_id < 0}{$board.last.l_anon_name|escape}{else}{displayname user_id=$board.last.user_id}{/if}</td>
- <td style="text-align:right;">{if $board.last.last_modified > 0}{$board.last.last_modified|reltime}</a>{/if}</td>
- {else}
- <td></td>
- <td></td>
- <td></td>
- {/if}
- {/if}
- </tr>
- {foreachelse}
- <tr class="norecords"><td colspan="16">
- {tr}No records found{/tr}
- </td></tr>
- {/foreach}
- </table>
- {*
- {if $gBitUser->hasPermission( 'p_bitboards_remove' )}
- <div style="text-align:right;">
- <script type="text/javascript">/* <![CDATA[ check / uncheck all */
- document.write("<label for=\"switcher\">{tr}Select All{/tr}</label> ");
- document.write("<input name=\"switcher\" id=\"switcher\" type=\"checkbox\" onclick=\"switchCheckboxes(this.form.id,'checked[]','switcher')\" /><br />");
- /* ]]> */</script>
-
- <select name="submit_mult" onchange="this.form.submit();">
- <option value="" selected="selected">{tr}with checked{/tr}:</option>
- {if $gBitUser->hasPermission( 'p_bitboards_remove' )}
- <option value="remove_bitboards">{tr}remove{/tr}</option>
- {/if}
- </select>
-
- <noscript><div><input type="submit" value="{tr}Submit{/tr}" /></div></noscript>
- </div>
- {/if}
- *}
- {/form}
-
- {pagination b=$smarty.request.b}
+ <div class="mb-cat-list">
+ {foreach from=$ns item=child}
+ {include file="bitpackage:bitboards/board_cat.tpl" child=$child color=$color}
+ {/foreach}
+ </div>
</div><!-- end .body -->
</div><!-- end .admin -->
{/strip}
diff --git a/templates/post.tpl b/templates/post.tpl
index 8cfb594..733960a 100644
--- a/templates/post.tpl
+++ b/templates/post.tpl
@@ -1,11 +1,11 @@
-{* $Header: /cvsroot/bitweaver/_bit_boards/templates/Attic/post.tpl,v 1.8 2006/07/27 23:00:40 hash9 Exp $ *}
+{* $Header: /cvsroot/bitweaver/_bit_boards/templates/Attic/post.tpl,v 1.9 2006/07/29 15:10:00 hash9 Exp $ *}
{strip}
<div class="floaticon">
{assign var=flip value=$thread->getFlipFlop()}
{foreach from=$flip item=flip_s key=flip_name}
{include file="bitpackage:bitboards/flipswitch.tpl"}
{/foreach}
-{if !$topic_locked}<a title="{tr}Post on this thread{/tr}" href="{$comments_return_url}&post_comment_reply_id={$thread->mInfo.flc_content_id}&post_comment_request=1#editcomments"> {biticon ipackage=bitboard iname="mail_new" iexplain="Post on this thread"}</a>{/if}
+{if !$topic_locked}<a title="{tr}Post Reply{/tr}" href="{$comments_return_url}&post_comment_reply_id={$thread->mInfo.flc_content_id}&post_comment_request=1#editcomments"> {biticon ipackage=bitboard iname="mail_new" iexplain="Post Reply"}</a>{/if}
{bithelp}</div>
@@ -16,8 +16,21 @@
</div>
<div class="body">
- {include file="bitpackage:liberty/comments_display_option_bar.tpl"}
- {minifind sort_mode=$sort_mode thread_id=$smarty.request.thread_id}
+ <form action="{$comments_return_url}" style="padding: 0.2em; margin: 0.2em; text-align:right" class="small" method="post">
+ <input type="hidden" name="t" value="{$smarty.request.t}" />
+ <input type="hidden" name="comment_page" value="{$smarty.request.comment_page}" />
+ <label for="comments-style">{tr}Threaded: {/tr} </label>
+ <input type="checkbox" name="comments_style" id="comments-style" value="threaded" {if $comments_style eq "threaded"}checked="checked"{/if} onchange="this.parentNode.submit()"/> <label for="comments-maxcomm">{tr}Messages: {/tr} </label>
+ <select name="comments_maxComments" id="comments-maxcomm" onchange="this.parentNode.submit()">
+ <option value="5" {if $maxComments eq 5}selected="selected"{/if}>5</option>
+ <option value="10" {if $maxComments eq 10}selected="selected"{/if}>10</option>
+ <option value="20" {if $maxComments eq 20}selected="selected"{/if}>20</option>
+ <option value="50" {if $maxComments eq 50}selected="selected"{/if}>50</option>
+ <option value="100" {if $maxComments eq 100}selected="selected"{/if}>100</option>
+ <option value="999999" {if $maxComments eq 999999}selected="selected"{/if}>All</option>
+ </select> <input type="submit" name="comments_setOptions" value="set" id="set_btn"/>
+ <script>document.getElementById('set_btn').parentNode.removeChild(document.getElementById('set_btn'));</script>
+ </form>
{formfeedback hash=$formfeedback}
<table class="mb-table">
{foreach item=comment from=$comments}
@@ -44,12 +57,12 @@
<tr><td colspan="10">&nbsp;</td></tr>
{/if}
</table>
- {if !$topic_locked}<p style="text-align: right;"><a title="{tr}Post on this thread{/tr}" href="{$comments_return_url}&post_comment_reply_id={$thread->mInfo.flc_content_id}&post_comment_request=1#editcomments">{tr}Post on this thread{/tr} {biticon ipackage=bitboard iname="mail_new" iexplain="Post on this thread"}</a></p>{/if}
+ {if !$topic_locked}<p style="text-align: right;"><a title="{tr}Post Reply{/tr}" href="{$comments_return_url}&post_comment_reply_id={$thread->mInfo.flc_content_id}&post_comment_request=1#editcomments">{tr}Post Reply{/tr} {biticon ipackage=bitboard iname="mail_new" iexplain="Post Reply"}</a></p>{/if}
{libertypagination ihash=$commentsPgnHash}
</div><!-- end .body -->
</div><!-- end .admin -->
- {if $gBitSystem->isFeatureActive('bitboards_post_anon_moderation') && $smarty.request.post_comment_request && !$gBitUser->isRegistered()}
+ {if $gBitSystem->isFeatureActive('bitboards_post_anon_moderation') && ($smarty.request.post_comment_request || !empty($smarty.request.post_comment_submit)) && !$gBitUser->isRegistered()}
{formfeedback warning="Your post will not be shown immediately it will have to be approved by a moderator"}
{/if}
{include file="bitpackage:liberty/comments_post_inc.tpl" post_title="Post" hide=1 preview_override=1}
diff --git a/templates/topic.tpl b/templates/topic.tpl
index 4ee7367..41ad8fe 100644
--- a/templates/topic.tpl
+++ b/templates/topic.tpl
@@ -1,4 +1,4 @@
-{* $Header: /cvsroot/bitweaver/_bit_boards/templates/Attic/topic.tpl,v 1.7 2006/07/27 23:00:41 hash9 Exp $ *}
+{* $Header: /cvsroot/bitweaver/_bit_boards/templates/Attic/topic.tpl,v 1.8 2006/07/29 15:10:00 hash9 Exp $ *}
{strip}
<div class="listing bitboard">
<div class="floaticon">
@@ -23,8 +23,8 @@
</div>
<div class="body">
- <p style="text-align: right; margin: 0px; padding: 0px;"><a title="{tr}Start a new thread{/tr}" href="{$comments_return_url}&amp;post_comment_request=1#editcomments">{tr}Start a new topic{/tr} {biticon ipackage=bitboard iname="mail_new" iexplain="Start a new topic"}</a></p>
- {minifind sort_mode=$sort_mode board_id=$smarty.request.board_id}
+ <p style="text-align: right; margin: 0px; padding: 0px;"><a title="{tr}New Topic{/tr}" href="{$comments_return_url}&amp;post_comment_request=1#editcomments">{tr}New Topic{/tr} {biticon ipackage=bitboard iname="mail_new" iexplain="New Topic"}</a></p>
+ {minifind sort_mode=$sort_mode b=$smarty.request.b}
{form id="checkform"}
<input type="hidden" name="board_id" value="{$smarty.request.board_id}" />
<input type="hidden" name="offset" value="{$control.offset|escape}" />
@@ -54,26 +54,17 @@
{/if}
{if $thread.th_sticky==1} mb-sticky{/if}">
{if $thread.th_moved>0}
- <td class="actionicon" width="1" colspan="{$thread.flip|@count}">{* thread status icons *}
- {biticon ipackage=bitboard iname="move" iexplain="Moved Thread"}
+ <td class="actionicon" width="1" colspan="{$thread.flip|@count}">{* topic status icons *}
+ {biticon ipackage=bitboard iname="move" iexplain="Moved Topic"}
</td>
{else}
{assign var=flip value=$thread.flip}
{foreach from=$flip item=flip_s key=flip_name}
- <td class="actionicon" width="1">{* thread status icons *}
+ <td class="actionicon" width="1">{* topic status icons *}
{include file="bitpackage:bitboards/flipswitch.tpl"}
</td>
{/foreach}
{/if}
- {if $gBitSystem->isFeatureActive('bitboards_thread_verbrose')}
- <td>
- <a href="{$thread.url}" title="{$thread.title|escape}">{$thread.title|escape}</a>, started by {if $thread.flc_user_id < 0}{$thread.anon_name|escape}{else}{displayname user_id=$thread.flc_user_id}{/if} {$thread.flc_created|reltime|escape}{if $thread.post_count > 1}, with {$thread.post_count|escape} posts,
- last update by {if $thread.llc_user_id < 0}{$thread.l_anon_name|escape}{else}{displayname user_id=$thread.llc_user_id}{/if} {$thread.llc_last_modified|reltime|escape}{/if}
- </td>
- {if $gBitUser->hasPermission('p_bitboards_edit') || $gBitUser->hasPermission('p_bitboards_post_edit')}
- <td style="text-align:right;">{if $thread.unreg > 0}<a style="color: blue;" href="{$thread.url}" title="{$thread.title}">{$thread.unreg}&nbsp;Unregistered&nbsp;Posts</a>{/if}</td>
- {/if}
- {else}
<td style="white-space: nowrap;"><a href="{$thread.url}" title="{$thread.title|escape}">{$thread.title|escape}</a></td>
<td style="text-align: center;">{if $thread.flc_user_id < 0}{$thread.anon_name|escape}{else}{displayname user_id=$thread.flc_user_id}{/if}</td>
<td>{$thread.flc_created|reltime:short|escape}</td>
@@ -83,7 +74,6 @@
{/if}
<td style="text-align: center;">{if $thread.post_count > 1}{if $thread.llc_user_id < 0}{$thread.l_anon_name|escape}{else}{displayname user_id=$thread.llc_user_id}{/if}{else}{/if}</td>
<td style="text-align: right;">{if $thread.post_count > 1}{$thread.llc_last_modified|reltime:short|escape}{else}{/if}</td>
- {/if}
{if $gBitUser->hasPermission('p_bitboards_edit') || $gBitUser->hasPermission('p_bitboards_post_edit')}
<td class="actionicon">
{if $thread.flc_user_id<0 && $thread.first_approved==0}
@@ -145,7 +135,7 @@
{/foreach}
</table>
- <p style="text-align: right;"><a title="{tr}Start a new thread{/tr}" href="{$comments_return_url}&amp;post_comment_request=1#editcomments">{tr}Start a new topic{/tr} {biticon ipackage=bitboard iname="mail_new" iexplain="Start a new topic"}</a></p>
+ <p style="text-align: right;"><a title="{tr}New Topic{/tr}" href="{$comments_return_url}&amp;post_comment_request=1#editcomments">{tr}New Topic{/tr} {biticon ipackage=bitboard iname="mail_new" iexplain="New Topic"}</a></p>
{if $gBitUser->hasPermission( 'p_bitboards_remove' )}
<div style="text-align:right;">
<script type="text/javascript">/* <![CDATA[ check / uncheck all */
diff --git a/templates/topic_move.tpl b/templates/topic_move.tpl
index 9f62dfc..b040c0c 100644
--- a/templates/topic_move.tpl
+++ b/templates/topic_move.tpl
@@ -1,10 +1,10 @@
-{* $Header: /cvsroot/bitweaver/_bit_boards/templates/topic_move.tpl,v 1.3 2006/07/21 23:58:45 hash9 Exp $ *}
+{* $Header: /cvsroot/bitweaver/_bit_boards/templates/topic_move.tpl,v 1.4 2006/07/29 15:10:00 hash9 Exp $ *}
{strip}
<div class="floaticon">{bithelp}</div>
<div class="admin bitboard">
<div class="header">
- <h1>{tr}Move Thread{/tr}: {$gContent->mInfo.title|escape}</h1>
+ <h1>{tr}Move Topic{/tr}: {$gContent->mInfo.title|escape}</h1>
</div>
<div class="body">
@@ -25,7 +25,7 @@
{/forminput}
</div>
<div class="row submit">
- <input type="submit" name="move_thread" value="{tr}Move Thread{/tr}" />
+ <input type="submit" name="move_thread" value="{tr}Move Topic{/tr}" />
</div>
{/form}
</div><!-- end .body -->