STRING_REGEXP_FRACTION
STRING_REGEXP_FRACTION = '(-?)(\\d+)\\s+(\\d+\\/\\d+)'
Regular Expressions
$controlCharacters : string[]
Control characters array.
$SYLKCharacters : array
SYLK Characters array.
$decimalSeparator : string
Decimal separator.
$thousandsSeparator : string
Thousands separator.
$currencyCode : string
Currency code.
$isIconvEnabled : bool
Is iconv extension avalable?
$iconvOptions : string
iconv options.
controlCharacterOOXML2PHP(string $value) : string
Convert from OpenXML escaped control character to PHP control character.
That's correct, control characters are stored directly in the shared-strings table.
We do encode characters that cannot be represented in XML using the following escape sequence:
xHHHH where H represents a hexadecimal character in the character's value...
So you could end up with something like x0008 in a string (either in a cell value (
string | $value | Value to unescape |
controlCharacterPHP2OOXML(string $value) : string
Convert from PHP control character to OpenXML escaped control character.
That's correct, control characters are stored directly in the shared-strings table.
We do encode characters that cannot be represented in XML using the following escape sequence:
xHHHH where H represents a hexadecimal character in the character's value...
So you could end up with something like x0008 in a string (either in a cell value (
string | $value | Value to escape |
UTF8toBIFF8UnicodeShort(string $value, array $arrcRuns = []) : string
Converts a UTF-8 string into BIFF8 Unicode string data (8-bit string length) Writes the string using uncompressed notation, no rich text, no Asian phonetics If mbstring extension is not available, ASCII is assumed, and compressed notation is used although this will give wrong results for non-ASCII strings see OpenOffice.org's Documentation of the Microsoft Excel File Format, sect. 2.5.3.
string | $value | UTF-8 encoded string |
array | $arrcRuns | Details of rich text runs in $value |
UTF8toBIFF8UnicodeLong(string $value) : string
Converts a UTF-8 string into BIFF8 Unicode string data (16-bit string length) Writes the string using uncompressed notation, no rich text, no Asian phonetics If mbstring extension is not available, ASCII is assumed, and compressed notation is used although this will give wrong results for non-ASCII strings see OpenOffice.org's Documentation of the Microsoft Excel File Format, sect. 2.5.3.
string | $value | UTF-8 encoded string |
setThousandsSeparator(string $pValue) : void
Set the thousands separator. Only used by NumberFormat::toFormattedString() to format output by \PhpOffice\PhpSpreadsheet\Writer\Html and \PhpOffice\PhpSpreadsheet\Writer\Pdf.
string | $pValue | Character for thousands separator |
testStringAsNumeric(string $value) : mixed
Retrieve any leading numeric part of a string, or return the full string if no leading numeric (handles basic integer or float, but not exponent or non decimal).
string | $value |
string or only the leading numeric part of the string