$Test = new XQL("xim.ini");
$Test->Query("GET `Username`"); // This returns Xim
$Test->Query("SET `Username` TO 'X1M!'"); // This returns X1M! and changes the Username key from Xim to X1M!
function Query($Query)
{
$Qry = Explode(" ", $Query);
Switch(strtoupper($Qry[0])) {
Default:
Return 0;
Break;
Case "GET":
If(isset($Qry[1])):
return $this->getKey(str_replace("`", "", $Qry[1]), (isset($Qry[4]) && $Qry[4] == "INT()")?1:0);
Else:
return 0;
EndIf;
Break;
Case "SET":
If(isset($Qry[1]) && isset($Qry[3])):
$this->setKey(str_replace("`", "", $Qry[1]), str_replace("'", "", $Qry[3]), (isset($Qry[4]) && $Qry[4] == "INT()")?1:0);
return 1;
Else:
Return 0;
EndIf;
Break;
}
}