[WordPress] 外掛分享: Pingchecker

首頁外掛目錄 › Pingchecker
10+
安裝啟用
尚無評分
5368 天前
最後更新
問題解決
WordPress 2.6+ v1.2.0 上架:2011-04-26

內容簡介

Pingchecker 是一款免費的 WordPress 外掛,它允許您掃描您文章中的內容,查看鏈接的 ping 狀態,並手動 ping 這些頁面。這比 WordPress 內建的功能更加優秀,因為它允許您獲得您嘗試 ping 的結果,而 WordPress 則沒有提供結果(在 WordPress 中,您的 ping 要麼出現在追踪列表中,要麼不在,沒有說明或錯誤代碼)。 同時,Pingchecker 還提供了一個解決 WordPress XML RPC 服務器中缺陷的方法,該方法可以很大程度上提高您 ping 被接受的機會。當您發布文章時,使用 Pingchecker 檢查您鏈接的頁面的 ping 狀態,如果它們不可 ping,則當做需要更換鏈接。發布文章後,WordPress 將自動嘗試 ping 這些頁面。如果您發現追踪列表中沒有您的 ping,使用 Pingchecker 手動 ping 這些頁面,它將通過警報框提供 ping 的結果。此外,它的 XML RPC 服務器錯誤解決方案,通過使用正則表達式來掃描文章內容中的鏈接,然後在您博客的頁腳中加入一個隱藏的 div 元素,其中包含所有鏈接(帶有 nofollow 標籤,以免您被歸類為兩次鏈接),這樣可以更輕鬆地被服務器使用的 strip_tags 函數所解析。

外掛標籤

開發者團隊

⬇ 下載最新版 (v1.2.0) 或搜尋安裝

① 下載 ZIP → 後台「外掛 › 安裝外掛 › 上傳外掛」
② 後台搜尋「Pingchecker」→ 直接安裝(推薦)
📦 歷史版本下載

原文外掛簡介

Pingchecker is a free plugin for WordPress that allows you to scan your post’s content for
links, check the pingability of those resources you’ve linked to, and manually ping those
pages. This improves upon the inbuilt fuctionality of WordPress by allowing you to receive
the results of your attempted pings whereas WordPress doesn’t. (With WordPress your ping
either appears in the trackback list or it doesn’t, with no explanation or error codes.)
Also included is a workaround for a bug in the WordPress XML RPC server that prevents many
of your pingbacks from succeeding without you even knowing about it! When you ping another
blogs server, it will check the page you linked, BUT because of this bug, sometimes it can’t
find the link at all. This workaround adds a hidden div to your footer with your links so
they can be found, greatly improving your chances of a successful ping.
Recommended Use

Before publishing your post, use Pingchecker to check the pingability of the resources
you are linking to. If they aren’t, you may wish to choose alternative similar resources
that are pingable instead.
Then, publish your post and WordPress will attempt to ping the resources automatically
as it normally would. Check the trackback list under your content box to see if your ping
was successful as usual.
If the new trackback/pingback does not appear, use Pingchecker to ping the resource
instead. The results of your attempted pings will be returned in an alert box.

The XML RPC Server Bug Workaround
While working on this plugin I noticed a large occurrence of the pingback fault 17:
“The source URL does not contain a link to the target URL, and so cannot be used as a source.”
A really frustrating message given you are sending a pingback because the source DOES contain
a link to the target, yes? Might I point out that very few WordPress users are aware of this
even happening because nowhere does WordPress actually return you these fault codes..!
Well, after a bit of testing I found the bug seems to be in the XML RPC server code for
Wordpress, specifically the strip_tags function in PHP is just not reliable enough for getting
anchor links on the variety of WordPress templates out there (IMHO). (Line 3422 in WP3.1)
Unfortunately, since the bug is in the server code itself, you can’t fix it on someone elses
blog can you? That’s why this is a workaround instead. The Pingchecker workaround will scan
your post content for links using regex instead, then echo a hidden div element containing
all the links (with an added nofollow tag so you aren’t linking twice) in your blogs footer,
which is picked up much more easily by the strip_tags function in use by the server.

延伸相關外掛

文章
Filter
Mastodon