How do I use https (SSL) in XAMPP while using virtual hosts

后端 未结 4 1607
清酒与你
清酒与你 2020-12-02 05:45

I am writing a php app on my local machine and would like to test to see if SSL is working. Bear with me because this is the first time I\'ve ever used SSL.

So far t

4条回答
  •  轻奢々
    轻奢々 (楼主)
    2020-12-02 06:22

    Here is simple step.

    1. Go to C:\xampp\apache\conf

    Open httpd.conf

    And enable the ssl extensions (Remove # from line)

    LoadModule ssl_module modules/mod_ssl.so

    1. Go to C:\xampp\apache\conf\extra

    Open httpd-vhosts.conf

    Add new virtual hosts or edit existing

       
    	DocumentRoot "C:/xampp/htdocs/PROJECTNAME" 
    	ServerName www.pl.f24sdev.com
    	
    		AllowOverride All
    		Order Deny,Allow   
    		Allow from all  
    	
    	SSLEngine on
    	SSLCertificateFile "conf/ssl.crt/server.crt"
    	SSLCertificateKeyFile "conf/ssl.key/server.key"   
    

提交回复
热议问题