Jump to content

Run Once > Fash then static .jpg


trochia

Recommended Posts

  Good day to all,

  I am fairly new to php and having a cookie problem I think.

  I have a .swf file that I would like to "run once" when the visitor first comes to the "index" of the site in maybe a 24 hour period.

  It would then become static ( .jpg ) when going thru the rest of the site for the 24 hours or whatever it is set at.

  Any help would be greatly appreciated.

Jim
Link to comment
https://forums.phpfreaks.com/topic/34568-run-once-fash-then-static-jpg/
Share on other sites

George, thanks for the reply... 

Here's in my index =

if(!isset($_COOKIE['flash_cookie'])){
  @setcookie('flash_cookie', 1, time() + (60*5), '/', '.domain.com', 0);
}

then this, is in my functions.php =

<?php if(!isset($_COOKIE['flash_cookie'])){ ?>

<OBJECT classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"
codebase="http://active.macromedia.com/flash2/cabs/swflash.cab#version=4,0,0,0" ID=Untitled WIDTH=720 HEIGHT=130>
<PARAM NAME=movie VALUE="images/nw.swf">
<PARAM NAME=quality VALUE=high>
<PARAM NAME=loop VALUE=False>
<param NAME="wmode" Value="transparent";>
<EMBED src="images/nw.swf" loop=false quality=high
WIDTH=720 HEIGHT=130 TYPE="application/x-shockwave-flash"
PLUGINSPAGE="http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash">
</EMBED>
</OBJECT>

<?php }else{ ?>

<img src="images/_bannerstrip.jpg" width="720" height="130" border="0">

<?php } ?>

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.