-
AuthorPosts
-
April 13, 2016 at 4:45 pm #612918
Hello,
Great work guys on this plugin. I have an issue i need help on. I put a WordPress audio shortcode inside an ajax portfolio item (portfolio item called ‘MP3 Test’ on the page in the private content ). When the item is clicked and the contents display via ajax, I see the audio come up. When i click play the audio starts playing which is good.
The problem comes from closing the ajax display, the audio keeps playing, even when i use the arrow to navigate to the next portfolio item the music keeps playing. I believe the audio should stop/pause when i close the ajax view or use arrow to navigate to the next item or click another portfolio item.
How can I get this fixed.
April 15, 2016 at 8:06 am #614611Hi adotopanuga!
Thank you for using Enfold.
Please add this in the functions.php file:
// new script add_action('wp_footer', 'ava_new_custom_script'); function ava_new_custom_script(){ ?> <script type="text/javascript"> (function($) { var audio = $("audio")[0]; $('.ajax_controlls a').bind('click', function(e) { audio.pause(); audio.currentTime = 0; }); })(jQuery); </script> <?php }
Remove browser cache or hard refresh the page before testing it.
Regards,
IsmaelApril 23, 2016 at 12:14 pm #620492Hi Ismael.
Thanks for your response. However the code doesn’t seem to work. I have put the code in child theme’s function.php file. You could check it in the link in the private content area.
April 25, 2016 at 4:50 am #620954Hi,
Please send us a temporary admin login so that we can have a closer look. You can post the details in the Private Content section of your reply.
Best regards,
RikardApril 25, 2016 at 10:48 am #621139Hi Rikard,
Thanks for your quick response. Please see private content.
April 25, 2016 at 11:18 am #621159April 25, 2016 at 11:25 am #621166Hi Ismael,
Thanks for this. One more thing.
1. I noticed the player stops when i click the close button or the 2 navigation arrow buttons beside the close button which is good. However, if the portfolio ajax is opened and audio is playing and then i click another portfolio thumbnail from beneath to see another ajax view, the audio doesn’t stop. Could you help fix such that clicking another portfolio thumbnail also stops the audio from playing.
2. Also what adjustment/code was used so i can replicate this elsewhere on the main project im working on. Thanks.
Many thanks and great work on the theme.
- This reply was modified 8 years, 8 months ago by adotopanuga. Reason: more inquiries
April 25, 2016 at 4:41 pm #621466Hello,
Still waiting for a response on this. Please treat as urgent. Thank you.
April 26, 2016 at 5:07 am #621869Hi!
Please replace the code with:
// new script add_action('wp_footer', 'ava_new_custom_script'); function ava_new_custom_script(){ ?> <script type="text/javascript"> (function($) { $('body').on('click', '.grid-entry, .ajax_controlls a', function(e) { var audio = $(".wp-audio-shortcode")[0]; if(!audio.paused) { audio.pause(); audio.currentTime = 0; } }); })(jQuery); </script> <?php }
Best regards,
IsmaelApril 26, 2016 at 11:58 am #622055Hi Ismael,
Sorry for all the stress and thank for your patience so far, This is where (check private content area) am trying to replicate the work. I can’t seem to achieve it. I have used the code in the shild theme functions file but no show. If you look at the page you’ll see that i want each ajax portfolio content to be different songs. Its not working that when i play it and i click any of the control or the ajax thumbnails the music stop. In fact from my observation the music keeps playing and when i click paly in another item that one continues playing over the previous one.
Please any help will be much appreciated.
April 27, 2016 at 8:21 am #622830Hi!
Looks like you didn’t replace the code in the functions.php file. Please replace it with the following: https://kriesi.at/support/topic/wordpres-audio-keeps-playing-after-closing-ajax-portfolio-item/#post-621869
Regards,
IsmaelApril 27, 2016 at 9:33 am #622870Hi Ismael,
I did it did not work. That why I provided you the login info.
Lease help look at this as this is really urgent and delaying the launch of the project. I have put the code in. Still has all those issues I mentioned in my previous reply.I noticed it takes like 24hrs to get another reply from you. I’m hoping you can help fix this sooner coz I’m out of time on this project. Thanks.
April 27, 2016 at 11:53 am #622951Hi!
We modified the code in the functions.php file. It’s working now. Please remove browser cache or hard refresh the page.
It usually takes within 24 hours before we can reply back so if you’re in a hurry, please contact codeable: http://kriesi.at/contact/customization
Best regards,
IsmaelApril 27, 2016 at 5:04 pm #623238Thanks Ismael. Much appreciated.
It’s working now but just 2 more things.
1. It doesn’t stop on click of the close button (located at the top-right of the ajax portfolio item content).
2. In a particular item(see private content) on page 1, i’m experience audio overlapping issue (first song doesn’t stop playing when another play button is clicked) when i use multiple audio shortcodes.Could you help fix this..
Your support has been great and patient very very helpful. Thank you in advance.
- This reply was modified 8 years, 8 months ago by adotopanuga.
April 28, 2016 at 6:57 am #623486Hi!
1.) I’m not sure why it’s not working for the close button. Please give us more time to inspect the issue.
2.) Users will have to pause the other player manually if there are multiple audio shortcode.
Regards,
IsmaelApril 28, 2016 at 1:39 pm #623695Okay. I’ll be expecting your response thanks.
May 2, 2016 at 8:48 am #625539 -
AuthorPosts
- You must be logged in to reply to this topic.