Jump to content

Game Playing System


davidknag

Recommended Posts

weird stuff maybe add the following line:

<?php
$con = mysqli_connect('localhost', 'webuser', 'davidknag', 'games')or die(mysqli_error($con));

if(isset($_GET['id'])){
     $query_var = (int)$_GET['id']; // force it to be an integer

$query=" SELECT * FROM games WHERE id = '$query_var'";

     $result = mysqli_query($con, $query)or die(mysqli_error($con));
     while($row =  mysqli_fetch_array($result)) { //this output should be filtered in a real world
         $string1= '<td><h2 class="blye2"><i>'.$row['title'].'</i></h2><br />';
         $string2= 'dd'.$row['swfname'].'<br />';
         $string3= 'Description: '.$row['description'].'<br/>';


$string4= 'How To: '.$row['howto'].'</h3>';
     $mysupertitle = $row['title'];// <----------------------------------------------I added this line
     }
}

?>

and than in between <title></title>

place

<?php echo $mysupertitle; ?>

 

make sure the first part is in the head or ontop of your page since it read from top to bottom.

weird stuff maybe add the following line:

<?php
$con = mysqli_connect('localhost', 'webuser', 'davidknag', 'games')or die(mysqli_error($con));

if(isset($_GET['id'])){
     $query_var = (int)$_GET['id']; // force it to be an integer

$query=" SELECT * FROM games WHERE id = '$query_var'";

     $result = mysqli_query($con, $query)or die(mysqli_error($con));
     while($row =  mysqli_fetch_array($result)) { //this output should be filtered in a real world
         $string1= '<td><h2 class="blye2"><i>'.$row['title'].'</i></h2><br />';
         $string2= 'dd'.$row['swfname'].'<br />';
         $string3= 'Description: '.$row['description'].'<br/>';


$string4= 'How To: '.$row['howto'].'</h3>';
     $mysupertitle = $row['title'];// <----------------------------------------------I added this line
     }
}

?>

and than in between <title></title>

place

<?php echo $mysupertitle; ?>

 

make sure the first part is in the head or ontop of your page since it read from top to bottom.

yep of course :P

 

thanks man ;)

worked like a charm

ty for all your help

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.