summaryrefslogtreecommitdiffstats
path: root/For Weekly Test
diff options
context:
space:
mode:
authorTriatmoko2011-10-26 01:33:32 +0200
committerTriatmoko2011-10-26 01:33:32 +0200
commit3c713429e4825e3c5acc289e44f7d47c06c9ba07 (patch)
treee34ef138b4760267efdac5abecf76e201cacf194 /For Weekly Test
parentupdate device manual (diff)
downloadgsm-selftest-3c713429e4825e3c5acc289e44f7d47c06c9ba07.tar.gz
gsm-selftest-3c713429e4825e3c5acc289e44f7d47c06c9ba07.tar.xz
gsm-selftest-3c713429e4825e3c5acc289e44f7d47c06c9ba07.zip
update devices
Diffstat (limited to 'For Weekly Test')
-rw-r--r--For Weekly Test/tricode/devconfigManual.php79
-rw-r--r--For Weekly Test/tricode/insertdevice.php21
-rw-r--r--For Weekly Test/tricode/main.php36
3 files changed, 136 insertions, 0 deletions
diff --git a/For Weekly Test/tricode/devconfigManual.php b/For Weekly Test/tricode/devconfigManual.php
new file mode 100644
index 0000000..e12ebd8
--- /dev/null
+++ b/For Weekly Test/tricode/devconfigManual.php
@@ -0,0 +1,79 @@
+<?php
+
+$db = mysql_connect("localhost","root","randompasswordSQL");
+mysql_select_db("gsmselftesting",$db);
+?>
+
+<html>
+
+<head>
+ <title>GSM selftest Software</title>
+ <meta name="generator" content="BBEdit 9.6" />
+ <link rel="stylesheet" href="css/tooltip.css" type="text/css" media="screen">
+</head>
+
+<body background="Images/BackGround.jpg">
+<?php
+$message='';
+if (isset($_REQUEST['Submit']))
+ {
+ $sql="UPDATE DeviceAddressTable SET portName = '$_POST[portname]', number = '$_POST[number]' WHERE deviceName = '$_POST[device]'";
+ if($result = mysql_query($sql ,$db))
+ {
+ $message = '<font size="3" face="Century Gothic" color="LightGray"> UPDATE Device Succeed</font>';
+ }
+ else
+ {
+ echo "ERROR: ".mysql_error();
+ }
+ }
+else {
+?>
+<!--<FORM name="testForm" form action="devconf.php" method="POST">-->
+ <table style="width:50%; margin:auto" border="0">
+ <tr>
+ <td height="100px" align="center"><a href="home.html" STYLE="TEXT-DECORATION: NONE"><font size="3" face="Century Gothic" color="LightGray">HOME</font></a></td>
+ <td height="100px" align="center"><a href="Blank.html" STYLE="TEXT-DECORATION: NONE"><font size="3" face="Century Gothic" color="LightGray">About Us</font></a></td>
+ <td height="100px" align="center"><font size="3" face="Century Gothic" color="LightGray">Help</font></td>
+ </tr>
+
+ <tr>
+
+ <td height="45px" align="right">
+ <a href="devconfigAuto.php" STYLE="TEXT-DECORATION: NONE"> <img src="Images/AutoIcon.png"></img></a>
+ </td>
+ <td>
+ </td>
+ <td height="45px" align="left">
+ <a href="devconfigManual.php" STYLE="TEXT-DECORATION: NONE"> <img src="Images/ManualIcon.png"></img></a>
+
+ </td>
+
+ </tr>
+ <tr height="50px">
+ </tr>
+ <!--</FORM>-->
+ <tr>
+ <?php include("main.php"); ?>
+ </tr>
+
+ <tr>
+ <td height="200px" align="center"></td>
+ <td height="200px" align="center"><?php $message ?></td>
+ <td height="200px" align="center"></td>
+ </tr>
+
+ <tr>
+ <table style="width:100%; margin-top: -10px; height: 300px; align: center" valign="bottom" border="0">
+ <tr>
+ <td height="100px" align="center" valign="bottom"><font size="1" face="Century Gothic" color="LightGray">Albert-Ludwig University of Freiburg 2011</td>
+ </tr>
+ </table>
+ </tr>
+ </table>
+<?php
+}
+?>
+
+</body>
+</html>
diff --git a/For Weekly Test/tricode/insertdevice.php b/For Weekly Test/tricode/insertdevice.php
new file mode 100644
index 0000000..b3f7350
--- /dev/null
+++ b/For Weekly Test/tricode/insertdevice.php
@@ -0,0 +1,21 @@
+<?php
+$con = mysql_connect("localhost","root","randompasswordSQL");
+if (!$con)
+ {
+ die('Could not connect: ' . mysql_error());
+ }
+
+mysql_select_db("gsmselftesting", $con);
+$sql="UPDATE DeviceAddressTable SET portName = '$_POST[portname]', number = '$_POST[number]' WHERE deviceName = '$_POST[device]'";
+
+
+if (!mysql_query($sql,$con))
+ {
+ die('Error: ' . mysql_error());
+ }
+else
+{
+echo "1 record added";
+}
+mysql_close($con)
+?> \ No newline at end of file
diff --git a/For Weekly Test/tricode/main.php b/For Weekly Test/tricode/main.php
new file mode 100644
index 0000000..60cef31
--- /dev/null
+++ b/For Weekly Test/tricode/main.php
@@ -0,0 +1,36 @@
+ <table style="width:50%; margin:auto" border="0">
+ <tr>
+ <td height="100px" width ="120px" align="left">
+ <font size="3" face="Century Gothic" color="LightGray">
+ <form action="" method="POST">
+ <input type="radio" name="device" value="GSMRZ1" /> RZ GSM 1<br>
+ <input type="radio" name="device" value="GSMext.Eplus" /> E-Plus<br>
+ <input type="radio" name="device" value="GSMext.O2" /> O2<br>
+ <input type="radio" name="device" value="GSMext.Voda" /> Vodaphone<br>
+ <input type="radio" name="device" value="GSMext.Tm" /> T-Mobile<br>
+
+ </font>
+ </td>
+ <td height="100px" width ="100px" align="left">
+ <font size="3" face="Century Gothic" color="LightGray">
+ Port Number<br>
+ IMEI<br>
+ Number<br>
+ </font>
+ </td>
+ <td height="100px" width ="90px" align="left">
+ <font size="3" face="Century Gothic" color="LightGray">
+ : <input type="text" name="portname" /></br>
+ : <input type="text" name="imei" /><br>
+ : <input type="text" name="number" /><br>
+ </font>
+ </td>
+ <td height="100px" width ="50px" align="left">
+ <font size="3" face="Century Gothic" color="LightGray">
+ <INPUT type="image" value="submit" name="submit" src="Images/SubmitButton.png"><br />
+ </font>
+ </td>
+
+ </form>
+ </tr>
+ </table>