get ban list
Re: get ban list
Hi,
you can use this:
Cheers
you can use this:
Code: Select all
List<BannedUser> banList = SmartFoxServer.getInstance().getBanList()
Cheers
Re: get ban list
hi
i mean something like that
https://www.smartfoxserver.com/docs/1x/ ... /index.htm
Something I can write inside the extension
i mean something like that
https://www.smartfoxserver.com/docs/1x/ ... /index.htm
Something I can write inside the extension
Re: get ban list
Ok. Well the code above is valid for a Java extension
In Javascript it translates to:
Each item in the list is a Java class (BannedUser) with the following methods:
Hope it helps
In Javascript it translates to:
Code: Select all
var banList = _server.getBanList()
Each item in the list is a Java class (BannedUser) with the following methods:
- getName()
getIp()
getBanDate() (in Unix time format)
Hope it helps
Re: get ban list
Code: Select all
16:18:19.885 - [ WARNING ] > Error in extension [ admin.as ]: TypeError: Cannot find function getBanList. (admin.as#1627) Internal: 50 -- Line number: 49 in file: admin.as
It seems that the Fincation does not exist
Re: get ban list
You're right, this is not accessible via javascript, only Java.
Sorry for the inconvenience. Haven't used SFS PRO in a long time.
Sorry for the inconvenience. Haven't used SFS PRO in a long time.
Re: get ban list
np .thanks for your time
I will create a new table in the database for banned people
I will create a new table in the database for banned people
Re: get ban list
Before you do that, try this instead:
the _server.instance object points to the actual Java class that exposes the method.
Cheers
Code: Select all
var bannedUsers = _server.instance.getBanList()
the _server.instance object points to the actual Java class that exposes the method.
Cheers
Return to “SmartFoxServer 1.x Discussions and Help”
Who is online
Users browsing this forum: No registered users and 78 guests