Make WordPress Core


Ignore:
Timestamp:
02/02/2008 07:22:14 PM (17 years ago)
Author:
ryan
Message:

Don't hard code post type in edit forms. Props filosofo and DD32. fixes #4991

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-admin/edit-form-advanced.php

    r6633 r6712  
    4747$saveasdraft = '<input name="save" type="submit" id="save" tabindex="3" value="' . attribute_escape( __('Save and Continue Editing') ) . '" />';
    4848
    49 if (empty($post->post_status)) $post->post_status = 'draft';
    50 
    5149?>
    5250
     
    5553<input type="hidden" id="originalaction" name="originalaction" value="<?php echo $form_action ?>" />
    5654<input type="hidden" name="post_author" value="<?php echo attribute_escape( $post->post_author ); ?>" />
    57 <input type="hidden" id="post_type" name="post_type" value="post" />
     55<input type="hidden" id="post_type" name="post_type" value="<?php echo $post->post_type ?>" />
    5856
    5957<?php echo $form_extra ?>
Note: See TracChangeset for help on using the changeset viewer.