inFleet

(/rs/public/functions.access.php)

inFleet -- Check if member is in a fleet.

Description

bool inFleet ($fID, $pin = 0)

This function checks to see if a member is on the roster for a certain fleet. The fleet id is passed via the argument $fID and is mandatory.

$pin is optional and will default to the logged-in member (RSID) if it is set to 0, which is the default.

This function returns true if $pin (RSID if ! $pin) is found in fleet $fID. It returns false otherwise, including returning false on other failures.

Examples

inFleet (1) /* Check if the logged-in member is in fleet with id 1. */

inFleet (1, 2) /* Check is member with id 2 is in fleet with id 1. */

inFleet (1, 0) /* Check if the logged-in member is in fleet with id 1. */

Related Functions

None.

Dependencies

None.

Function Index