siehe user.php
[php]if ($_GET[op]=="search"){
$sql = "SELECT acctid FROM accounts WHERE ";
$where="
login LIKE '%{$_POST['q']}%' OR
acctid LIKE '%{$_POST['q']}%' OR
name LIKE '%{$_POST['q']}%' OR
emailaddress LIKE '%{$_POST['q']}%' OR
lastip LIKE '%{$_POST['q']}%' OR
uniqueid LIKE '%{$_POST['q']}%' OR
gentimecount LIKE '%{$_POST['q']}%' OR
level LIKE '%{$_POST['q']}%'";
$result = db_query($sql.$where);
if (db_num_rows($result)<=0){
output("`\$Keine Ergebnisse gefunden`0");
$_GET[op]="";
$where="";
}elseif (db_num_rows($result)>100){
output("`\$Zu viele Ergebnisse gefunden. Bitte Suche einengen.`0");
$_GET[op]="";
$where="";
}elseif (db_num_rows($result)==1){
//$row = db_fetch_assoc($result);
//redirect("user.php?op=edit&userid=$row[acctid]");
$_GET[op]="";
$_GET['page']=0;
}else{
$_GET[op]="";
$_GET['page']=0;
}
}[/php]
[php]output("<form action='user.php?op=search' method='POST'>Suche in allen Feldern: <input name='q' id='q'><input type='submit' class='button'></form>",true);
output("<script language='JavaScript'>document.getElementById('q').focus();</script>",true);
addnav("","user.php?op=search");
output("</form>",true);[/php]
|