【发布时间】:2016-11-04 08:10:18
【问题描述】:
我有一个使用 SSL 的 wordpress 项目,我想在 XAMPP 上运行它。
我修改了我的 httpd-vhosts.conf 和我的 httpd-ssl.conf 来为这个特定的 wordpress 项目创建一个虚拟主机。
这是我的 httpd-vhosts.conf 文件内容
<VirtualHost *:443>
DocumentRoot "D:/xampp/htdocs/wordpresssoftd"
ServerName mysite.local
ServerAlias mysite.local
SSLEngine on
SSLCertificateFile conf/ssl.crt/server.crt
SSLCertificateKeyFile conf/ssl.key/server.key
<Directory "D:/xampp/htdocs/wordpresssoftd">
AllowOverride All
Order allow,deny
Allow from all
</Directory>
</VirtualHost>
wordpresssoftd 包含我的项目文件。
我还重命名了 httpd-ssl.conf 中的文档根目录。
当我运行网站时,没有加载 CSS 和 JS 文件,但是 wordpress 网站的索引页面提供了没有 CSS 和 JS。
我已经检查了这些链接无济于事
Setting up SSL on a local xampp/apache server
How do I use https (SSL) in XAMPP while using virtual hosts
http://www.leonardaustin.com/blog/technical/how-to-enable-ssl-on-xampp-with-vhosts/
https://jaswanttak.wordpress.com/2010/04/15/configure-ssl-on-xampp-and-windows/
【问题讨论】: