Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

.php with javascript gotoAndPlay frame in flashmovie?

Posted on 2004-04-13
3
Medium Priority
?
453 Views
Last Modified: 2008-02-01
hi everyone,

i am struggling with the following thing.
I would like to "redirect" certain visitors to a named frame in a flashmovie using
.php and javascript.

i got it working to the point that if a variable is true, a link appears above the flash file.
when user clicks on this link, the movie goes to a frame named "login".

oke so far, so good. but this is an ugly solution, i would really want to hide this part en
redirect the visitor while loading the page, without having to click on a link,
but i can't get this working...

anyone with ideas?

thanks in advance,

derek

code:

<HTML>
<HEAD>
<meta http-equiv=Content-Type content="text/html;  charset=">
<TITLE>flash_realty</TITLE>
<?
if ($string=="yes"){
echo "<center>";
echo "<A href=\"javascript:document.flash_realty.TGotoLabel('/','login');document.flash_realty.Play()\">$lang_see</A>";
echo "</center>";
echo "<br>";
}
?>
</HEAD>
<BODY bgcolor="#FFFFFF">
<!-- URL's used in the movie-->
<!-- text used in the movie-->
<!--<P ALIGN="LEFT">OBJECT classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"
 codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,0,0"
 WIDTH="500" HEIGHT="570" id="flash_realty" ALIGN="">
 <PARAM NAME=movie VALUE="flash_realty.swf"> <PARAM NAME=quality VALUE=high> <PARAM NAME=bgcolor VALUE=#FFFFFF> <EMBED src="flash_realty.swf" quality=high bgcolor=#FFFFFF  WIDTH="500" HEIGHT="570" NAME="flash_realty" SWLIVECONNECT="true" ALIGN=""
 TYPE="application/x-shockwave-flash" PLUGINSPAGE="http://www.macromedia.com/go/getflashplayer"></EMBED>
</OBJECT><br><br>

</script>
</BODY>
</HTML>
0
Comment
Question by:dwax
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 12

Expert Comment

by:venkateshwarr
ID: 10813176
you can redirect to a page like this..

<?
if ($string=="yes")
{
header("Location: ________");
}
?>

for example
header("Location: http://www.google.com/"); /* Redirect browser */

I did not understand your javascript....
In any case if you want to get redirected from javascript .... you can do something like this.

<?php
if ($string=="yes"){
echo "<script>";
echo "document.flash_realty.TGotoLabel('/','login'); \n";
echo "document.flash_realty.Play(); \n";
echo "</script>";
}
?>
0
 

Author Comment

by:dwax
ID: 10814009
thanks venkateshwarr,

it works like  a charm! my javascript-skills are close to zero...
i was so dumb to put the script in the head, but it only works after the
embedded flash file.

well, thanks again
0
 
LVL 12

Accepted Solution

by:
venkateshwarr earned 1000 total points
ID: 10825022
you are welcome
0

Featured Post

Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Part of the Global Positioning System A geocode (https://developers.google.com/maps/documentation/geocoding/) is the major subset of a GPS coordinate (http://en.wikipedia.org/wiki/Global_Positioning_System), the other parts being the altitude and t…
Originally, this post was published on Monitis Blog, you can check it here . In business circles, we sometimes hear that today is the “age of the customer.” And so it is. Thanks to the enormous advances over the past few years in consumer techno…
The viewer will learn how to dynamically set the form action using jQuery.
This tutorial will teach you the core code needed to finalize the addition of a watermark to your image. The viewer will use a small PHP class to learn and create a watermark.
Suggested Courses

618 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question