All pastes #460085 Raw Edit

Anonymous

public text v1 · immutable
#460085 ·published 2007-04-26 21:01 UTC
rendered paste body
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<title>DarkMage Productions - Asset Database</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<style type="text/css">
<!--
@import url("DarkMageProd.css");
-->
</style>
</head>

<body bgcolor="#FFFFFF" link="#666666" vlink="#666666" alink="#666666" leftmargin="225" rightmargin="225">
<table width="400" border="1" bgcolor="#FFFFFF">
  <tr> 
    <td colspan="6"><img src="http://acesmm.aces.shu.ac.uk/students/assetman06/pstewar2/bars/AboutMe.jpg" width="800" height="100"></td>
  </tr>
  <tr> 
    <td width="108" class="Links"><div align="center"><a href="home.htm">HOME</a></div></td>
    <td width="131" class="Links"><div align="center"><a href="aboutMe.htm">ABOUT 
        ME</a></div></td>
    <td width="145" class="Links"><div align="center"><a href="2D.htm">2D</a></div></td>
    <td width="136" class="Links"><div align="center"><a href="3D.htm">3D</a></div></td>
    <td width="127" class="Links"><div align="center">AUDIO</div></td>
    <td width="123" class="Links"><div align="center">VIDEO</div></td>
  </tr>
</table>
<p class="Secondheader">&nbsp;</p>
<p class="Header">Asset Database<br>
<span class="Body">Please Select a Medium and name of the Asset to be displayed.<br>
Clicking on an Asset Id number will bring up more information about that Asset.<br>
Selecting All and leaving the 'Name' box blank will result in a full database display.<br>
<span class="Body">
<form action="AssetDatabase.php" method="post"> 
<select name="Type"> 
<option>All</option>
<option>Model</option>
<option>Video</option>
<option>2D</option>
<option>Logo</option>
</select>
Name: <input name="Name" type="text" /> 
<input type="submit" />
</form>

<!-phpmysql1.php-->
<?php
include 'dbparams.php';
$con = mysql_connect("localhost",$user,$password);
$query 	= "SELECT * FROM `Asset`";
$sel		= mysql_select_db(pstewar2_db1, $con);
$result 	= mysql_query($query);
$Type = $_POST['Type'];
$Name = $_POST['Name'];
$NameQuery = $row['Name'];
Print "<Span Class=\"Header\">";
Print "<table border cellpadding=3>";
Print "<tr>";
Print "<td align=centre>Asset ID</td>";
Print "<td align="centret">Asset Name</td>";
Print "<td align="centre">Author</td>";
Print "<td>Medium</td>";
Print "<td>SoftWare Used</td>";
Print "<td>Thumbnail</td>";
Print "<Span Class =\"body\">";
while	($row = mysql_fetch_array($result,MYSQL_BOTH))
{
IF ($row['Name'] ==  $Name || $Name == "" ){
IF  ($row['Medium'] == $Type || $Type == "All" ) {
Print "<tr>";
Print "<td> <a href= details.php?Selected=".$row['ID'] ."> ".$row['0'] . "</td> ";
Print "<td>".$row['Name'] . "</td> ";
Print "<td>".$row['Author'] . "</td> ";
Print "<td>".$row['Medium'] . "</td> ";
Print "<td>".$row['Software Used'] . "</td> ";
Print "<td> <a href=".$row['Thumbnail'] . "><img src=".$row['Thumbnail'] . " width=125 > </td></tr>";
}
}
}
Print "</table>"; 
?>
</body>
</html>