Now with default statuses. Drafts on edit page. Fixed bookmarklets, tested in IE and Moz. Slightly tweaked CSS.

git-svn-id: http://svn.automattic.com/wordpress/trunk@670 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
saxmatt 2003-12-31 22:21:50 +00:00
parent 17e7a2b393
commit efd65680bd
5 changed files with 33 additions and 8 deletions

View File

@ -71,10 +71,6 @@ window.onload = focusit;
<legend><a href="http://wordpress.org/docs/reference/post/#category" title="Help on categories">Categories</a></legend>
<div><?php dropdown_categories($default_post_cat); ?></div>
</fieldset>
<fieldset id="postpassworddiv">
<legend><a href="http://wordpress.org/docs/reference/post/#post_password" title="Help on post password">Post Password</a></legend>
<div><input name="post_password" type="text" size="18" tabindex="3" id="post_password" value="<?php echo $post_password ?>" /></div>
</fieldset>
<br />
<fieldset style="clear:both">

View File

@ -40,7 +40,29 @@ ob_start();
<li><a href="edit-comments.php">Latest Comments</a></li>
<li class="last"><a href="moderation.php">Comments Awaiting Moderation</a></li>
</ul>
<?php
get_currentuserinfo();
$drafts = $wpdb->get_results("SELECT ID, post_title FROM $tableposts WHERE post_status = 'draft' AND post_author = $user_ID");
if ($drafts) {
?>
<div class="wrap">
<p><strong>Your Drafts:</strong>
<?php
$i = 0;
foreach ($drafts as $draft) {
if (0 != $i)
echo ', ';
$draft->post_title = stripslashes($draft->post_title);
if ($draft->post_title == '')
$draft->post_title = 'Post #'.$draft->ID;
echo "<a href='post.php?action=edit&amp;post=$draft->ID' title='Edit this draft'>$draft->post_title</a>";
++$i;
}
?>.</p>
</div>
<?php
}
?>
<div class="wrap">
<table width="100%">
<tr>

View File

@ -54,7 +54,8 @@ for ($i=0; $i<count($wpvarstoreset); $i += 1) {
}
}
}
$link_url = stripslashes($HTTP_GET_VARS['linkurl']);
$link_name = htmlentities(stripslashes(urldecode($HTTP_GET_VARS['name'])));
require('admin-header.php');
?>
<ul id="adminmenu2">

View File

@ -58,9 +58,12 @@ switch($action) {
}
}
$post_status = $HTTP_POST_VARS['post_status'];
if (empty($post_status)) $post_status = get_settings('default_post_status');
$comment_status = $HTTP_POST_VARS['comment_status'];
if (empty($comment_status)) $comment_status = get_settings('default_comment_status');
$ping_status = $HTTP_POST_VARS['ping_status'];
$post_password = addslashes($HTTP_POST_VARS['post_password']);
if (empty($ping_status)) $ping_status = get_settings('default_ping_status');
$post_password = addslashes(stripslashes($HTTP_POST_VARS['post_password']));
$post_name = sanitize_title($post_title);
$trackback = $HTTP_POST_VARS['trackback_url'];
// Format trackbacks
@ -262,8 +265,11 @@ switch($action) {
}
$post_status = $HTTP_POST_VARS['post_status'];
$prev_status = $HTTP_POST_VARS['prev_status'];
$post_status = $HTTP_POST_VARS['post_status'];
$comment_status = $HTTP_POST_VARS['comment_status'];
if (empty($comment_status)) $post_status = get_settings('default_comment_status');
$ping_status = $HTTP_POST_VARS['ping_status'];
if (empty($ping_status)) $post_status = get_settings('default_ping_status');
$post_password = addslashes($HTTP_POST_VARS['post_password']);
$post_name = sanitize_title($post_title);
$trackback = $HTTP_POST_VARS['trackback_url'];

View File

@ -207,7 +207,7 @@ textarea, input, select {
#categorydiv {
line-height: 130%;
margin-right: 5px;
margin-right: 15px;
position: absolute;
right: 5%;
width: 9em;