One of the best on Windows Server 2022 is a web platform installer (WPI), using this you can install PHP with Internet Information Services (IIS). However, there are other methods to install PHP on your Windows Server 2022 but in this article, BKNS will use WPI to do it as it takes significantly less time than its alternatives. it.
In this article, we will guide you through the installation process PHP on your system using IIS.
In your Windows Server 2022, open Dashboard.
In Programs and Features, you will see Turn Windows Features on or off , click it.
A pop-up window will open.
The Add Roles and Features Wizard will launch with the “Before you begin”.
Select option "Skip this page by default” to skip in the future.
Continue by pressing “Next“.
Select the radio button “Role-based or feature-based installation” since running the PHP code
on your Windows 2022 server in a role-based installation.
You will see in the image below that IIS is installed in our system.
However, in your case you need to select Server CGI in Role services.
Click Web Server (IIS) then come Web Server and then Application development.
Check the box next to CGI , if it hasn't already.
Click ” Next ", in Features.
In the window Confirmation, click Install node to install CGI in IIS.
Now download WebPI using this link and then install it, depending on your system bit. Here!
Now Install WebPlatformInstaller_x64_en-US.msi that we have downloaded.
After installation you can see Microsoft Web Platform Installer in the start menu. Open it.
- The Web Platform Installer window opens.
Go to section Products and find php.
13. Find PHP 8.0.0 (x64) or anything above it then click the . button Add next to it.
And then click the button Install and agree to the terms to install PHP.
However, you will have to remember that this can lead to the installation of components that you did not select . And all of you may see failed installation message PHP Manager for IIS but you can still use text editor and command line to make changes in configuration.
You can also check the PHP settings. Use the following code to create a test file:
< ? php phpinfo () ; ? >
I created a file called phpinfo.php to test PHP.
Now open your browser and run this file through it. Eg : http: //localhost/phpinfo.php or your serverip/phpinfo.php.
You should see something like or similar to this if the installation was successful:
And that's all. You have successfully installed PHP in your Windows Server 2022. Now you can go ahead and use to install applications like WordPress, Joomla… Good luck!
Explore more:
Post a Comment
Post a Comment