I have a very odd issue with a snippet not showing at all in a resource- either with the [[ or the [! tags. It’s basically the presentation code for a Flash SWF plus a mySQL query to a db which has been set up and is working.
It looks as if it just isn’t reading the snippet properly, because I can add errors into the mySQL query or anywhere else and it doesn’t do anything. Looking at the outputted page source code, there’s absolutely no ouput from the snippet whatsoever except an echo statement that I put in.
Any ideas? (here’s the code)
<?php
include ('manager/advertising/inc/dbconnect.php');
// Build SQL Query
$query = "SELECT * FROM home ORDER BY rand() LIMIT 1"; // specify the table and field names for the SQL query
$numresults=mysql_query($query);
$numrows=mysql_num_rows($numresults);
// get results
$result = mysql_query($query) or die("Couldn't execute query");
// display the results returned
while ($row= mysql_fetch_array($result)) {
$title = $row["url"];
echo $title;
}
echo '<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" width="120" height="285" id="FlashID2" title="Radisson Hotels">
<param name="movie" value=" ' . $title . '/>
<param name="quality" value="high" />
<param name="wmode" value="opaque" />
<param name="swfversion" value="7.0.70.0" />
<!-- This param tag prompts users with Flash Player 6.0 r65 and higher to download the latest version of Flash Player. Delete it if you don’t want users to see the prompt. -->
<param name="expressinstall" value="scripts/expressInstall.swf" />
<!-- Next object tag is for non-IE browsers. So hide it from IE using IECC. -->
<!--[if !IE]>-->
<object type="application/x-shockwave-flash" data="/1.swf" width="120" height="285">
<!--<![endif]-->
<param name="quality" value="high" />
<param name="wmode" value="opaque" />
<param name="swfversion" value="7.0.70.0" />
<param name="expressinstall" value="scripts/expressInstall.swf" />
<!-- The browser displays the following alternative content for users with Flash Player 6.0 and older. -->
<div>
<h4>Content on this page requires a newer version of Adobe Flash Player.</h4>
<p><a href="http://www.adobe.com/go/getflashplayer"><img src="http://www.adobe.com/images/shared/download_buttons/get_flash_player.gif" alt="Get Adobe Flash player" width="112" height="33" /></a></p>
</div>
<!--[if !IE]>-->
</object>
<!--<![endif]-->
</object>
<script type="text/javascript">
<!--
swfobject.registerObject("FlashID2");
//-->
</script>';
?>
I should also point out that it does show the path when I echo the $title variable in the code (see above).