MovieData::matchRegex PHP Method

matchRegex() private method

private matchRegex ( $strContent, $strRegex, $intIndex = null )
    private function matchRegex($strContent, $strRegex, $intIndex = null)
    {
        preg_match_all($strRegex, $strContent, $arrMatches);
        if ($arrMatches === FALSE) {
            return false;
        }
        if ($intIndex != null && is_int($intIndex)) {
            if ($arrMatches[$intIndex]) {
                return $arrMatches[$intIndex][0];
            }
            return false;
        }
        return $arrMatches;
    }