summaryrefslogtreecommitdiffstats
path: root/wp-admin/options-writing.php
diff options
context:
space:
mode:
authordonncha <donncha@7be80a69-a1ef-0310-a953-fb0f7c49ff36>2007-10-12 16:21:15 +0000
committerdonncha <donncha@7be80a69-a1ef-0310-a953-fb0f7c49ff36>2007-10-12 16:21:15 +0000
commit3a4570b0fc8b3d6339bef71d17d7701554e0bbf7 (patch)
tree2a06e5261263c68d8afd95a6328879dc289cb909 /wp-admin/options-writing.php
parentb83c34a7010faee0223f6037025c350da12e05e6 (diff)
downloadwordpress-mu-3a4570b0fc8b3d6339bef71d17d7701554e0bbf7.tar.gz
wordpress-mu-3a4570b0fc8b3d6339bef71d17d7701554e0bbf7.tar.xz
wordpress-mu-3a4570b0fc8b3d6339bef71d17d7701554e0bbf7.zip
Merge with WP 2.3 - testing use only!
Move pluggable functions out of wpmu-functions and into pluggable.php, fixes #439 git-svn-id: http://svn.automattic.com/wordpress-mu/trunk@1069 7be80a69-a1ef-0310-a953-fb0f7c49ff36
Diffstat (limited to 'wp-admin/options-writing.php')
-rw-r--r--wp-admin/options-writing.php36
1 files changed, 18 insertions, 18 deletions
diff --git a/wp-admin/options-writing.php b/wp-admin/options-writing.php
index 1f70b74..6c0db1e 100644
--- a/wp-admin/options-writing.php
+++ b/wp-admin/options-writing.php
@@ -7,17 +7,17 @@ $parent_file = 'options-general.php';
include('admin-header.php');
?>
-<div class="wrap">
-<h2><?php _e('Writing Options') ?></h2>
-<form method="post" action="options.php">
+<div class="wrap">
+<h2><?php _e('Writing Options') ?></h2>
+<form method="post" action="options.php">
<?php wp_nonce_field('update-options') ?>
<p class="submit"><input type="submit" name="Submit" value="<?php _e('Update Options &raquo;') ?>" /></p>
-<table width="100%" cellspacing="2" cellpadding="5" class="optiontable editform">
-<tr valign="top">
-<th width="33%" scope="row"> <?php _e('Size of the post box:') ?></th>
-<td><input name="default_post_edit_rows" type="text" id="default_post_edit_rows" value="<?php form_option('default_post_edit_rows'); ?>" size="2" style="width: 1.5em; " />
-<?php _e('lines') ?></td>
-</tr>
+<table width="100%" cellspacing="2" cellpadding="5" class="optiontable editform">
+<tr valign="top">
+<th width="33%" scope="row"> <?php _e('Size of the post box:') ?></th>
+<td><input name="default_post_edit_rows" type="text" id="default_post_edit_rows" value="<?php form_option('default_post_edit_rows'); ?>" size="2" style="width: 1.5em; " />
+<?php _e('lines') ?></td>
+</tr>
<tr valign="top">
<th scope="row"><?php _e('Formatting:') ?></th>
<td>
@@ -31,11 +31,12 @@ include('admin-header.php');
<th scope="row"><?php _e('Default post category:') ?></th>
<td><select name="default_category" id="default_category">
<?php
-$categories = $wpdb->get_results("SELECT * FROM $wpdb->categories ORDER BY cat_name");
+$categories = get_categories('get=all');
foreach ($categories as $category) :
-if ($category->cat_ID == get_option('default_category')) $selected = " selected='selected'";
+$category = sanitize_category($category);
+if ($category->term_id == get_option('default_category')) $selected = " selected='selected'";
else $selected = '';
-echo "\n\t<option value='$category->cat_ID' $selected>$category->cat_name</option>";
+echo "\n\t<option value='$category->term_id' $selected>$category->name</option>";
endforeach;
?>
</select></td>
@@ -44,18 +45,17 @@ endforeach;
<th scope="row"><?php _e('Default link category:') ?></th>
<td><select name="default_link_category" id="default_link_category">
<?php
-foreach ($categories as $category) :
-if ($category->cat_ID == get_option('default_link_category')) $selected = " selected='selected'";
+$link_categories = get_terms('link_category', 'get=all');
+foreach ($link_categories as $category) :
+$category = sanitize_term($category, 'link_category');
+if ($category->term_id == get_option('default_link_category')) $selected = " selected='selected'";
else $selected = '';
-echo "\n\t<option value='$category->cat_ID' $selected>$category->cat_name</option>";
+echo "\n\t<option value='$category->term_id' $selected>$category->name</option>";
endforeach;
?>
</select></td>
</tr>
</table>
-
-
-
<p class="submit">
<input type="hidden" name="action" value="update" />
<input type="hidden" name="page_options" value="default_post_edit_rows,use_smilies,default_category,default_email_category,use_balanceTags,default_link_category" />