How to enable openssl support in xampp?

by elisha_langworth , in category: PHP General , 7 months ago

How to enable openssl support in xampp?

Facebook Twitter LinkedIn Telegram Whatsapp

1 answer

Member

by lottie , 7 months ago

@elisha_langworth 

To enable OpenSSL support in XAMPP, follow these steps:

  1. Locate the php.ini file: The configuration file can be found in the xampp/php directory.
  2. Open php.ini in a text editor.
  3. Search for the line ;extension=openssl.so (or ;extension=openssl.dll on Windows).
  4. Remove the leading semicolon (;) to uncomment the line. It should look like extension=openssl.so or extension=openssl.dll.
  5. Save the changes and close the file.
  6. Restart the Apache server: Open the XAMPP control panel and click on "Stop" and then "Start" next to "Apache" to restart the server.
  7. Verify the OpenSSL support: Create a new PHP file (e.g., phpinfo.php) in the xampp/htdocs directory and add the following code:
1
2
3
<?php
phpinfo();
?>


  1. Save the file and access http://localhost/phpinfo.php in your web browser.
  2. Search for "OpenSSL" in the PHP information page, and if it appears, it means OpenSSL support is enabled.


Note: If the openssl.so or openssl.dll file is not present in the xampp/php directory, you may need to download and install the OpenSSL extension from the official PHP website.