|
-
Apr 11th, 2001, 02:06 AM
#1
Thread Starter
Evil Genius
How can I play a sound file when my Html / web page loads please ?
I guess this would be under the :
Sub Document_OnLoad()
event, but I've no idea how to do this.
Can this work for several media types also please ?
I may need to change this file in the future, so I'd like to support *.avi, *.mpg & a couple of other standard ones if possible please.
Thanks for all your help !
-
Apr 11th, 2001, 03:47 AM
#2
Retired VBF Adm1nistrator
Well to play a sound once when the page loads :
Code:
<html>
<head>
<title>Some Title</title>
<bgsound src="file:///C:/jamie/Funnies/TRACTOR1.wav" loop="0">
</head>
<body>
</body>
</html>
In terms of playing a movie or whatever, this should do the trick :
Code:
<img border="0" dynsrc="file:///C:/jamie/Funnies/fight.avi" start="fileopen" width="168" height="84">
Ya follow ?
- jamie
Microsoft MVP : Visual Developer - Visual Basic [2004-2005]
-
Apr 11th, 2001, 04:01 AM
#3
Thread Starter
Evil Genius
Ya Mon ! I follow,
That's great cheers !
-
Apr 11th, 2001, 06:13 AM
#4
Retired VBF Adm1nistrator
To whom shall I address the invoice
Microsoft MVP : Visual Developer - Visual Basic [2004-2005]
-
Apr 11th, 2001, 06:31 AM
#5
Thread Starter
Evil Genius
Cheques in the post ! 
TOUGH ONE I was asked this by a mate, & passed it to this forum. I've just suggested this and have the following puzzing scenario ...
He's used one of these simple wizard type websites that puts all the HTML code in & makes the website for you.
They only allow *.avi files to be uploaded for this. His new question, can I connect to HIS PC, rather than using the server the webpage is on. This isn't networked, so I wondered if you could use the PC's IP address instead. so instead of :
Code:
src="file:///C:/jamie/Funnies/fight.avi"
Could you have :
Code:
src="file:255.0.0.1///C:/jamie/Funnies/fight.avi"
Type thing please ?
Thank you (hope I made some sense there)!
-
Apr 11th, 2001, 06:37 AM
#6
Retired VBF Adm1nistrator
Well if the system is running PWS or something similar, then he would do :
Code:
src="http://127.0.0.1/jamie/Funnies/fight.avi"
Assuming there is a folder called jamie off the root directory of the webserver.
He should have pws ; it comes with win98.
- jamie
Microsoft MVP : Visual Developer - Visual Basic [2004-2005]
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|