I have already started to understand itself. But has faced a problem. I try to output contents of a cell of a database in the console of a server. But anything it is impossible to me here a code part which does not work:
DB
[IMG]http://img4.**************/img4/2429/97666737.jpg[/IMG]
PHP Code:
#define H_TABLE_UP "hmk_update"
#define H_TABLE_UPQ "huds"
...............
.............
....
PHP Code:
public update(){
if (dbc == SQL_FAILED) {
server_print("[HOMKA-update] not connect with db")
}
else {
server_print("[HOMKA-update] connect with db - OK !");
result = dbi_query(dbc,"SELECT value FROM `%s` WHERE type = `%s`",H_TABLE_UP,H_TABLE_UPQ);
new pr[32]
//SQL_ReadResult(result, 0, pr, 31)
dbi_result(result, "value", pr, 31) //line 96
server_print("resultat: %s", pr)
}
}
It writes a server to the console:
Code:
[HOMKA-update] connect with db - OK !
L 04/09/2009 - 17:35:51: [MySQL] Invalid DBI result handle -1
L 04/09/2009 - 17:35:51: [AMXX] Displaying debug trace (plugin "tak.amxx")
L 04/09/2009 - 17:35:51: [AMXX] Run time error 10: native error (native "dbi_result")
L 04/09/2009 - 17:35:51: [AMXX] [0] tak.sma::update (line 96)

Help me to output result in the server console