Add a local PHP configuration example
Question
Could you add an example of how to configure now-php to work with now dev? On this page it says "check that PHP executable is added to the PATH environment variable". I'm guessing this means create a .env file and put something like PATH=/usr/local/Cellar/[email protected]/7.3.15/bin/php in it. Is that right? I tried that and also tried using the path from my .bash_profile, with no luck.
Hi, I prefer starting php app via php -S localhost:8000 (php development server).
Ahh OK, thanks. You do that from the api folder?
(I think that needs to be a capital S btw php -S localhost:8000)
Yup, I was on mobile. xD
php -S localhost:8000 api/index.php (or any other php file).
Using this server, rather than now dev means everything is expected to be inside the api directory, right? If index.php is referencing a CSS file for example. How would you deal with that?
Well, it starts full webserver. All assets are handled properly.
Could you show me your project? It might help.