HTML - Adding Sound To A Link Using Css
Hey, I'm about 50% done creating my website. And I was thinking of adding sounds to my links (on mouseover).
Well I decided that I definitely want to. I've picked out the sound. The only problem is, I only know how to add sound to a link like that using javascript. And with 50% of all of my pages created. I don't want to go back through all of those pages to add javascript into the header and change the coding and all of that stuff. So is there anyway I can add my sound using CSS (all of my pages are linked to a CSS file). This way I won't have to edit ALL of my pages, instead, just my CSS sheet. Thanks in advanced. - Jake Similar TutorialsI was wondering how i add sound to my webpage, so that it plays when the user enters the page, but with a play and stop button. This is what I got... Quote: <bgsound src="music/nameofsong.mp3" loop="0" id="sound" /> Quote: <script type="text/javascript"> function stop() { document.getElementById("sound").src = ""; } </script> Quote: <input type="button" onclick="stop();" /> It all works... fine, but not up to my standard. The button is so bad What I want to accomplish is this... A person goes on the site, music is playing, at the bottom of the page there is an 'onoff' option. They click 'off', it goes to regular, and the 'on' turns bold. When they click on, viseversa happenes. Is this possible with regular HTML :S Having sucha headache here.. tried a lot Hi there.. i added some menu buttons for my site this is the code for the menu button <BUTTON TYPE=SUBMIT> <IMG SRC="../graphics/sfsmile.gif" HEIGHT=97 WIDTH=105 ALT="Starflower" ALIGN="ABSMIDDLE"> <STRONG>Send It In!</STRONG></BUTTON> Or go here i took this code from this website http://www.htmlcodetutorial.com/forms/_BUTTON.html you have an example here Now i added them but i have no clue how to add a link to this button so that when i click on it sents me to a page.. any ideeas pls ? Can anyone help me so that i can add a link to this menu button ? Thx Hi Everybody! I am new to java script... I got this freelance job that I need to work on a javascript developed by somebody else. I need to add a url link to an Array. So not only the image will swap but after a mouse down another url is called. Is it posssible? Any suggestion is appreciated!! Thanks! Bellow is the code +++++++++++++++++++++++ var aryImages = new Array() var aryDesc = new Array() aryImages[1] = new Image(380, 380); aryImages[1].src = "images/online_partners_demandmade.gif"; aryDesc[1] = "" +++++++++++++++++++++++ Hi all, I cant seem to manage to put links to the slideshow I'm using. http://fifthmammoth.co.uk/slideshow/example4.html This doesn't appear to work: Code: <div id="slide_01"> <div id="myShow-1" class="slide-show"> <div class="slide first"> <a href="pro_scherm/index.html"><img alt="" src="slideshow2/images/slide_01.jpg" width="300" height="200"> <div class="slide-caption">plaatje 1</div></a> </div> <div class="slide"> <img src="slideshow2/images/slide_02.jpg" width="300" height="200"> <div class="slide-caption">plaatje 2</div> </div> <div class="slide"> <img src="slideshow2/images/slide_03.jpg" width="300" height="200"> <div class="slide-caption">plaatje 3</div> </div> </div> Another thing I'd like to accomplish, to make a link between the slideshow in the mainscreen, and the menubar below. Ideally, if you rollover the slideshow, the matching project in the menubar below lightens. Is it possible to create a rollover effect like this? Your help would be really appreciated! Hey every one I've got a simple one. When you copy and paste a link into face book often times a small image shows up to the left of link with the description. So I'm trying to get that to work on a site that I've built. I've read a bit about the open graph meta tags and a few simpler stop gaps but so far no luck. Did a bit of reading here but when push came to shove I'm still stuck: http://stackoverflow.com/questions/1...ost-link-image I'm trying to get the following image to be my FB link Image: http://www.eartheasy.johncliffordtay...s/thumb000.png So far I have plugged in the flowing HTML code in my <head> area of the with no luck: Code: <!-- Opengraph protocol. See http://ogp.me/ --> <meta property="og:title" content="Earth Easy Pest Control" /> <meta property="og:type" content="company" /> <meta property="og:url" content="http://www.eartheasy.johncliffordtaylor.com" /> <meta property="og:image" content="http://www.eartheasy.johncliffordtaylor.com/images/thumb000.png" /> Also I've tried the simpler work around mentioned in the above article with no luck: Code: <link rel="image_src" href="http://www.eartheasy.johncliffordtaylor.com/images/thumb000.png" /> As always thanks for the help in advance ladies and gents! Have a great day! JT I would like to add a link to my page that will call the current page that I am on...I need the call to not not only preseves the current params that were present in the initial call, but I would also like to add one addtional param. Is this possible? Example: Page call: index.html?view=all Wiithin the index.html file I want to add an <a href=""> tag that when clicked it will add an additional parameter "music=off" So the link would be: index.html?view=all&music=off Is this possible? Hello, Can someone please help me with this: I am trying to embed a sound into a text link...here is the code: <li><a class="last" href="index.html">Inchide Sistemul</a></li> ...when I click the link I want to play a sound, how can I modify the code to do that? Thanks I can't seem to get a sound to play on my site. I can edit the code and execute it on my computer and it works fine. When I upload it to my page, it doesn't work. I use Firefox but also tried it with IE. I have tried both EMBED and BGSOUND. The sound is a very small WAV file. Where am I going wrong? hey all, i have added mp3 file using quicktime player it works fine is IE but, it doesn't work on firefox. it comes up with missing plugin (even though i have quicktime installed) if i change this code to wmp then the activex doesnt show up any ideas whats gone wrong? Code: <div class="navStyle" id="subMenu"> Silent Hill 4: Cradel of the forest <br /> <br /> <object width="171" height="20" classid="clsid:02BF25D5-8C17-4B23-BC80-D3488ABDDC6B" codebase="http://www.apple.com/qtactivex/qtplugin.cab"> <param name="src" value="../media/essentials/thread/1.mp3" /> param name="autoplay" value="false" /> <param name="controller" value="true" /> <!-- For Older Browsers --> <embed src="../media/essentials/thread/1.mp3" width="171" height="50" autoplay="false" controller="true" pluginspage="http://www.apple.com/quicktime/download/"> </embed> </object> </div> Is it possible to make a sound when the mouse goes over an image? maybe using some JS or something. Also on mouseout aswell I would like it to make some kind of beeping noise when the user hovers over an image but i dont want to go in to all that flash stuff etc... Just wondering if anyone knows a good way to loop like a 3 second sound clip on a page? I want it to start as soon as the page loads and keep looping. Any help would be awesome. Thanks I have a sound problem with chrome. I have been added a song to my website using: <embed src="c1.mp3" width="200" height="100" autoplay="true" hidden="true" loop="1" volume="100"></embed> but is not working in chrome. On the other hand is woking in IE 6 What is the problem?? I have this alert box that I would like to add a sound after you click ok. Can this be done to the script I have here? Thanks //<![CDATA[ var alertmessage="Well this the last and finale Assignment for the JavaScript Level One Course" //Alert only once per browser session (0=no, 1=yes) var once_per_session=1 function get_cookie(Name) { var search = Name + "=" var returnvalue = ""; if (document.cookie.length > 0) { offset = document.cookie.indexOf(search) if (offset != -1) { // if cookie exists offset += search.length // set index of beginning of value end = document.cookie.indexOf(";", offset); // set index of end of cookie value if (end == -1) end = document.cookie.length; returnvalue=unescape(document.cookie.substring(offset, end)) } } return returnvalue; } function alertornot(){ if (get_cookie('alerted')==''){ loadalert() document.cookie="alerted=yes" } } function loadalert(){ alert(alertmessage) } if (once_per_session==0) loadalert() else alertornot() //]]> http://pavel.free-site-host.com/ I have a couple of problems with this layout. First of all I have set up a script for mouse over sound over the nav, but when i mouse over nothing happens. Next I have set up another script that has random images but for some reason it has made the layout unaligned. Last, towards the bottom it has a blank spot for a search (for the web-site) could somebody explain how to create a search for the content inside the site. Thank you in advance I am on myspace. I am trying to send a comment with a sound wav. I don't want a link I want a small player that will play the file. I want it to be Html but I don't know how to get it that way. I've tried everything . Help??! Hello everyone, I'm currently making a Super Mario Bros website. I'm using hover buttons. Those question mark stones and when you hover over them a coin comes out with the tittle of the page the button refers to. I also have a Flash file with the sound of the coins from Super Mario Bros. The file is called Coin.swf. How do I get the sound to play once when you hover over them? Help would be greatly appreciated. Thanks in advance, d4rcr3st I need to add sound to a rollover button. I have downloaded the sound file(.wav) that I want and have in my project's folder. When I check the Dreamweaver help section it says to link to the sound; problem is I also need to link to a page when the button is clicked. How do I acheive this? I am using Dreamweaver 8. I appreciate all help offered. Thanks, Tazmania hi this is new user. i have one query that i want to play a sound(eg.mid) in background when i opne my html code. so anybody can tell me how to do that in detail. with littel code too. thnks in advance i am waiting for reply. Hi, I'm making my first website, and I'm trying to embed an mp3 file into a page. So far I have a folder of html files on my computer an haven't uploaded to a server yet. With the file "Telefone529Musicology.mp3" in this folder, and using the tag: Code: <embed src="Telefone529Musicology.mp3" WIDTH="145" HEIGHT="60" AUTOPLAY="true" LOOP="true"></embed> I can't get it to work on either FF or IE7, and I want it to work on both, since they seem to be the most popular browsers. In FF, my page loads, and at the point of the embed tag I get a square box containing the quicktime logo and a question mark, with no sound. I checked my quicktime settings, and the default action for .mp3 files is to use the quicktime plugin, and I'm sure it has worked in the past so is it a problem with the code or some other settings I need to configure on my browser? Likewise, in IE7, the same thing happens, except I get a box with a little red cross, and no sound. Again, I'm sure my quicktime plugins are up to date, and configured to play mp3 files, so I'm lost. I'd really like to get this working, Thanks |