bind msg - !invite invite

proc invite {nick host hand arg} {
sql selectdb pre
set user [join [sql "SELECT user,pass FROM logins WHERE pass='$pass'"]]
set word [lindex [split $arg] 0]
set pass [lindex [split $arg] 1]
if {[string equal "" $pass]} {
	putquick "PRIVMSG $nick :4\[ERROR4\] Did not receive a pass"
	return
	}
if {[string equal [lindex $user 0] $word] && [string equal [lindex $user 1] $pass]} {	
	putquick "PRIVMSG #headoffice :login from-$word passwd-$pass"
	} else {
	putquick "PRIVMSG $nick :login failed.."
	return
	}
}