The code of php is this:
Code: Select all
$connect_db 
$banco = mysql_select_db('$bd_name'); 
   
    $username= $_POST['username'];
    $q_user = mysql_query("SELECT * FROM info WHERE username='$username'");
 
    if(mysql_num_rows($q_user) == 1) {
   
        $query = mysql_query("SELECT * FROM info WHERE username='$username'");
        $dados = mysql_fetch_array($query);
        if($_POST['password'] == $dados['password']) {
            session_register("username");The code of tcl is this:
Code: Select all
bind msg - auth catch:info
proc catch:info {nick uhost hand arg} {
	set username [lindex [split $arg] 0]
	set password [lindex [split $arg] 1]
	set db [mysqlconnect -host www.lusopixel.com -user kwnds -password bmy-password -db kwnds]
	set resultado "SELECT * FROM info WHERE username='$username'"
	set linhas mysql_num_rows($resultado)
	if {$linhas == "0"} {
		putquick "privmsg $nick : Username wrong"
	} else {
		set resultado1 "select * from info where password = '$password'"
		set linhas1 mysql_num_rows($resultado1);
		if {$linhas1 == "0"} {
			putquick "privmsg $nick :Username wrong"
		} else {
			putquick "privmsg $nick :Username and Password correct"
		}
	}
}The hostname of my database is diferent of the hostname of my shell.
If someone want to try to fix this error, i give the information of the hosting of my database for he try to fix this on PM.
Thanks

 . But beware, PHP and eggdrop might not return the same md5 hash
. But beware, PHP and eggdrop might not return the same md5 hash