e1seix
07-12-2007, 05:43 PM
I'll explain. Have managed to get my php pages the way I want them to individually, but obviously I want to expand the pages to encompass link menus etc. so if my php code is...
<?php
// Make a MySQL Connection
mysql_connect("blah...", "blah...", "blah...") or die(mysql_error());
mysql_select_db("blah") or die(mysql_error());
$product_sku = $_GET['product_sku'];
// Get a specific result from the "example" table
$result = mysql_query("SELECT * FROM shaving WHERE product_sku=$product_sku AND DEF='T05'") or die(mysql_error());
echo "<table border='0' cellpadding='5' cellspacing='0' width='100%'>";
while($row = mysql_fetch_array( $result )) {
// Print out the contents of each row into a table
echo "<tr><td bgcolor='#ffff00'><p class='BRAPRO'>";
echo $row ['BRA']. " | ". $row['PRO'];
echo "</p></td></tr>";
}
echo "</table>";
?>
... why am i getting error messages when i try to do this...
<html>
<head></head>
<body>
<table>
<tr>
<td>
<?php
// Make a MySQL Connection
mysql_connect("blah...", "blah...", "blah...") or die(mysql_error());
mysql_select_db("blah") or die(mysql_error());
$product_sku = $_GET['product_sku'];
// Get a specific result from the "example" table
$result = mysql_query("SELECT * FROM shaving WHERE product_sku=$product_sku AND DEF='T05'") or die(mysql_error());
echo "<table border='0' cellpadding='5' cellspacing='0' width='100%'>";
while($row = mysql_fetch_array( $result )) {
// Print out the contents of each row into a table
echo "<tr><td bgcolor='#ffff00'><p class='BRAPRO'>";
echo $row ['BRA']. " | ". $row['PRO'];
echo "</p></td></tr>";
}
echo "</table>";
?>
<td>
</tr>
</table>
</body>
</html>
... can someone show me how?
<?php
// Make a MySQL Connection
mysql_connect("blah...", "blah...", "blah...") or die(mysql_error());
mysql_select_db("blah") or die(mysql_error());
$product_sku = $_GET['product_sku'];
// Get a specific result from the "example" table
$result = mysql_query("SELECT * FROM shaving WHERE product_sku=$product_sku AND DEF='T05'") or die(mysql_error());
echo "<table border='0' cellpadding='5' cellspacing='0' width='100%'>";
while($row = mysql_fetch_array( $result )) {
// Print out the contents of each row into a table
echo "<tr><td bgcolor='#ffff00'><p class='BRAPRO'>";
echo $row ['BRA']. " | ". $row['PRO'];
echo "</p></td></tr>";
}
echo "</table>";
?>
... why am i getting error messages when i try to do this...
<html>
<head></head>
<body>
<table>
<tr>
<td>
<?php
// Make a MySQL Connection
mysql_connect("blah...", "blah...", "blah...") or die(mysql_error());
mysql_select_db("blah") or die(mysql_error());
$product_sku = $_GET['product_sku'];
// Get a specific result from the "example" table
$result = mysql_query("SELECT * FROM shaving WHERE product_sku=$product_sku AND DEF='T05'") or die(mysql_error());
echo "<table border='0' cellpadding='5' cellspacing='0' width='100%'>";
while($row = mysql_fetch_array( $result )) {
// Print out the contents of each row into a table
echo "<tr><td bgcolor='#ffff00'><p class='BRAPRO'>";
echo $row ['BRA']. " | ". $row['PRO'];
echo "</p></td></tr>";
}
echo "</table>";
?>
<td>
</tr>
</table>
</body>
</html>
... can someone show me how?