Show image in edit form
-
Thought it would be nice to show the image in the admin edit form. Just add the line with the <img /> tag into the function:
// add image field in edit form function z_edit_texonomy_field($taxonomy) { wp_enqueue_style('thickbox'); wp_enqueue_script('thickbox'); echo '<tr class="form-field"> <th scope="row" valign="top"><label for="taxonomy_image">Image</label></th> <td> <img src="'.get_option('z_taxonomy_image'.$taxonomy->term_id).'" /><br /> <input type="text" name="taxonomy_image" id="taxonomy_image" value="'.get_option('z_taxonomy_image'.$taxonomy->term_id).'" /><br /></td> </tr>'.z_script(); }
The topic ‘Show image in edit form’ is closed to new replies.