如何还原默认主页? [英] How to restore default homepage?

查看:100
本文介绍了如何还原默认主页?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我是Drupal的新手,无法理解该操作:我必须不小心删除了测试站点中的默认主页,并且找不到恢复它的方法。

I'm new to Drupal, and cannot understand how to do this: I must have accidentally deleted the default home page in my test site, and cannot find a way to restore it.

我可以创建一个新的基本页面并将其设置为我的新家,但是这缺少了一些东西-例如,即使我没有显示带有主页内容系统块的最新文章,将该新页面设置为网站设置中的主页。

I see I can create a new basic page and set it as my new home, however this is missing something - for example it does not show latest articles with the "main page content" system block, even if I set this new page as the homepage in site settings.

我还应该做些什么让Drupal知道这实际上是一个主页吗?还没有办法还原原始的默认主页吗?如果我删除了自定义页面,并在网站设置中将默认主页留空,那么现在我将被发送到登录页面,或者如果我已经登录,则被发送到用户个人资料。

Should I do something more to let Drupal know this is actually an homepage? And isn't there a way to restore the original default home page? If I delete the custom page and let the default home empty in site settings I'm now sent to the login page, or to my user profile if I'm logged-in.

感谢您的帮助,
等。

Thanks for any help, al.

推荐答案

Drupal 8中的默认首页实际上不是页面(一个节点)但一个视图。

The default front page in Drupal 8 is actually not a page (a node) but a View.

请检查是否启用了视图和视图UI模块(从管理菜单中进行管理/扩展 )。

Please, check out if Views and Views UI modules are enabled (Manage/Extend from admin menu).

如果两个都启用,则检查所有当前视图( Manage / Structure / Views )。

If both of them enabled, then inspect all your current Views (Manage/Structure/Views). There should be one with a name "Frontpage".

如果存在并启用了此 Frontpage视图,则将默认首页设置为 / node 在您网站的设置中(管理/配置/基本网站设置)。

If this "Frontpage" View exists and enabled, then set Default front page to /node in your site's settings (Manage/Configuration/Basic sites settings).

如果此首页视图

如果此首页视图不存在,则您可能已将其删除并有3个还原它的选项:

If this "Frontpage" View does not exist, then you've probably deleted it and have 3 options to restore it:


  1. 创建一个新视图,该视图将与已删除的默认原始 Frontpage视图一样工作。您可以创建一个新的测试站点,仅将其设置用作参考(在全新的标准安装后即可使用 Frontpage视图)。

  2. 如果未创建任何新站点查看或修改现有的视图,那么最好的选择就是取消安装/安装Views / Views UI模块。它将刷新所有设置(即,将丢失所有自定义视图或设置,将还原所有默认的预定义视图)。

  3. 不推荐。您可以创建一个新的Drupal新鲜站点,使Drupal相信此新安装实际上是您当前站点的副本,然后您可以使用核心模块配置将新安装的 Frontpage视图从新安装导出/导入到当前站点。经理。有关此内容的更多信息: https://drupal.stackexchange.com/a/150609

  1. Create a new View which would work just as default original "Frontpage" View that have been deleted. You can create a new test site and just use its settings as a reference ("Frontpage" View will be available after a clean "standard" install).
  2. If you did not create any new Views or modify existing, then the best choice will be just unistalling/installing Views/Views UI modules. It will refresh all settings (i. e. all custom Views or settings will be missed, all default predefined Views will be restored).
  3. Not recommended. You can create a new Drupal fresh site, make Drupal believe that this new install is actually a copy of your current site, and then you can just export/import this "Frontpage" View from new install to your current site using core module "Configuration Manager". More on this: https://drupal.stackexchange.com/a/150609

这篇关于如何还原默认主页?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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