summaryrefslogtreecommitdiff
path: root/templates
diff options
context:
space:
mode:
Diffstat (limited to 'templates')
-rw-r--r--templates/blog_post.tpl3
-rw-r--r--templates/center_list_blog_posts.php33
-rw-r--r--templates/view_blog_post.tpl2
3 files changed, 25 insertions, 13 deletions
diff --git a/templates/blog_post.tpl b/templates/blog_post.tpl
index dcdfbe4..c46a13d 100644
--- a/templates/blog_post.tpl
+++ b/templates/blog_post.tpl
@@ -1,4 +1,4 @@
-{* $Header: /cvsroot/bitweaver/_bit_blogs/templates/blog_post.tpl,v 1.9 2005/12/18 22:27:35 squareing Exp $ *}
+{* $Header: /cvsroot/bitweaver/_bit_blogs/templates/blog_post.tpl,v 1.10 2006/01/10 21:11:26 squareing Exp $ *}
{strip}
<div class="edit blogs">
<div class="header">
@@ -41,6 +41,7 @@
{formlabel label="Title" for="title"}
{forminput}
<input type="text" size="50" name="title" id="title" value="{$title|escape}" />
+ {formhelp note="When you leave the title blank, the current date will be substituted automagically."}
{/forminput}
</div>
{/if}
diff --git a/templates/center_list_blog_posts.php b/templates/center_list_blog_posts.php
index 1dbc495..7752736 100644
--- a/templates/center_list_blog_posts.php
+++ b/templates/center_list_blog_posts.php
@@ -4,23 +4,23 @@ global $gBitSmarty, $gBlog, $gBitSystem, $categlib, $_REQUEST, $maxRecords, $gQu
$postRecords = ( $module_rows ? $module_rows : $maxRecords );
if (defined("CATEGORIES_PKG_PATH")) {
- include_once( CATEGORIES_PKG_PATH.'categ_lib.php');
+ include_once( CATEGORIES_PKG_PATH.'categ_lib.php');
}
include_once( BLOGS_PKG_PATH.'BitBlog.php' );
require_once( USERS_PKG_PATH.'BitUser.php' );
if ($gBitSystem->isPackageActive( 'vvcat' )) {
- if (isset($_REQUEST['addcateg']) and $_REQUEST['addcateg'] and isset($_REQUEST['post_id']) and $_REQUEST['post_id']) {
- $categlib->categorize_blog_post($_REQUEST['post_id'],$_REQUEST['addcateg'],true);
- } elseif (isset($_REQUEST['delcategs']) and isset($_REQUEST['post_id']) and $_REQUEST['post_id']) {
- $categlib->uncategorize('blogpost',$_REQUEST['post_id']);
- }
- $categs = $categlib->list_all_categories(0, -1, 'name_asc', '', '', 0);
+ if (isset($_REQUEST['addcateg']) and $_REQUEST['addcateg'] and isset($_REQUEST['post_id']) and $_REQUEST['post_id']) {
+ $categlib->categorize_blog_post($_REQUEST['post_id'],$_REQUEST['addcateg'],true);
+ } elseif (isset($_REQUEST['delcategs']) and isset($_REQUEST['post_id']) and $_REQUEST['post_id']) {
+ $categlib->uncategorize('blogpost',$_REQUEST['post_id']);
+ }
+ $categs = $categlib->list_all_categories(0, -1, 'name_asc', '', '', 0);
- $gBitSmarty->assign('categs',$categs['data']);
- $gBitSmarty->assign('page','view.php');
- $choosecateg = str_replace('"',"'",$gBitSmarty->fetch('bitpackage:blogs/popup_categs.tpl'));
- $gBitSmarty->assign('choosecateg',$choosecateg);
+ $gBitSmarty->assign('categs',$categs['data']);
+ $gBitSmarty->assign('page','view.php');
+ $choosecateg = str_replace('"',"'",$gBitSmarty->fetch('bitpackage:blogs/popup_categs.tpl'));
+ $gBitSmarty->assign('choosecateg',$choosecateg);
}
if ( empty( $_REQUEST["sort_mode"] ) ) {
@@ -61,6 +61,17 @@ $listHash['parse_data'] = TRUE;
$listHash['load_comments'] = TRUE;
$listHash['page'] = (!empty($_REQUEST['page']) ? $_REQUEST['page'] : 1);
$listHash['offset'] = (!empty($_REQUEST['offset']) ? $_REQUEST['offset'] : 0);
+
+if( @BitBase::verifyId( $module_params['blog_id'] ) ) {
+ $listHash['blog_id'] = $module_params['blog_id'];
+}
+if( @BitBase::verifyId( $module_params['user_id'] ) ) {
+ $listHash['user_id'] = $module_params['user_id'];
+}
+if ( !empty( $module_params['sort_mode'] ) ) {
+ $listHash['sort_mode'] = $module_params['sort_mode'];
+}
+
// Get a list of last changes to the Wiki database
if ($gQueryUserId) {
$listHash['user_id'] = $gQueryUserId;
diff --git a/templates/view_blog_post.tpl b/templates/view_blog_post.tpl
index e0723ad..f95452b 100644
--- a/templates/view_blog_post.tpl
+++ b/templates/view_blog_post.tpl
@@ -30,7 +30,7 @@
<div class="header">
<h1>
- {if $post_info.use_title eq 'y' && $post_info.title}
+ {if $post_info.use_title eq 'y'}
{$post_info.title}
{else}
{$post_info.created|bit_long_date}