Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Controling the Start Frame from HTML 2

Status
Not open for further replies.

asda

Programmer
Jan 18, 2002
2
GB
Is is possiable to control which frame the flash flie start at from the HTML..

by using any <param>

<OBJECT classid=&quot;clsid:D27CDB6E-AE6D-11cf-96B8-444553540000&quot;
codebase=&quot; WIDTH=548 HEIGHT=40>
<PARAM NAME=movie VALUE=&quot;BarAccess.swf&quot;><PARAM NAME=Frame VALUE =2 <PARAM NAME=loop VALUE=false> <PARAM NAME=menu VALUE=false> <PARAM NAME=quality VALUE=high> <PARAM NAME=bgcolor VALUE=#FFFFFF> <EMBED src=&quot;BarAccess.swf&quot; loop=false menu=false quality=high bgcolor=#FFFFFF WIDTH=548 HEIGHT=40 TYPE=&quot;application/x-shockwave-flash&quot; PLUGINSPAGE=&quot;</OBJECT>
 
Have you tried changing the value behind PARAM NAME=Frame Value= ?
I believe you have no closing > behind that parameter. (If it's your code).

Why would you do that ? You can't open this flash file ? It is impossible to make anything foolproof because fools are so ingenious.
Murphy's Laws
 

...src=&quot;BarAccess.swf?frame=2&quot;...

[bb]
 
hey guys,

what r u talking about? none of those work! clarify this matter, will u?
 
Bignewbie Both set of html do not work ...

I am still wait for an answer

 
Well fun loving activeX got a vote... Must mean something!

Maybe it should clear it up!

Regards,
new.gif
 
put this AFTER the plugin code:

Code:
<SCRIPT LANGUAGE=&quot;JavaScript&quot;> 
var InternetExplorer = navigator.appName.indexOf(&quot;Microsoft&quot;) != -1;
baraccess.GotoFrame(2);
</SCRIPT>

remember to insert name=&quot;baraccess&quot; after the movie dimensions in between the <OBJECT> and <EMBED> tags.

dave
dave@pinkzeppelin.com

^^^^^^^^^^^^^^^^^^^^^​
 
ps: activeX, all your addition does is set a variable in the main timeline called &quot;frame&quot; and assign the value 2 to that variable.

dave
dave@pinkzeppelin.com

^^^^^^^^^^^^^^^^^^^^^​
 
dave,

what is this code for:

var InternetExplorer = navigator.appName.indexOf(&quot;Microsoft&quot;) != -1;

it is from ur example above.

biggie.
 
big,

Thanks for highlighting that because I was in a rush when I wrote that and left a vital part out. The previous code I gave will work no problem with IE but not with netscape.

To allow it to work for both browsers use the following:

Code:
<SCRIPT LANGUAGE=&quot;JavaScript&quot;> 
var InternetExplorer = navigator.appName.indexOf(&quot;Microsoft&quot;) != -1;
var dave = InternetExplorer ? window.baraccess : window.document.baraccess	;
dave.GotoFrame(2);
</SCRIPT>

where:

---the
Code:
var Internet.....
line checks whether the user is using Netscape or Internet Explorer as their browser. This is needed because both browsers target objects differently.

---the
Code:
var dave.....
line sets up a variable called dave which has the correct target definition for the particular browser.

---the final line utilises 'dave' to target the movie effectively.

On A final note, to ensure that this works in Netscape, insert
Code:
swLiveConnect=true
just before the
Code:
name=&quot;baraccess&quot;
statement within the <EMBED> tags.
dave@pinkzeppelin.com

^^^^^^^^^^^^^^^^^^^^^​
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top