Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <!-- language: lang-php -->
- <?php
- <form id="question-form" method="post" enctype="multipart/form-data" action="<?php echo qa_get_url( 'archive' ); ?>">
- <?php wp_nonce_field( 'qa_edit' ); ?>
- <input type="hidden" name="qa_action" value="edit_question" />
- <input type="hidden" name="question_id" value="<?php echo esc_attr( $question->ID ); ?>" />
- <table>
- <tr>
- <td id="question-title-label">
- <label for="question-title"><?php _e('Title:', QA_TEXTDOMAIN); ?></label>
- </td>
- <td id="question-title-td">
- <input type="text" id="question-title" name="question_title" value="<?php echo esc_attr( $question->post_title ); ?>" />
- </td>
- </tr>
- </table>
- <textarea name="question_content"><?php echo esc_textarea( $question->post_content ); ?></textarea>
- <!-- My custom fields ends here -->
- <table id="question-taxonomies">
- <tr>
- <td id="question-category-td">
- <?php wp_dropdown_categories( array(
- 'taxonomy' => 'question_category',
- 'selected' => $question->cat,
- 'hide_empty' => false,
- 'hierarchical' => true,
- 'name' => 'question_cat',
- 'class' => '',
- 'show_option_none' => __( 'Select category...', QA_TEXTDOMAIN )
- ) ); ?>
- </td>
- <td id="question-tags-label">
- <label for="question-tags"><?php _e('Tags:', QA_TEXTDOMAIN); ?></label>
- </td>
- <td id="question-tags-td">
- <input type="text" id="question-tags" name="question_tags" value="<?php echo implode( ', ', $question->tags ); ?>" />
- </td>
- </tr>
- </table>
- <?php the_qa_submit_button(); ?>
- </form>
- <?php
- }
- ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement