[EDIT by nielsdos: This is no longer true as of PHP 8.4.0]
The parameter will not be set if the value contains both single and double quotes. Instead a warning will be shown when transforming the document:
PHP Warning: XSLTProcessor::transformToXml(): Cannot create XPath expression (string contains both quote and double-quotes)