Skip to content

Commit 2c78a3e

Browse files
authored
Merge pull request #3 from denverprophitjr/Featured_Image
Featured image fixes issue #3 & #2
2 parents a6a9e15 + 969da75 commit 2c78a3e

File tree

2 files changed

+22
-10
lines changed

2 files changed

+22
-10
lines changed

inc/Posts/Base.php

Lines changed: 15 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -369,15 +369,21 @@ public function set_labels() {
369369
'name' => $names['plural'],
370370
'singular_name' => $names['singular'],
371371
'add_new' => _x( 'Add New', 'dwqa', 'dwqa' ) . ' ' . $names['singular'],
372-
'add_new_item' => __( 'Add New', 'dwqa' ) . ' ' . $names['singular'],
373-
'edit_item' => __( 'Edit', 'dwqa' ) . ' ' . $names['singular'],
374-
'new_item' => __( 'New', 'dwqa' ) . ' ' . $names['singular'],
375-
'view_item' => __( 'View', 'dwqa' ) . ' ' . $names['singular'],
376-
'search_items' => __( 'Search ', 'dwqa' ) . $names['plural'],
377-
'not_found' => $names['plural'] . ' ' . __( 'not found', 'dwqa' ),
378-
'not_found_in_trash' => $names['plural'] . ' ' . __( 'not found in Trash', 'dwqa' ),
379-
'parent_item_colon' => __( 'Parent:', 'dwqa' ) . ' ' . $names['singular'],
380-
'menu_name' => isset( $names['menu'] ) ? $names['menu'] : $names['plural'],
372+
'add_new_item' => __( 'Add New', 'dwqa' ) . ' ' . $names['singular'],
373+
'edit_item' => __( 'Edit', 'dwqa' ) . ' ' . $names['singular'],
374+
'new_item' => __( 'New', 'dwqa' ) . ' ' . $names['singular'],
375+
'view_item' => __( 'View', 'dwqa' ) . ' ' . $names['singular'],
376+
'search_items' => __( 'Search ', 'dwqa' ) . $names['plural'],
377+
'not_found' => $names['plural'] . ' ' . __( 'not found', 'dwqa' ),
378+
'not_found_in_trash' => $names['plural'] . ' ' . __( 'not found in Trash', 'dwqa' ),
379+
'featured_image' => __( 'Featured Image', 'dwqa' ) . $names['singular'],
380+
'set_featured_image' => __( 'Set featured image', 'dwqa' ) . $names['singular'],
381+
'remove_featured_image' => __( 'Remove featured image', 'dwqa' ) . $names['singular'],
382+
'set_featured_image' => __( 'Set featured image', 'dwqa' ) . $names['singular'],
383+
'insert_into_item' => __( 'Insert into item', 'dwqa' ) . $names['singular'],
384+
'uploaded_to_this_item' => __( 'Uploaded to this item', 'dwqa' ) . $names['singular'],
385+
'parent_item_colon' => __( 'Parent:', 'dwqa' ) . ' ' . $names['singular'],
386+
'menu_name' => isset( $names['menu'] ) ? $names['menu'] : $names['plural'],
381387
);
382388
}
383389

inc/Posts/Question.php

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -139,7 +139,7 @@ public function init() {
139139
}
140140

141141
public function set_supports() {
142-
return array( 'title', 'editor', 'comments', 'author', 'page-attributes' );
142+
return array( 'title', 'editor', 'comments', 'author', 'thumbnail', 'page-attributes' );
143143
}
144144

145145
public function set_rewrite() {
@@ -243,6 +243,12 @@ public function register_taxonomy() {
243243
'choose_from_most_used' => __( 'Choose from the most used question tags', 'dwqa' ),
244244
'not_found' => __( 'No question tags found.', 'dwqa' ),
245245
'menu_name' => __( 'Question Tags', 'dwqa' ),
246+
'featured_image' => __( 'Featured Image', 'dwqa' ) . $names['singular'],
247+
'set_featured_image' => __( 'Set featured image', 'dwqa' ) . $names['singular'],
248+
'remove_featured_image' => __( 'Remove featured image', 'dwqa' ) . $names['singular'],
249+
'set_featured_image' => __( 'Set featured image', 'dwqa' ) . $names['singular'],
250+
'insert_into_item' => __( 'Insert into item', 'dwqa' ) . $names['singular'],
251+
'uploaded_to_this_item' => __( 'Uploaded to this item', 'dwqa' ) . $names['singular'],
246252
);
247253

248254
$args = array(

0 commit comments

Comments
 (0)