Update of /cvsroot/php-blog/serendipity/include
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv28988/include
Modified Files:
functions_entries.inc.php
Log Message:
Personal Configuration allows to configure defaults per-user for creating entries (publish state, moderate comments, allow comments)
Index: functions_entries.inc.php
===================================================================
RCS file: /cvsroot/php-blog/serendipity/include/functions_entries.inc.php,v
retrieving revision 1.51
retrieving revision 1.52
diff -u -d -r1.51 -r1.52
--- functions_entries.inc.php 26 Jan 2005 14:14:01 -0000 1.51
+++ functions_entries.inc.php 27 Jan 2005 15:02:00 -0000 1.52
@@ -1106,7 +1106,7 @@
serendipity_plugin_api::hook_event('backend_entryform', $entry);
- if (isset($entry['isdraft']) && $entry['isdraft'] == 'true') {
+ if (isset($entry['isdraft']) && $entry['isdraft'] == 'true' || $serendipity['publishDefault'] == 'draft') {
$draftD = ' selected="selected"';
} else {
$draftP = ' selected="selected"';
@@ -1124,7 +1124,7 @@
if (isset($entry['allow_comments']) && (serendipity_db_bool($entry['allow_comments']))) {
$allow_comments = ' checked="checked"';
- } elseif ((!isset($entry['allow_comments']) || $entry['allow_comments'] !== 'false') && ($serendipity['allowCommentsDefault'] == 'true' || $serendipity['allowCommentsDefault'] === true)) {
+ } elseif ((!isset($entry['allow_comments']) || $entry['allow_comments'] !== 'false') && (!isset($serendipity['allowCommentsDefault']) || $serendipity['allowCommentsDefault'] == 'true' || $serendipity['allowCommentsDefault'] === true)) {
// This is the default on creation of a new entry and depends on the "allowCommentsDefault" variable of the configuration.
$allow_comments = ' checked="checked"';
} else {
|