Author Topic: Checking if a function exists  (Read 792 times)

How do I check from the server side if a function exists.

bool isFunction(str function)

Returns true if function exists, false otherwise.

Example

==>echo(isFunction("echo"));
1
==>echo(isFunction("lobster_thermidor_aux_crevett es_with_a_mornay_sauce_garnis hed_with_truffle_pate_brandy_ and_a_fried_egg_on_top_and_sp am"));
0

bool isFunction(str function)

Returns true if function exists, false otherwise.

Example

==>echo(isFunction("echo"));
1
==>echo(isFunction("lobster_thermidor_aux_crevett es_with_a_mornay_sauce_garnis hed_with_truffle_pate_brandy_ and_a_fried_egg_on_top_and_sp am"));
0


stop making me hungry port

Unlocked due to several messages requesting that I leave them open

Unlocked due to several messages requesting that I leave them open
Always leave them open..

Anyway, if you want to check for a class function, here is an example:
==>echo(isFunction("Player","kill"));
1