« Back to Product

Documentation

IPS_FindServerID

 int IPS_FindServerID (int $ObjectID) 

Parameters

ObjectID

ID of the object on the local system

Returns

ID of the Sync Remote instance which mirrors the object. If no mapping exists, 1 is returned.

Description

Warning

This function is intended for internal use only and may change or be removed at any time without notice.

The function reads the mapping of object IDs between the local system and remote systems which are mirrored by Sync Remote instances (see Sync Remote). It determines the ID of the Sync Remote instance which mirrors the object ObjectID. If ObjectID is not a mirrored object, the function returns 1.

Example

// Determine the Sync Remote instance of a mirrored object
$serverID = IPS_FindServerID(12345);
if ($serverID == 1) {
    echo "The object is not mirrored";
} else {
    echo "Sync Remote instance: " . IPS_GetName($serverID);
}
Any questions?