Permalink
Browse files

Fixes to web interface... hopefully solving issue #21..

  • Loading branch information...
1 parent b673026 commit 822e4df2b991aaba28ea678650751e29e76e31f8 @MrMEEE committed Aug 27, 2011
Showing with 2 additions and 17 deletions.
  1. +2 −17 web/index.php
View
@@ -21,22 +21,7 @@
WHERE Manufacturer="%s" AND Model="%s" AND `nVidia Startup`="%s" AND `nVidia Shutdown`="%s"',
mysql_real_escape_string($manufacturer), mysql_real_escape_string($model),
mysql_real_escape_string($start), mysql_real_escape_string($shutdown));
- $query = mysql_query($sql);
-
- if($manufacturer!=""&&$model!=""&&$monitor!=""&&$nvidiabusid!=""&&$dmiproduct!=""&&
- $user!=""&&$monitor!="REPLACEWITHCONNECTEDMONITOR"&&$model!='$MODEL'){
- $sql = sprintf('INSERT into confirmed(Manufacturer, Model, `nVidia BusID`, `nVidia Startup`,
- `nVidia Shutdown`, `Confirming User`, `Users Confirming`, Distribution) VALUES
- ("%s", "%s", "%s", "%s", "%s", "%s", "%s", "%s")',
- mysql_real_escape_string($manufacturer), mysql_real_escape_string($model),
- mysql_real_escape_string($monitor), mysql_real_escape_string($intelbusid),
- mysql_real_escape_string($nvidiabusid), mysql_real_escape_string($start),
- mysql_real_escape_string($shutdown), mysql_real_escape_string($dmiproduct),
- mysql_real_escape_string($user), mysql_real_escape_string($distro)
- );
- mysql_query($sql);
- echo "System Added";
- }
+ $query = mysql_query($sql);
$row = mysql_fetch_assoc($query);
if($row['Manufacturer'] == $manufacturer){
$id = $row['id'];
@@ -47,7 +32,7 @@
echo "System Added to already existing profile";
}
else{
- if($manufacturer!=""&&$model!=""&&$user!=""&&$user!=$row['Confirming User']){
+ if($manufacturer!=""&&$model!=""&&$user!=""){ // &&$user!=$row['Confirming User']
$sql = sprintf('INSERT into confirmed (Manufacturer, Model, `nVidia Startup`,
`nVidia Shutdown`, `Submitting User`, `Users Confirming`, Distribution) VALUES
("%s", "%s", "%s", "%s", "%s", 1, "%s")',

0 comments on commit 822e4df

Please sign in to comment.