更改Ghost博客的默认路由

编程入门 行业动态 更新时间:2024-10-27 06:32:48
本文介绍了更改Ghost博客的默认路由的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述

是否可以更改Ghost中的默认路由?

Is there a way to change the default routing in Ghost?

我已经使用ghost平台创建了一个博客,并将默认主题从Casper更改为Ghostion。然后,我创建了四个关于我,我的投资组合,博客和简历的静态页面。一切都按预期进行。

I have created a blog using the ghost platform and changed the default theme from Casper to Ghostion. I then created four static pages about me, my portfolio, blog, and resume. Everything is working as it should.

这里是Ghost默认将所有博客文章传递到index.hbs文件的问题。我想更改此设置并将它们传递到自定义blog.hbs文件,然后当用户导航到/ blog slug时,由服务器提供blog.hbs文件,而不是静态页面的默认文件。本质上,我想将所有博客文章移至我的博客专用页面,而不是将其显示在网站的主页上。我希望我要实现的目标是明确的。

Here is the problem Ghost by default passes all the blog articles to the index.hbs file. I would like to change this and have them passed to a custom blog.hbs file then when the user navigates to the /blog slug have the server serve the blog.hbs file instead of the default for static pages. Essentially, I want to move all blog post to the page dedicated for my blog instead of having them displayed on the home page of the site. I hope what I'm trying to achieve is clear.

推荐答案

当前,如果不修改大量Ghost核心代码,这是不可能的,但是在将来的版本中,如果插件支持到达。

Currently this is not possible without modifying huge chunks of Ghost's core code, but it might be possible in future versions when plugin support arrives.

更多推荐

更改Ghost博客的默认路由

本文发布于:2023-08-02 17:06:05,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/34/1279578.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:路由   博客   Ghost

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!