these 2 lines:
<p onclick="SetSong1()"><a href="susansolo021206.wmv">Song 1</a></p>
<p onclick="SetSong2()"><a href="SonshineKids021206.wmv">Song
2</a></p>
are the problem. Its opening it in a new window.
change to:
<p onclick="SetSong1()"><a href="#">Song 1</a></p>
<p onclick="SetSong2()"><a href="#">Song 2</a></p>
and this
function SetSong2()
{
WindowsMediaPlayer1.URL = "susansolo021206.wmv";
WindowsMediaPlayer1.controls.play();
}
probably should be this:
function SetSong2()
{
WindowsMediaPlayer1.URL = "SonshineKids021206.wmv"";
WindowsMediaPlayer1.controls.play();
}
for your 2nd song.
You only want to put the wmv file reference in the setsong functions.
The #
sign I put in the <a href> section just to underline the link and bring
up a
hand cursor. There are other ways of doing it. You don't want to put a
real
href here. Some trick I picked up someplace. Probably here.
Charles
Charles, I thought I had this opening in the embeded player but I am
no
longer able to duplicate the result. Her is my modified code can you
see
where I am going wrong?
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"
http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="
http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Language" content="en-us" />
<title>Song 1</title>
<meta http-equiv="Content-Type" content="text/html;
charset=iso-8859-1" />
<style type="text/css">
#left_col {
width: 260px;
position: absolute;
left: 0px;
top: 0px;
clear: left;
}
#page_content {
margin-left: 261px;
position: relative;
}
#container {
position: relative;
overflow: hidden;
left: 0px;
top: 0px;
width: 720px;
}
..bodystyle {
text-align:center;
}
</style>
<script type="text/javascript">
<!--
function SetSong1()
{
WindowsMediaPlayer1.URL = "susansolo021206.wmv";
WindowsMediaPlayer1.controls.play();
}
function SetSong2()
{
WindowsMediaPlayer1.URL = "susansolo021206.wmv";
WindowsMediaPlayer1.controls.play();
}
function FP_callJS() {//v1.0
eval(arguments[0]);
}
// -->
</script>
</head>
<body class="bodystyle">
<div id="container">
<div id="left_col">
<p>
<object classid="clsid:6BF52A52-394A-11D3-B153-00C04F79FAA6"
id="WindowsMediaPlayer1">
<param name="URL" value="">
<param name="rate" value="1">
<param name="balance" value="0">
<param name="currentPosition" value="0">
<param name="defaultFrame" value>
<param name="playCount" value="1">
<param name="autoStart" value="0">
<param name="currentMarker" value="0">
<param name="invokeURLs" value="-1">
<param name="baseURL" value>
<param name="volume" value="50">
<param name="mute" value="0">
<param name="uiMode" value="full">
<param name="stretchToFit" value="0">
<param name="windowlessVideo" value="0">
<param name="enabled" value="-1">
<param name="enableContextMenu" value="-1">
<param name="fullScreen" value="0">
<param name="SAMIStyle" value>
<param name="SAMILang" value>
<param name="SAMIFilename" value>
<param name="captioningID" value>
<param name="enableErrorDialogs" value="0">
</object>
</p>
</div>
<div id="page_content">
<p> </p>
<p onclick="SetSong1()"><a href="susansolo021206.wmv">Song 1</a></p>
<p onclick="SetSong2()"><a href="SonshineKids021206.wmv">Song
2</a></p>
<p> </p>
<p> </p>
<p> </p>
<p> </p>
<p> </p>
<p> </p>
</div>
</div>
</body>
</html>
:
Dick,
Glad it worked. My major problem has been that for some reason media
player
needs EXACT spelling to play (at least for the asf files).
IE - if I save the asf as SoNG1.aSF, I had better put this in there,
as
song1.asf won't work.
Luckily I get to play with this, as I do it for our children's
ministry,
and
they don't really care that it doesn't look 100% professional, since
it's
for the children.
This page isn't live yet (it's actually going to be in a frame
underneath
some other pages, but it's what I've been working on. I need to
finish
embedding the CD and copyright information into the wma files.
http://www.carmelbaptist.org/edifying/carmelchildren/KidStuf/test.html
It "should" end up similar to this when it's done:
http://www.carmelbaptist.org/edifying/carmelchildren/KidStuf/febmusic.html
(hopefully better, but I do have a day job)
Charles
To Charles, It works! I just discovered where I needed to enter
the WMV
names
in the code to make them open in the embeded player. Thanks again
for
your
help.
:
This site has what I would like to be able to do.
http://www.andrew-umc.org/
:
I would like to have page with windows media player on the left
and
a
list of
movies on the right. When a movie is clicked it starts playing
in
the
player
on the left side og the page. No new player opens it just plays
any
movie
selected from the list. Any ideas appreciated.