使用除index.html之外的Github页面 [英] Use other than index.html for Github pages

查看:95
本文介绍了使用除index.html之外的Github页面的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我最近开始使用github页面,到目前为止,我正在使用默认的index.html作为我的主页.如何使用其他页面作为默认页面?例如,如果在我的gh-pages分支中,我的html位于文件夹src/中.如何将./src/index.html设置为默认值而不是./index.html?

I have recently started using github pages and so far I am using the default index.html as my main page. How do I use another page as my default page? For example if in my gh-pages branch I have my html in a folder src/. How do I set ./src/index.html as my default instead of ./index.html?

推荐答案

创建虚拟index.html并将其放在标题中

Create dummy index.html and put this in the header

<meta http-equiv="refresh" content="0; url=http://mysite.github.io/folder/index.html" />

更改 http://mysite.github.io/folder/index.html转到所需的网址.

这篇关于使用除index.html之外的Github页面的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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