fleetMemberPins

(/rs/public/functions.php)

fleetMemberPins -- Array containing pins of members in a fleet.

Description

array fleetMemberPins ($fleetID, $officers = "all", $includeCadets = false)

This function will return an array containing the pins of all members in the specified fleet.

$fleetID is the id of the fleet in the database.

$officers can be "all" or "only". "all" is the default value and returns everyone in the fleet, officers and non-officers. If "only" is passed, only fleet, wing, and squadron officers (CO, XO, SO, IO, TCO, and TXO) will be returned. "only" will override any value set for $includeCadets.

$includeCadets is a boolean which defaults to false. If it is set to true, cadets are included when returning members.

This function will return an empty array on failure.

Examples

fleetMemberPins (1) /* Returns the pins of all members in fleet with id 1, not including cadets. */

fleetMemberPins (1, "only") /* Returns all the fleet, wing, and squadron officers in fleet with id 1. Cadets are included if the cadet is an officer. */

fleetMemberPins (1, "all", true) /* Returns the pins of all members in fleet with id 1, including cadets. */

fleetMemberPins () /* Returns an empty array */

Related Functions

wingMemberPins, squadMemberPins

Dependencies

wingMemberPins, absArray

Function Index