Locale tag should be placed just before the extension of the file. For
example, filename bar.png can be localized as bar.en_GB.png,
and this method extracts en_GB from the name.
Note: this ignores matches on rss, xml and php and validates the identifier.
public static extractLocaleTagFromFilename ( string $filename ) : mixed | ||
$filename | string | Filename to extract locale identifier from |
return | mixed | The string with extracted locale identifier of FALSE on failure |