mysql listing
#10

im sorry im running late for school

Код:
CMD:banlist(playerid,params[])
{
	if(admin[playerid] < 2) return scm(playerid,0xFF0000FF,"Your not an admin.");
	new q[128],r;
	format(q,128,"SELECT * FROM ban");
	mysql_query(q);
	mysql_store_result();
	r=mysql_num_rows();
	for(new i=mysql_retrieve_row(1);i<r;i++)
	{
		new field[3][32],name[32],reason[64];
		mysql_fetch_row_format(q,"|");
		explode(q,field,"|");
	    new s[128];
	    format(reason,64,"%s",field[1]);
	    format(name,32,"%s",field[0]);
	    format(s,128,"%s - %s",name,reason);
	    scm(playerid,0xA9C4E4FF,s);
	}
	mysql_free_result();
	return 1;
}
thats how i did. mod it as u wish
Reply


Messages In This Thread
mysql listing - by BlackWolf120 - 08.09.2011, 01:41
Re: mysql listing - by JaTochNietDan - 08.09.2011, 01:43
Re: mysql listing - by BlackWolf120 - 08.09.2011, 01:49
Re: mysql listing - by JaTochNietDan - 08.09.2011, 01:58
Re: mysql listing - by BlackWolf120 - 08.09.2011, 02:04
Re: mysql listing - by JaTochNietDan - 08.09.2011, 02:14
Re: mysql listing - by BlackWolf120 - 08.09.2011, 02:22
Re: mysql listing - by THE_KNOWN - 08.09.2011, 02:39
Re: mysql listing - by BlackWolf120 - 08.09.2011, 02:44
Re: mysql listing - by THE_KNOWN - 08.09.2011, 02:47
[No subject] - by BlackWolf120 - 09.09.2011, 00:56
Re: mysql listing - by Alby Fire - 09.09.2011, 01:07
Re: mysql listing - by BlackWolf120 - 09.09.2011, 01:54
Re: mysql listing - by JaTochNietDan - 09.09.2011, 02:05

Forum Jump:


Users browsing this thread: 5 Guest(s)