- require_once ('admin-header.php');
- $cat_ID = (int) $_GET['cat_ID'];
- $category = get_category_to_edit($cat_ID);
- ?>
-
-<div class="wrap">
- <h2><?php _e('Edit Category') ?></h2>
- <form name="editcat" action="categories.php" method="post">
- <?php wp_nonce_field('update-category_' . $category->cat_ID); ?>
- <table class="editform" width="100%" cellspacing="2" cellpadding="5">
- <tr>
- <th width="33%" scope="row"><?php _e('Category name:') ?></th>
- <td width="67%"><input name="cat_name" type="text" value="<?php echo attribute_escape($category->cat_name); ?>" size="40" /> <input type="hidden" name="action" value="editedcat" />
-<input type="hidden" name="cat_ID" value="<?php echo $category->cat_ID ?>" /></td>
- </tr>
- <tr>
- <th scope="row"><?php _e('Category slug:') ?></th>
- <td><input name="category_nicename" type="text" value="<?php echo attribute_escape($category->category_nicename); ?>" size="40" /></td>
- </tr>
- <tr>
- <th scope="row"><?php _e('Category parent:') ?></th>
- <td>
- <select name='category_parent'>
- <option value='0' <?php if (!$category->category_parent) echo " selected='selected'"; ?>><?php _e('None') ?></option>
- <?php wp_dropdown_cats($category->cat_ID, $category->category_parent); ?>
- </select></td>
- </tr>
- <tr>
- <th scope="row"><?php _e('Description:') ?></th>
- <td><textarea name="category_description" rows="5" cols="50" style="width: 97%;"><?php echo wp_specialchars($category->category_description); ?></textarea></td>
- </tr>
- </table>
- <p class="submit"><input type="submit" name="submit" value="<?php _e('Edit category') ?> »" /></p>
- </form>
- <p><a href="categories.php"><?php _e('« Return to category list'); ?></a></p>
-</div>
- <?php
+ require_once ('admin-header.php');
+ $cat_ID = (int) $_GET['cat_ID'];
+ $category = get_category_to_edit($cat_ID);
+ include('edit-category-form.php');