studio
studio copied to clipboard
Feature Request: Allow selecting the PHP version
What
Add an option to select what PHP version to use.
Why
Being able to select a PHP version is essential for development and troubleshooting.
How
We could add this as an option under "Settings":
I was looking for this exact feature, then I find out it doesn't exist yet. Let's hope we could get it done eventually.
I have PHP 8.3.x installed on my mac. The studio thinks I'm running 8.0 and the plugin I'm developing requires at least 8.1. I've tried putting a php.ini file in wp-admin folder but no joy. How can I direct the Studio version of Wordpress to use the version installed on my machine?
How can I direct the Studio version of Wordpress to use the version installed on my machine?
Currently, there is no way to direct Studio to use the PHP version installed on the machine. We may add the ability to select the version that should be used for each site at some point, though.
I look forward to have this functionality, and as the matter of fact I could even try to contribute to its development but I couldn't find any reference to this feature or how this php server works inside the project to try implement it on my end and if I make it work, create a fork to send you a PR with that.
Anyway, thank you so much.
Nice! Thank you :-)
On May 29, 2024 at 12:51 PM, <Jenny Martinez @.***)> wrote:
I look forward to have this functionality, and as the matter of fact I could even try to contribute to its development but I couldn't find any reference to this feature or how this php server works inside the project to try implement it on my end and if I make it work, create a fork to send you a PR with that.
Anyway, thank you so much.
— Reply to this email directly, view it on GitHub (https://github.com/Automattic/studio/issues/32#issuecomment-2137860116), or unsubscribe (https://github.com/notifications/unsubscribe-auth/BDAY5IU2N5NYW3IQTVOE6HTZEYBRBAVCNFSM6AAAAABGYZK76GVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDCMZXHA3DAMJRGY). You are receiving this because you commented.Message ID: @.***>
Well, after the announcement of this platform to work locally, and using it I have had very good feelings, but I just found myself with this limitation and I have to say that while it is not active, I will continue working with other more mature options that do have it implemented . I hope it is resolved soon so we can continue testing this promising local development option.
I started working on this with https://github.com/Automattic/studio/pull/225
We should change the default PHP version too. PHP 8.1 or PHP 8.2?
Hey @danielbachhuber in my opinion I would rather to have the 8.2 that’s going to give us a bigger gap to test and work with the newer plugins and themes versions and possibly some window between having this fixed version while a version switch is being implemented.
Thanks a lot.
PS. Is there a way to know how is PHP implemented in this project? Or at least point us to the source files that are being used to implement it? It’s for a homework… Hahaha just kidding I’d love to collaborate in near future. 🥰
@lajennylove Makes sense, thanks for the input
PS. Is there a way to know how is PHP implemented in this project? Or at least point us to the source files that are being used to implement it? It’s for a homework… Hahaha just kidding I’d love to collaborate in near future.
It's using PHP as a WebAssembly binary, more information here: https://web.dev/articles/wordpress-playground#php_runs_as_a_webassembly_binary
@adamziel has talked about WordPress Playground a few times, but I don't know that he's ever explained how PHP and WebAssembly actually work.
Do you have specific questions?
Do you have specific questions?
Not really, I just wanted to have a hint of where to look if I ever wanted to collaborate on this matter.
I think it could be great to be a maintainer.
Anyway, thank you so much for taking your time to answer me back.
We can consider this issue closed as a PHP selector was incorporated in https://github.com/Automattic/studio/pull/225.
Amazing! Thank you so much @fluiddot