Apache Setup Mac后LocalHost Wordpress网站无法加载CSS [英] LocalHost Wordpress sites not loading css after Apache Setup Mac

查看:88
本文介绍了Apache Setup Mac后LocalHost Wordpress网站无法加载CSS的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

升级到High Sierra后,我的本地主机不再工作.我遵循了许多教程,最后使它起作用,但是现在我的Wordpress网站可以加载,但不能加载CSS和Javascript文件.当我检查检查器时,它表明由于目录错误而无法加载文件.地址栏显示localhost/Site-Name,但是文件正试图从localhost/〜paul/Site-Name加载,因此我必须以某种方式弄乱了配置.希望有人可以提供帮助.谢谢

After Upgrading to High Sierra my localhost no longer worked. I followed a number of tutorials and finally got it to work but now my Wordpress sites load but do not load the CSS and Javascript files. When I check inspector it shows that it can not load the files because the directory is wrong. The address bar says localhost/Site-Name but the files are trying to be loaded from localhost/~paul/Site-Name so I must have messed up the configuration somehow.. Hopefully somebody can help. Thanks

推荐答案

我找到了一种解决方法,尽管它不能修复我的本地主机,但不显示本地主机文件夹中的Sites文件夹,但它确实允许我的Wordpress网站正常工作.我在我的站点文件夹中创建了一个名为〜paul的文件夹,然后将所有站点移入该文件夹.现在CSS JS等都可以正常加载,对此我感到满意.

I found a workaround which while it does not fix my localhost not showing the Sites folder at localhost/~paul it does allow my Wordpress sites to work. I created a folder within my sites folder called ~paul and then moved all my sites into that. Now the CSS JS etc all load fine and I am happy with that.

这篇关于Apache Setup Mac后LocalHost Wordpress网站无法加载CSS的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆