How to activate php_xsl.dll module?
Hello,
I use a composer module in my Symfony 6 app that require php_xsl.dll lib (InkyExtension for email templating)
So I activated it in my .platform.app.yaml
type: php:8.1
runtime:
extensions:
- xsl
Though I got the following error when running my app on production :
PHP Warning: PHP Startup: Unable to load dynamic library 'php_xsl.dll' (tried: /usr/lib/php/20210902-zts/php_xsl.dll (/usr/lib/php/20210902-zts/php_xsl.dll: cannot open shared object file: No such file or directory), /usr/lib/php/20210902-zts/php_xsl.dll.so (/usr/lib/php/20210902-zts/php_xsl.dll.so: cannot open shared object file: No such file or directory)) in Unknown on line 0
Checked if the module was correctly enabled using symfony ssh 'php -m' and it is in the list
Should I install it as a custom extension as explained here https://docs.platform.sh/languages/php/extensions.html#custom-php-extensions ?
Thank you!
Comments
It looks like you’ve probably committed a
php.inifile at the root of your app. That file is probably pointing tophp_xsl.dll. This tells Platform.sh to load yourphp.inifile and all of the settings in it.Platform.sh doesn’t use DLL files, and if it did it would probably live a different path than your local machine anyway. Since you have taken the appropriate step of enabling the XSL extension via the
platform.app.yaml, here’s what I’d do next.php --iniphp_xsl.dllreference there.php_xsl.dllreference form the INI file that you are committing to your project.Once you have removed the DLL reference from your projects customs php.ini file, you should be able to commit it and run without issue on Platform.sh
Hello @TylerMills ,
Thanks for your answer.
Indeed, I have committed a
php.inifile to my project, but this one does not contain any reference tophp_xsl.dllHere it is :
So I actually have no idea where does this
dllpath come from. Maybe from the composer module ?It is not a path from my local environment.
The reason I wanted to activate
xlsis because I had the following error withcomposerduring deployment :PS: I tried to run
composer updateas suggested, but it didn’t help, still had the same errorOk, the issue is fixed now.
I think that I actually misinterpreted the logs, because I first tried to set it up through php.ini, indeed.
I got another error without logs, and I thought it was related, but it seems it is not!
Anyway, thanks a lot for your help !
Nice! Just create another post or support ticket if you need help with anything else.
Please sign in to leave a comment.