|
Server : Apache/2.4.62 System : FreeBSD fbsdweb2.web.rcn.net 14.1-RELEASE FreeBSD 14.1-RELEASE releng/14.1-n267679-10e31f0946d8 GENERIC amd64 User : www ( 80) PHP Version : 8.3.8 Disable Function : NONE Directory : /domains/academic/logs/ |
Upload File : |
<?php
# FileName="Connection_php_mysql.htm"
# Type="MYSQL"
# HTTP="true"
$hostname_StudentTrackerV = "mysql.web.rcn.net";
$database_StudentTrackerV = "academicassetmanagement_com";
$username_StudentTrackerV = "Admin";
$password_StudentTrackerV = "snarf16";
$StudentTrackerV = mysql_connect($hostname_StudentTrackerV, $username_StudentTrackerV, $password_StudentTrackerV) or trigger_error(mysql_error(),E_USER_ERROR); ?>
<?php setcookie('Teacher', 'None', time()+0, '/' ); ?>
<?php
if (!function_exists("GetSQLValueString")) {
function GetSQLValueString($theValue, $theType, $theDefinedValue = "", $theNotDefinedValue = "")
{
if (PHP_VERSION < 6) {
$theValue = get_magic_quotes_gpc() ? stripslashes($theValue) : $theValue;
}
$theValue = function_exists("mysql_real_escape_string") ? mysql_real_escape_string($theValue) : mysql_escape_string($theValue);
switch ($theType) {
case "text":
$theValue = ($theValue != "") ? "'" . $theValue . "'" : "NULL";
break;
case "long":
case "int":
$theValue = ($theValue != "") ? intval($theValue) : "NULL";
break;
case "double":
$theValue = ($theValue != "") ? doubleval($theValue) : "NULL";
break;
case "date":
$theValue = ($theValue != "") ? "'" . $theValue . "'" : "NULL";
break;
case "defined":
$theValue = ($theValue != "") ? $theDefinedValue : $theNotDefinedValue;
break;
}
return $theValue;
}
}
$editFormAction = $_SERVER['PHP_SELF'];
if (isset($_SERVER['QUERY_STRING'])) {
$editFormAction .= "?" . htmlentities($_SERVER['QUERY_STRING']);
}
?>
<?php
mysql_select_db($database_StudentTrackerV, $StudentTrackerV);
$query_RecordsetBelz = "SELECT * FROM `asset tagged textbooks`";
$RecordsetBelz = mysql_query($query_RecordsetBelz, $StudentTrackerV) or die(mysql_error());
$row_RecordsetBelz = mysql_fetch_assoc($RecordsetBelz);
$colname_RecordsetBelz = "-1";
if (isset($_POST['AssetTagBelz'])) {
$colname_RecordsetBelz = $_POST['AssetTagBelz'];
}
mysql_select_db($database_StudentTrackerV, $StudentTrackerV);
$query_RecordsetBelz = sprintf("SELECT * FROM `asset tagged textbooks` WHERE `Asset Tag` = %s ORDER BY `Asset Tag` ASC", GetSQLValueString($colname_RecordsetBelz, "text"));
$RecordsetBelz = mysql_query($query_RecordsetBelz, $StudentTrackerV) or die(mysql_error());
$row_RecordsetBelz = mysql_fetch_assoc($RecordsetBelz);
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<title>Student Tracker Demo</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta http-equiv="Content-Style-Type" content="text/css" />
<link href="style.css" rel="stylesheet" type="text/css" />
<link href="layout.css" rel="stylesheet" type="text/css" />
<script src="js/jquery-1.4.2.min.js" type="text/javascript"></script>
<script src="js/bgstretcher.js" type="text/javascript"></script>
<script src="js/bg-init.js" type="text/javascript"></script>
<!--[if lt IE 7]>
<link href="ie_style.css" rel="stylesheet" type="text/css" />
<script type="text/javascript" src="js/ie_png.js"></script>
<script type="text/javascript">
ie_png.fix('.png');
</script>
<![endif]-->
<script type="text/javascript">
<!--
function MM_setTextOfTextfield(objId,x,newText) { //v9.0
with (document){ if (getElementById){
var obj = getElementById(objId);} if (obj) obj.value = newText;
}
}
//-->
</script>
</head>
<body id="page1">
<p> </p>
<div id="main">
<!-- header -->
<div id="header">
<div class="wrapper">
<div class="logo">
<h1><a href="index.html"><img src="/Logo.JPG" alt="" width="580" height="123" /></a></h1>
<h1><span>Academic Asset Management, Inc.</span> </h1>
</div>
<!-- .nav -->
<ul class="nav">
<li class="item1"><a href="index-1.html">Home</a></li>
<li class="item2"><a href="index-2.html">About us</a></li>
<li class="item3"><a href="index-3.html">services</a></li>
<!--<li class="item4"><a href="index-4.html">projects</a></li>-->
<li class="item5"><a href="index-5.html">contact</a></li>
</ul>
<!-- /.nav -->
</div>
</div>
<!-- content -->
<div id="content">
<div class="main-message">
<p> StudentTracker Demo </p>
<form id="form2" method="post" action="/STdemoCheckOut.php">
<p>
<label>
Teacher:
<select name="Teacher" id="Teacher2">
<option selected=""> </option>
<option>BELZ</option>
<option>KENT</option>
<option>MILLER</option>
<option>SWINDLE</option>
</select>
</label>
</p>
<p>Password:
<label>
<input type="text" name="Password" id="Password" />
</label>
</p>
<p>
<label>
<input name="CheckOut" type="submit" id="CheckOut" value="Check Out TextBooks" />
</label>
</p>
<p> </p>
</form>
<p>
<form id="form2" method="post" action="/STdemoCheckIn.php">
</form>
</p>
<p>.</p>
</div>
</div>
</div>
<!-- footer -->
<div id="footer">
<div class="container">
<div class="indent">
<div class="wrapper">
<div class="fleft">AAM © 2010</div>
<div class="fright"><a href="#" class="rss">RSS</a></div>
</div>
</div>
</div>
</div>
<script type="text/javascript">
<!--
var spryradio2 = new Spry.Widget.ValidationRadio("spryradio2");
var sprytextfield2 = new Spry.Widget.ValidationTextField("sprytextfield2", "none", {minChars:14, maxChars:14});
var spryradio3 = new Spry.Widget.ValidationRadio("spryradio3");
var sprytextfield3 = new Spry.Widget.ValidationTextField("sprytextfield3", "none", {minChars:14, maxChars:14});
var spryradio4 = new Spry.Widget.ValidationRadio("spryradio4");
var sprytextfield4 = new Spry.Widget.ValidationTextField("sprytextfield4", "none", {minChars:14, maxChars:14});
//-->
</script>
</body>
</html>
<?php
mysql_free_result($RecordsetBelz);
?>