-
AuthorPosts
-
February 22, 2019 at 12:48 pm #1070302
On your demos,
you show a player on top of the image, it shows up on “blog Grid view”, the blog post itself, and so on.
The way enfold detects audio doesn’t work with Gutenberg,
it only works if the audio is inserted using the “classic editor”, or inside a “classic” block in Gutenberg
Can this be updated/fixedAny chance we could also make it work with podcasts managed with plugins such as Seriously Simple Podcasting
Regards
February 25, 2019 at 1:03 pm #1071263I edited includes/helper-post-format.php with this (there might be a more elegant way to do it but it works)
if(!function_exists('avia_audio_content_filter')) { function avia_audio_content_filter($current_post) { preg_match("![\[<]audio[^>]+?[src|source|mp3]=[\"\'](.+?)[\"\'][\]>][\[<]\/audio[\]>]!", $current_post['content'], $match_audio); if(!empty($match_audio)) { $current_post['before_content'] = do_shortcode('[audio src="'.$match_audio[1].'"][/audio]'); $current_post['content'] = str_replace($match_audio[0], "", $current_post['content']); } return avia_default_title_filter($current_post); } }
How would I go about defining this is my child theme, without editing enfold’s theme files,
so that it would survive theme update.
Any chance this will be implemented/fixed in a future release of enfold ?February 25, 2019 at 5:42 pm #1071375trying to get it to work with Seriously Simple Podcasting, but no success
all my post with post-format “audio” now show a player, when only one of those posts actually has an audio podcast url in it’s meta field “audio_file”the code I used :
if(!function_exists('avia_audio_content_filter')) { function avia_audio_content_filter($current_post) { $match_audio = get_post_meta(get_the_ID(), 'audio_file', false); if (!empty($match_audio)) { $current_post['before_content'] = do_shortcode('[audio src="'.$match_audio[0].'"][/audio]'); $current_post['content'] = str_replace($match_audio[0], "", $current_post['content']); } return avia_default_title_filter($current_post); } }
February 25, 2019 at 6:52 pm #1071407Hi pharefm,
Enfold does not work with Gutenberg, you can use one or the other.
Best regards,
Victoria -
AuthorPosts
- You must be logged in to reply to this topic.