protected function convertStaticPhpExcelConstantsFromStringsToConstants($value)
    {
        if (strpos($value, 'PHPExcel_') === 0) {
            $parts = explode('::', $value);
            $class = new \ReflectionClass($parts[0]);
            $value = $class->getConstant($parts[1]);
        }

        return $value;
    }
protected function convertStaticPhpExcelConstantsFromStringsToConstants($value)
    {
        if (strpos($value, 'PHPExcel_') === 0) {
            $parts = explode('::', $value);
            $class = new \ReflectionClass($parts[0]);
            $value = $class->getConstant($parts[1]);
        }

        return $value;
    }
protected function convertStaticPhpExcelConstantsFromStringsToConstants ( $ value ) { if ( strpos ( $ value , 'PHPExcel_' ) === 0 ) { $ parts = explode ( '::' , $ value ) ; $ class = new \ ReflectionClass ( $ parts [ 0 ] ) ; $ value = $ class -> getConstant ( $ parts [ 1 ] ) ; } return $ value ; }
Turn PHPExcel constants into actual constants

Example:
If the html element contains a _excel-styles attribute with the json-encoded version of the array below,
the value PHPExcel_Style_Fill::FILL_SOLID would be treated as a string.
We need to treat it as a static class constant and also apply the correct namespace.

array (
'fill' => array (
'type' => 'PHPExcel_Style_Fill::FILL_SOLID',
'color' => array (
'rgb' => '4F4F4F',
),
),
)

@param string $value
@return string
Turn PHPExcel constants into actual constants