Hi djjjozsi.
ok this is how it is at the moment:
This is the complete page of the file that gets the video to show on another page:
<?
require_once 'tubeinc/config.php';
function insertclip($id)
{
$id = $_GET["id"];
$query = "SELECT file FROM clips WHERE id = '$id'";
$result = mysql_query( $query );
while ( $content = mysql_fetch_object( $result ) )
print( "<table width=\"500px\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\" bgcolor=\"#000000\"><tr><td align=\"center\" style=\"{padding: 2px;}\"></td></tr><tr><td><p id=\"player1\"><a href=\"http://www.macromedia.com/go/getflashplayer\">Get the Flash Player</a> to see this player.</p>
<script type=\"text/javascript\">
var FO = { movie:\"mediaplayer.swf\",width:\"480\",height:\"360\",majorversion:\"7\",build:\"0\",bgcolor:\"#FFFFFF\",allowfullscreen:\"true\",autoplay:\"true\",
flashvars:\"file=$content->file\" };
UFO.create( FO, \"player1\");
</script></td></tr></table>" );
}
function insertcliplist($clip_cat_id) {
$clip_cat_id = $_GET["clip_cat_id"];
$query = "SELECT * FROM clips WHERE clip_cat_id ='$clip_cat_id'";
$return = mysql_query($query);
$num = mysql_numrows($return);
echo "<table border='0'>";
$query = "SELECT clipcol FROM config";
$content = mysql_fetch_object( mysql_query( $query ) );
$ncols = "$content->clipcol";
$i=0;
while($i < $num){
echo "<tr>";
$ci=0;
while($ci < $ncols){
if($i < $num){
$id = trim(mysql_result($return, $i, "id"));
$clip_name = trim(mysql_result($return, $i, "clip_name"));
$description = trim(mysql_result($return, $i, "description"));
$query = "SELECT tubepage FROM config";
$content = mysql_fetch_object( mysql_query( $query ) );
if ($description == "") {
echo "<td><a href='".$content->tubepage."?id=".$id."&clip_cat_id=".$clip_cat_id."'>".$clip_name."</a></td>";
}else{
echo "<td><a href='".$content->tubepage."?id=".$id."&clip_cat_id=".$clip_cat_id."'>".$clip_name." (".$description.")</a></td>";
}
}else{
echo "<td> </td>";
}
$i++;
$ci++;
}
echo "</tr>";
if($i == 0){
$i = $num;
}
}
echo "</table>";
}
function insertcatlist() {
$query = "SELECT * FROM cat ORDER BY cat_name ASC";
$return = mysql_query($query);
$num = mysql_numrows($return);
echo "<table border='0'>";
if($num != 0){
$query = "SELECT catcol FROM config";
$content = mysql_fetch_object( mysql_query( $query ) );
$ncols = "$content->catcol";
$i=0;
while($i < $num){
echo "<tr>";
$ci=0;
while($ci < $ncols){
if($i < $num){
$clip_cat_id = trim(mysql_result($return, $i, "clip_cat_id"));
$cat_name = trim(mysql_result($return, $i, "cat_name"));
$query = "SELECT clippage FROM config";
$content = mysql_fetch_object( mysql_query( $query ) );
echo "<td><a href='".$content->clippage."?clip_cat_id=".$clip_cat_id."'>".$cat_name."</a></td>";
}else{
echo "<p> </p>";
}
$i++;
$ci++;
}
echo "</tr>";
if($i == 0){
$i = $num;
}
}
}
echo "</table>";
}
function insertupload() {
?>
<script language="javascript" type="text/javascript" src="tubefiles/menu.js"></script>
<?
$query = "SELECT uploadclips FROM config";
$content = mysql_fetch_object( mysql_query( $query ) );
echo "<a href=\"javascript:openpopupa()\">".$content->uploadclips."</a>";
}
?>
And this is the code on the output page without all the html as its not needed as its just html code:
<p class="center">
<table width="500px" border="0" cellspacing="0" cellpadding="0" bgcolor="#000000"><tr><td align="center" style="{padding: 2px;}"></td></tr><tr><td><p id="player1"><a href="http://www.macromedia.com/go/getflashplayer">Get the Flash Player</a> to see this player.</p>
<script type="text/javascript">
var FO = { movie:"mediaplayer.swf",width:"480",height:"360",majorversion:"7",build:"0",bgcolor:"#FFFFFF",allowfullscreen:"true",autoplay:"true",
flashvars:"file=../clips/view_video.php?viewkey=2e7daed3677ce8e9fe40" };
UFO.create( FO, "player1");
</script></td></tr></table><br class="spacer" />
<table border='0'><tr><td><a href='http://www.mysite.com/vids/video.php?id=2&clip_cat_id=2'>loose wheel</a></td></tr><tr><td><a href='http://www.mysite.com/vids/video.php?id=11&clip_cat_id=2'>Bull Butt</a></td></tr><tr><td><a href='http://www.mysite.com/vids/video.php?id=4&clip_cat_id=2'>hit the brakes (mad biker)</a></td></tr><tr><td><a href='http://www.mysite.com/vids/video.php?id=5&clip_cat_id=2'>panda snooze sneeze (panda snooze sneeze)</a></td></tr><tr><td><a href='http://www.mysite.com/vids/video.php?id=6&clip_cat_id=2'>cat massage</a></td></tr><tr><td><a href='http://www.mysite.com/vids/video.php?id=12&clip_cat_id=2'>one sexy babe</a></td></tr></table><br class="spacer" />
<script language="javascript" type="text/javascript" src="tubefiles/menu.js"></script>
<a href="javascript:openpopupa()">Upload Movies</a></p>
So as you can see the "$content->file" part is not giving the full url to the video file, and thats where the problem is- as it should read :
flashvars:"file=http:www.mysite.com/vids/clips/view_video.php?viewkey=2e7daed3677ce8e9fe40" };
I just cant seem to get my head around why it shows "../ " instead of the full url.
I apologise for being such a pain & hope you can come up with an solution to this.
Thanks again.
Pablos234.