简体   繁体   English

通过GoDaddy,首页看起来有所不同

[英]Home page looks different through GoDaddy

I have godaddy hosting my website . 我有Godaddy托管我的网站

My website looks fine when I host it locally. 在本地托管时,我的网站看起来不错。 However, when I launch it through a web browser: 但是,当我通过Web浏览器启动它时:

  • the navbar looks smaller 导航栏看起来更小
  • the font looks smaller 字体看起来较小
  • the icons float right instead of being in the middle. 图标向右浮动,而不是位于中间。

If you click on my link to go to my website, you'll see that it looks smaller but my other pages look normal. 如果单击我的链接转到我的网站,您会发现它看起来较小,但其他页面看起来很正常。 Does anybody know why? 有人知道为什么吗?

Couple things: 几件事情:

1: If you're developing locally on Windows, for example editing files in a text editor and then refreshing a browser to view the changes, you're likely using the Windows API (which is standard for Windows apps), meaning filenames are case-insensitive. 1:如果您要在Windows上进行本地开发,例如在文本编辑器中编辑文件,然后刷新浏览器以查看更改,则可能使用Windows API(Windows应用程序的标准),即文件名大小写-不敏感。 An exception to this would be if you're using a more POSIX compliant system, such as Cygwin. 如果您使用的是与POSIX兼容的系统,例如Cygwin,则可能是一个例外。

When you move your files to godaddy's server and view them there, they're running a POSIX compliant http server such as Nginx or Apache, so your filenames are case sensitive. 当您将文件移到Godaddy的服务器上并在其中查看时,它们正在运行POSIX兼容的http服务器,例如Nginx或Apache,因此文件名区分大小写。 I hope this helps clear things up a little for you. 我希望这对您有所帮助。

2: My rep is too low to alter your post, but you need to prune the trailing forward slash from your url: 2:我的代表的职位太低,无法更改您的帖子,但是您需要修剪网址中的尾随正斜杠:

'index.html/' becomes 'index.html' “ index.html /”成为“ index.html”

Everything looks different because the site is getting 404 responses for all the styles and scripts. 一切看起来都不同,因为该网站针对所有样式和脚本都收到404响应。 Check on your browser's console for errors. 在浏览器的控制台上检查是否有错误。 You have to change the sources or upload the assets to your hosting. 您必须更改源或将资产上载到托管。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM