Moving from Windows php to Linux

I am a newbie to linux. I have a website built on windows php. What needs to be changed in my files to make it compatible with apache?

Show comments

Submit an answer

This textbox defaults to using Markdown to format your answer.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

Sign In or Sign Up to Answer

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Want to learn more? Join the DigitalOcean Community!

Join our DigitalOcean community of over a million developers for free! Get help and share knowledge in Q&A, subscribe to topics of interest, and get courses and tools that will help you grow as a developer and scale your project or business.

In most cases you should not have to change anything. There are a few Windows/Linux specific things that can be done in php but for the most part everything should work. To import your php app you will want to:

1.) Create a new droplet. I would recommend the LAMP Application image as this will provide you with a ready to use server environment with php.

2.) Upload your files using SFTP to the /var/www/html directory

3.) Navigate to your droplet by IP (or domain if you have configured one) in a browser and test your script.

Of course if your app includes a database there will be additional steps to import your data.