Run php from command line in 32-bit mode
-
20-09-2019 - |
Question
Is it possible to tell php to run a script from the command line in 32-bit mode? I have a php script that uses an ODBC driver that is only works when PHP is run in 32-bit. Here is how I'm calling the script:
php -d safe_mode=0 -f checkImport.php
Any ideas?
Solution
You can't. The PHP interpreter is compiled either as 64-bit or as 32-bit. What you can do is compile or install a separate 32-bit edition of PHP on your system. How to do this is very platform specific.
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow