Audio - toggle on/off multiple sounds even when they are not currently playing

I am wondering if there is a way to stop toggle all sounds even if they are not playing.
What I mean by that is I have several sound files that play one at a time when a slide comes in. I can toggle on/of the current sound but what if I want to toggle all sounds on/off in the compostion even if they are not playing so that when I go to next slide it will be on or off depending what was chosen on the previous slide?
One of the problem would be that I do not want all sounds to be turned back on at the same time but only the current one but I still want to be able to turn off all the sounds if the user decides he does not want to hear sound while at the same time I want the sounds to load automatically on each slide if he has decided to have sound.
Hope this makes sense.

didn't have the time to test this code yet.
but it should work.
Html5 audio can not be accessed by class, it can only be accessed by id.
so i made this code
$( "audio" ).each(function() {
var a = $(this).attr("id");
var audioPlayer = document.getElementById(a)
    audioPlayer.pause();
    audioPlayer.currentTime = 0;
this will find the id of the audios and pause them and reset the time to 0
( not really a way to officially stop audio )
or you van just mute it with this code
$( "audio" ).each(function() {
var a = $(this).attr("id");
var audioPlayer = document.getElementById(a)
    audioPlayer.muted = true;
- Rob

Similar Messages

  • My Macbook is not playing sound unless i have headphones in. The light in the headphone plug stays on even when they are not plugged in. How can i fix this?

    My Macbook is not playing sound unless i have headphones in. The light in the headphone port stays on even when they are not plugged in. How can i fix this?

    You might need to clean the headphone port (I was in the same situation and this worked for me).  Dirt, dust, and debris accumulate in the port and eventually the computer registers the debris as headphones being plugged in.  After cleaning the issue was resolved.

  • Images showing offline when they are not - sequence plays fine

    I'm using FCE 4.0 and when I open a project that I've been working on for weeks, some of the pictures in one of my directories are showing as offline.
    When I go into that bin and click on an offline photo, it shows me the thumbnail and I some of the other pictures which are offline are now visible and other previously visible pictures are now showing offline.
    I can play the entire sequence and everything is available and plays fine. I just can't see the photos to add them to my project.
    any thoughts?

    Maybe I am stupid but if you delete the imagefolder, it will be gone. You can set your default imagefolder: goto Media-> Camera-> Settings-> Use Memory-> Card. You can also backup your card to PC, reformat the card in your phone, because it makes default maps for images, video, audio,.........and then copy your images back to the specific folder.
    ‡Thank you for hitting the Blue/Green Star button‡
    N8-00 RM 596 V:111.030.0609; E71-1(05) RM 346 V: 500.21.009

  • Using 10.9.2 has anyone had problems with mail sounds not sounding even when they have been selected in mail preferences?, Using 10.9.2 has anyone had problems with mail sounds not sounding even when they have been selected in mail preferences?

    Using 10.9.2 has anyone had problems with mail sounds not sounding even when they have been selected in mail preferences?

    Your download or install of the update may have been corrupt. Visit the Mac App Store and re-download the update or visit http://support.apple.com/kb/DL1726 and download the 10.9.2 update combo and re-install.
    If that fails to solve the problem please post back and post a EtreCheck Report which you can locate at:
    http://www.etresoft.com/etrecheck

  • TS1630 My iPhone 4 says the headphones are in when they are not. I am not getting any sound from the speaker. Nothing appears to be in the headphone jack.  Any ideas anyone?

    My iPhone 4S  has no sound through the speaker generally, although the speakerphone does work.  It is indicating that headphones are in, when they are not.  Nothing appears to be in the headphone jack.  Resetting the phone has not resolved the problem.  any ideas what could be wrong?

    This just happened to my brand new iPhone5. I tried turning all the way off and then on AND plugging and unplugging. Only to discover that simply connecting to the charger worked!!!
    Very frustrating though!!

  • My iphone5 thinks that my headphones are plugged in even when they're not. How can I fix this?

    My iphone5 thinks that my headphones are plugged in even when they're not. How can I fix this?

    Try inserting and removing headphones in succession 6-7 times.
    If this does not work, take it to an Apple Store or Apple Authorized Service Provider and have them evaluate it.

  • Can we recharge iPhones several times a day even when they are in 50%

    Dear all,
    Can we recharge iPhones several times a day even when they are in 50%?
    Is it OK, if we leave iPhone plugged-in even when it is fully charged? I have heard that, we need to discharge battery completely at least once a month to improve the battery life. Is that right?
    Thanks

    Dear Farhad,
    there is definitely two schools of thought about this, the conventional one is use phone until almost dead then full charge, however recent articles in macworld that frequent charges do no more harm to these batteries. i think the best advice is to use your phone and then charge it when it needs charging. Most phone batteries ae fairly tired after a couple of years anyway, regardless of how to charge.
    bw
    Andrew

  • My contacts don't sync on icloud on my iphone some contacts disapear on iphone and some contacts hae been merged together to make one contact when they are not related. Can anyone help?

    My contacts don't sync on icloud on my iphone some contacts disapear on iphone and some contacts hae been merged together to make one contact when they are not related. Can anyone help?

    If you log into Icloud.com, are all your contacts correct there? If the answer is Yes, I would then turn contacts OFF on your phone, and then turn them back on. Do not merge, but replace with Icloud content.
    This is usually the quickest way to edit a bunch of contacts, through the web interface.

  • My ipod 5th gen won't change volume when headphones are plugged in, but when they are not I can change the volume on the speaker.  How do I fix this?

    My ipod 5th gen won't let me adjust volume when headphones are plugged in, but when they are not I can adjust the volume on the speaker.  How do I fix this?

    Try a hard reset of the Nano. To do this, press and hold both the Select (Center) and Menu buttons together long enough for the Apple logo to appear.
    I assume you have double checked to make sure you are plugging the headset all the way in meaning the white part of the headset is flush with the body of the Nano?
    B-rock

  • I have dragged 2 files to the trash bin but I cannot delete them from the trash bin. It keeps telling me these files are in use when they are not. How do I delete these files? One is a txt file and the other is an xls file

    I have dragged 2 files to the trash bin but I cannot delete them from the trash bin. It keeps telling me these files are in use when they are not. How do I delete these files? One is a txt file and the other is an xls file

    From the Finder menu select 'Secure Empty Trash'. If this or the suggestion above doesn't resolve the problem take a look at the various suggestions in this link:
    http://www.thexlab.com/faqs/trash.html

  • I recently had to get a new computer, my list of audible books is there but can't open because original file cannot be found.  how do I find them or redownload them when they are not in my purchased list anymore?

    I recently had to purchase a new computer, after doing so I no longer can open my audible books.  the list is there, but I get an error message telling me that the original file cannot be found.  How can I redownload them when they are not in my purchased list anymore when I go to the Apple Store??

    Downloading past purchases from the App Store, iBookstore, and iTunes Store - http://support.apple.com/kb/ht2519 - enabled with iTunes 10.3 and newer; not available in all countries; apps, books (not audiobooks), music, t.v. shows, and movies (some - not all studios have permitted this). Movies currently available in the USA only. Downloading previously purchased movies and TV shows requires iTunes 10.6 or later.  Discontinued items not available. For items not included in the iCloud list, or locations or computer systems where iCloud is not (yet?) available, you only get one download per fee paid.  Apple notes it is your responsibility to back up your purchases.
    Select the store on the left side of iTunes.
    Click on Purchased on the right side under Quick Links.
    You can re-download your available previous purchases.

  • WOT and Webutation is showing as disabled when they are not

    WOT and Webutation is showing as disabled when they are not .The icons show,but no color on icons. Says WOT is disabled when its not. Also the same on Webutation. Tried uninstalling then reinstalled both and the same thing happened. Tried Wot on another users account and theirs work. Can someone help me on these issues?

    capaho wrote:
    That's like saying a boat is an airplane because it's not a car.
    SMH
    In other words, how does your explanation account for ED (enhanced definition)?
    ED is generally considered to be 576p or 480p, but this is not universally accepted and these resolutions are often accepted as HD also. Additionally an ED signal uses non square pixels just as SD does so the horizontal pixel dimensions should be no more than 720. Exactly how the tv would treat these resolutions I don't know (yet).
    If you have a copy of the source code for the function that displays the HD icon, please post it so I can take a look at it.
    Why should I have such a copy and why is it relevant. The issue here is that the OP believes his video is incorrectly labelled HD which is not the case. There may or may not be anomalies in the way the tv attributes the HD label to some files (although it isn't the case for me), however the OP has incorrectly converted his source video and they are no longer SD, they are also not ED by whichever definition you wish to apply and any such anomalies should they exist are not responsible for the OP's files being labelled HD.

  • All my incoming calls are coming up as unknown, even though they are not blocked?

    All my incoming calls are coming up as unknown, even though they are not blocked? Any help much appreciated!

    We didnt    Still happens to some numbers!

  • My iphone thinks it has headphone plugged in when they are not

    My iphone thinks it has headphone plugged in when they are not. What to do?

    https://discussions.apple.com/thread/1343532?start=0&tstart=0
    i'ts a known hardware issue

  • HT204150 I have just set up icloud and all my contacts are duplicated from Address Book! My new iPhone is also showing duplicate contacts even though they are not duplicated in my address book on my computer. Please can you help

    I have just set up icloud and all my contacts are duplicated from Address Book! My new iPhone is also showing duplicate contacts even though they are not duplicated in my address book on my computer. Please can you help?

    Also, what are the source of your contacts? are they created on the phone, or you synced from yahoo/hotmail etc.
    If thats the case, the circular arrow wont be visible but instead show "groups"
    Contacts from different accounts are not synced to iCloud.

Maybe you are looking for