Smart Custom 404 error page [404page] WordPress 插件

Smart Custom 404 error page [404page] WordPress 插件

描述

现在404page是最流行的WordPress自定义404错误页面插件,活跃安装数已达100,000+!

将访问者带到您的网站上既费时又费力。每个访客都很重要。但大多数主题的默认404错误页面缺乏有关您的站点的信息。这使得那些首次访问的访客感到困惑,并最终离开您的站点。应该设置有帮助的自定义404错误页面,以保留这些访客。

这个方便的插件使您可以轻松创建自己的404错误页面,并且几乎适用于所有主题。

使用方法

像创建其他页面一样,使用WordPress页面编辑器创建您的自定义404错误页面。然后转到“外观”-> “ 404错误页面”,选择创建的页面作为您的自定义404错误页面。大功告成!

Demo

See it in action (no registration needed)
kindly powered by TasteWP

为什么使用本插件?

与其他类似的插件不同,404page插件不会创建重定向,这 非常重要,因为这会传递正确的404代码,从而告诉搜索引擎该页面不存在,必须将其从索引中删除。

与其他类似的插件不同,404page插件不会产生额外的服务器请求

要求

运行此插件的唯一要求是,将“设置”->“固定链接”中的永久固定结构更改为除“朴素”以外的任何形式。这也会激活WordPress 404错误处理。

文档和支持

插件使用手册

支持论坛

视频(英语)

404page插件简介

高级设置快速概览

“加载页面后强制404错误”说明

“禁用URL自动更正猜测”说明

“发送针对回收站对象的HTTP 410状态代码”说明

“兼容模式”说明

Block & Shortcode

Block

The Plugin offers a block “URL causing 404 error” for the block-based editor to show the URL that caused the error. The block offers three display options:

  • “Page” to show the page including path ( e.g. does/not/exist )
  • “Domain Path” to show the URL without protocol and parameters ( e.g. example.com/does/not/exist )
  • “Full” to show the complete URL ( e.g. https://example.com/does/not/exist?p=1 )

Shortcode

The Plugin offers a shortcode “pp_404_url” for the classic editor to show the URL that caused the error. There are three possible options:

  • [pp_404_url page] to show the page including path ( e.g. does/not/exist )
  • [pp_404_url domainpath] to show the URL without protocol and parameters ( e.g. example.com/does/not/exist )
  • [pp_404_url] or [pp_404_url full] to show the complete URL ( e.g. https://example.com/does/not/exist?p=1 )

您喜欢这个插件吗?

I spend some of my precious free time developing and maintaining my free WordPress plugins. You don’t need to make a donation. No money, no beer, no coffee. If you like this plugin then please do me a favor and give it a good rating. Thanks.

插件隐私信息

  • 本插件不设置cookies
  • 本插件不收集或存储任何数据
  • 本插件不会将任何数据发送到外部服务器

Peters的插件隐私政策

ClassicPress

本插件与ClassicPress兼容。

Peter的更多插件

Take a look at my other plugins

兼容性

404page插件已通过以下主题作者的测试

  • Athena
  • Customizr (阅读有关Customizr兼容模式的更多信息)
  • evolve
  • GeneratePress
  • Graphene
  • Hemingway
  • Hueman
  • Responsive
  • Spacious
  • Sparkling
  • Sydney
  • Twenty Ten
  • Twenty Eleven
  • Twenty Twelve
  • Twenty Thirteen
  • Twenty Fourteen
  • Twenty Fifteen
  • Twenty Sixteen
  • Twenty Seventeen
  • Twenty Nineteen
  • Twenty Twenty
  • Vantage
  • Virtue
  • Zerif Lite

404page插件已通过以下基础主题作者的测试

  • Bones
  • JointsWP
  • undersores

404page插件已通过以下插件作者的测试

  • bbPress
  • BuddyPress
  • DW Question & Answer
  • hashtagger
  • Page Builder by SiteOrigin
  • Polylang
  • User Submitted Posts
  • WooCommerce
  • WP Super Cache (阅读有关WP Super Cache兼容性的更多信息)
  • WPML WordPress Multilingual Plugin (被WPML team官方采用)

针对开发者

动作钩子

该插件添加了一个动作钩子 404page_after_404,您可以使用它来添加其他函数。在检测到404错误后,动作发生的确切位置取决于操作方法。您的函数不应产生任何输出。没有参数。

常量

安装并激活404page插件后,它将定义PHP常量PP_404。可以通过检查这个常量是否存在以检测404page插件。

函数

本插件提供以下函数:

  • pp_404_is_active() 检测是否选择了一个自定义404页面并确认页面是否存在
  • pp_404_get_page_id() 获取404页面的ID
  • pp_404_get_all_page_ids() 获取包含所有语言的页面ID的数组
  • pp_404_get_the_url( $type ) to get the URL that caused the 404 error
    • Parameter $type string Optional
    • “page” to get the page including path ( e.g. does/not/exist )
    • “domainpath” to get the URL without protocol and parameters ( e.g. example.com/does/not/exist )
    • “full” (default) to get the complete URL ( e.g. https://example.com/does/not/exist?p=1 )

Read more

原生模式

如果您是主题开发人员,则可以在主题中添加对404page插件的原生支持,以实现完全控制。更多信息.

相关推荐

发表回复

房先生
我们将24小时内回复。
2024-07-11 10:50:00
您好,有任何疑问请与我们联系!
您的工单我们已经收到,我们将会尽快跟您联系!
[QQ客服]
2781198
加我微信
[电话联系]
13585372227
[电子邮件]
chaoneo@163.com
取消

选择聊天工具: