feat(submit): add user media library
This commit is contained in:
@@ -60,10 +60,12 @@ $featured_args = ['type' => '', 'data' => new stdClass(), 'options' => [
|
||||
if ($edit_post) {
|
||||
if (!empty($post_meta['featured_video'])) {
|
||||
$featured_args['type'] = 'video';
|
||||
$featured_args['data'] = [
|
||||
'url' => (string) $post_meta['featured_video'],
|
||||
'pic' => (string) ($post_meta['thumbnail_url'] ?? ''),
|
||||
];
|
||||
$featured_args['data'] = [
|
||||
'url' => (string) $post_meta['featured_video'],
|
||||
'pic' => (string) ($post_meta['thumbnail_url'] ?? ''),
|
||||
'id' => absint($post_meta['featured_video_attachment_id'] ?? 0),
|
||||
];
|
||||
|
||||
} elseif (!empty($post_meta['featured_slide'])) {
|
||||
$slides = array_filter(array_map('trim', explode(',', (string) $post_meta['featured_slide'])));
|
||||
$slide_data = [];
|
||||
|
||||
Reference in New Issue
Block a user