flygirl Posted March 16, 2006 Posted March 16, 2006 Hi Guys and Gals,Hope one of you gurus can help me!I'm running FrontPage 2002 and I want to put a button on my home-page to play music when selected. I've got as far as playing background music but that starts as soon as the home-page opens. I'd like the surfer to have control. I know that whenever I've opened a music file on the web, my browser goes to Media Player so, if I may be so bold as to ask:(a) Is it possible to have a button that, when pressed, plays a .wav file (just once and not on a loop)(B) Is it possible to keep the home-page visible to the surfer without going to Media Player© Is it possible to configure the button so it plays on the surfers music player if they don't have Media Player (Real Player etc.)I apologise for the number of 'is it possibles' but I'm a newbie at this. The HTML page just looks like a jumble of ancient Egyptian (can't spell that hyroglyphics word - if that's right, I take that back) so a step by step guide would be most appreciated and turn me from mad to ecstatic.Hope someone out there can helpMy personal e-mail is flygirl757@hotmail.co.uk (please note the .co.uk).LoveMichelle
gunsmokingman Posted March 16, 2006 Posted March 16, 2006 This should work in theory this is a HTA so you can see how it works.Save As DemoMusic.HtaAll you have to do is place the button name play and it script in your web page.You must also have add the path for the music file. Try the HTA first to see how it works.<HTML><HEAD><BODY> <html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns="http://www.w3.org/TR/REC-html40"> <Title> Demo_MusicButton </Title><HTA:APPLICATION ID="MusicButton" SCROLL="No" SCROLLFLAT ="No" SingleInstance="Yes" ShowInTaskbar="Yes" SysMenu="Yes" MaximizeButton="No" MinimizeButton="No" Border="Thin" BORDERSTYLE ="complex" INNERBORDER ="No" Caption="Yes" WindowState="Normal" APPLICATIONNAME="MusicButton" Icon="Hta2.ico"> <meta http-equiv=Content-Type content="text/html; charset=windows-1252"><meta name=ProgId content=Word.Document> <meta name=Generator content="Microsoft Word 11"><meta name=Originator content="Microsoft Word 11"> <style type="text/css"> .Button {font-family:Palatino-Linotype;font-size :8.75pt;font-weight:Bold-Italic; line-height:110%;color:#09f6ed;background-color:#6CA2E3;filter:progid:DXImageTransform.Microsoft.Gradient (GradientType=0,StartColorStr='#5e9ab9,endColorStr='#006060'');width:91;height:25; padding-top:1;padding-bottom:1;padding-left:5;padding-right:5;margin-right:5;margin-left:5;} Body.Normal {font:9.75pt;font-family:Palatino-Linotype;color:#004040;background-color:#ed0926;filter: progid:DXImageTransform.Microsoft.Gradient(GradientType=0,StartColorStr='#eeeeee',endColorStr='#5e9ab9'); padding-top:1;padding-bottom:1;Text-Align:Center;Valign:Top;} </STYLE> <script> function MusicToPlay(address) {window.location=address;} function ExitHta(){self.close();} </script> <Body Class="Normal"> <Table> <!-- =================================== PLACE THE WEB ADDRESS HERE ================== --> <Input Type="Button" Class="Button" onClick="MusicToPlay('Http://www.gunsmokingman.ath.cx/Music_Temp/Janeiro.wma')" Value="Play"> <Input Type="Button" Class="Button" onClick="ExitHta()" Value="Exit"> </Table>
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now