How to add php file to local by flywheel for testing>

Hi all,

I am working on some php files and would like to use Local by flywheel as my local hosting to test out my code. can we do that? usually we create a whole wordpress site inside local by flywheel instead of a single php file. Do you guys know where to put my php files and how to test it out? thanks.

1 Like

Hey @ernest, Welcome to the Local community!

Local is specifically designed to work with WordPress, so this might not be the best environment to test on.
However, this is totally possible! If you right-click on the site name in Local and choose “Reveal in Finder”.
That will take you to the site files and logs. From there go to app->public, and you will see the WordPress install.

Place your PHP files in that directory and you can run and test your PHP code or even delete the WordPress install altogether. Just note that removing the WordPress files might break some of the Locals features.

Hello, @jkiley!! I am having a problem and I can’t figure out what is wrong with it. I’ve been trying for two days. When I try to view the php document I saved in the public folder online on my local site, for instance, " my-fictional-site.local/ " and then add “experiment.php” which is the name of the document, this message keeps coming to me: There are no results for this. Try using different keywords. What am I doing wrong??? I am working on windows 10. Please help…really frustrated. Thank you!

1 Like