Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7746847
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 1, 20262026-06-01T10:23:04+00:00 2026-06-01T10:23:04+00:00

I have a webpage that plays a ‘chime’ sound when certain events occur. Problem

  • 0

I have a webpage that plays a ‘chime’ sound when certain events occur. Problem is, the audio playback is intermittent and I couldn’t seem to figure out what was causing it until I changed my code to this :

var audioElement = document.createElement('audio');
audioElement.setAttribute('src', '/public/sounds/chime.ogg');
audioElement.load();
audioElement.play();

Now the audio (only 11kb) plays every time but I want to know for performance evaluation, is the file pulled from the server every single time or is it cached and reused?

my old code used to be like this:

HTML:

<audio id="chime" preload="auto" autobuffer>
    <source src="@{'/public/sounds/chime.ogg'}" />
</audio>

JavaScript:

$('#chime').get(0).play();
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-01T10:23:06+00:00Added an answer on June 1, 2026 at 10:23 am

    EDIT: If all you want to do is see if the browser is requesting the file or honoring the cache info, pop open the dev tools network panel (or the firebug net panel) and reload the page.

    you will see a GET for the file resource being loaded, along with a status (look at the headers tab in the chrome tools – you’ll like see one of ‘200 OK’, ‘200 (from cache)’ or ‘304 not modified’.

    Take a look at the timings tab and you’ll see if it’s spending time downloading the whole file, or if it’s just comparing the local file with the one on the server.

    This behavior will be fairly be browser specific, so if you test in firefox, webkit and IE you may potentially see slightly different results.


    firefox respects caching info in audio file http headers, webkit browser perform a quicky check.

    http://mindtrove.info/archive/2010/02/1/

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a webpage that pulls information from a database, converts it to .csv
I have a webpage that is taking way too long and need to optimize
I have a webpage that implements a set of tabs each showing different content.
I have a webpage that I use h1 tags multiple times within various DIVs
I have a webpage that redirects to another webpage like this: http://www.myOtherServer.com/Sponsor.php?RedirectPage=http://mylink.com/whereIwasgoingtogo.html Then the
I have a webpage that displays a very large list of data. Since this
I have a webpage that I don't have the ability to change the underlying
I have a webpage that activates a print job on a printer. This works
I have a webpage that displays a calendar, and I want to change the
I'm trying to make a HTML5 webapp that simply plays a sound over and

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.