hackmeanscode
10-15-2006, 05:25 PM
Okay, so I am workig on something called Tudit, and there is something wrong with the following code- but I am not sure what:
<?php
// Start output buffering.
ob_start();
// Initialize a session.
session_start();
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1" />
<title>Tudit: <?php echo $name ?></title>
<style>
#display
{
width: 80%;
height: 80%;
}
.tab
{
background: url(tab.png) repeat-x;
width: 50px;
height: 15px;
border: #000000 thin solid;
overflow: hidden;
font-size: 14px;
font-family: Arial, Helvetica, sans-serif;
font-color: #fff;
}
</style>
</head>
<body>
<?php
$name=$_GET["channel"];
require_once ('../mysql_connect.php'); // Connect to the database
$result = mysql_query("SELECT source1, name1, source2, name2, source3, name3, source4, name4, source5, name5
FROM channels
WHERE channame = ' $name ';");
while($row = mysql_fetch_array($result))
{
echo '<a href="aggregate.php?readsource=' . $row[source1] . '" target="ifrm" class="tab">' . $row[name1] . '</a>';
echo '<a href="aggregate.php?readsource=' . $row[source2] . '" target="ifrm" class="tab">' . $row[name2] . '</a>';
echo '<a href="aggregate.php?readsource=' . $row[source3] . '" target="ifrm" class="tab">' . $row[name3] . '</a>';
echo '<a href="aggregate.php?readsource=' . $row[source4] . '" target="ifrm" class="tab">' . $row[name4] . '</a>';
echo '<a href="aggregate.php?readsource=' . $row[source5] . '" target="ifrm" class="tab">' . $row[name5] . '</a>';
}
?>
<iframe src="mosource.php" name="ifrm" id="ifrm" frameborder="0" height="650" width="900" />
</body>
</html>
<?php // Flush the buffered output.
ob_flush();
?>
Help please!
<?php
// Start output buffering.
ob_start();
// Initialize a session.
session_start();
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1" />
<title>Tudit: <?php echo $name ?></title>
<style>
#display
{
width: 80%;
height: 80%;
}
.tab
{
background: url(tab.png) repeat-x;
width: 50px;
height: 15px;
border: #000000 thin solid;
overflow: hidden;
font-size: 14px;
font-family: Arial, Helvetica, sans-serif;
font-color: #fff;
}
</style>
</head>
<body>
<?php
$name=$_GET["channel"];
require_once ('../mysql_connect.php'); // Connect to the database
$result = mysql_query("SELECT source1, name1, source2, name2, source3, name3, source4, name4, source5, name5
FROM channels
WHERE channame = ' $name ';");
while($row = mysql_fetch_array($result))
{
echo '<a href="aggregate.php?readsource=' . $row[source1] . '" target="ifrm" class="tab">' . $row[name1] . '</a>';
echo '<a href="aggregate.php?readsource=' . $row[source2] . '" target="ifrm" class="tab">' . $row[name2] . '</a>';
echo '<a href="aggregate.php?readsource=' . $row[source3] . '" target="ifrm" class="tab">' . $row[name3] . '</a>';
echo '<a href="aggregate.php?readsource=' . $row[source4] . '" target="ifrm" class="tab">' . $row[name4] . '</a>';
echo '<a href="aggregate.php?readsource=' . $row[source5] . '" target="ifrm" class="tab">' . $row[name5] . '</a>';
}
?>
<iframe src="mosource.php" name="ifrm" id="ifrm" frameborder="0" height="650" width="900" />
</body>
</html>
<?php // Flush the buffered output.
ob_flush();
?>
Help please!