[WordPress] 外掛分享: WP-ngrok

WordPress 外掛 WP-ngrok 的封面圖片。

前言介紹

  • 這款 WordPress 外掛「WP-ngrok」是 2020-12-02 上架。
  • 目前有 40 個安裝啟用數。
  • 上一次更新是 2022-12-04,距離現在已有 881 天。超過一年沒更新,安裝要確認版本是否可用。以及後續維護問題!
  • 外掛最低要求 WordPress 5.0 以上版本才可以安裝。
  • 外掛要求網站主機運作至少需要 PHP 版本 8.0 以上。
  • 有 1 人給過評分。
  • 還沒有人在論壇上發問,可能目前使用數不多,還沒有什麼大問題。

外掛協作開發者

themeid | hadie-danker |

外掛標籤

debug | ngrok | localhost | development | local server |

內容簡介

本外掛能夠將運行在您的本機機器上的 WordPress 本地網頁服務暴露到網際網路上。Ngrok 能夠幫助您實現此功能。
此外掛透過掛載頁面創建的開始和結尾,並將其捕獲到輸出緩衝區中。接著,它將使用資料庫中的 URL 進行 str_replace,會在發送回關閉鈎子之前刪除它。這意味著,我可以共享 ngrok URL 的 HTTP 或 HTTPS 版本。

使用方法
第一步:安裝 ngrok

在此下載並安裝 ngrok https://ngrok.com/download

第二步:安裝 WP-NGROK

將 wp-ngrok.zip 文件夾上傳到 /wp-content/plugins/ 目錄
在 WordPress 的「外掛」菜單中啟用此外掛

在您的終端中運行以下命令:

~/ngrok http -host-header=localdomain.test 8888

第三步:創建 localtunnel

通過傳遞我們在本地使用的網站主機名和端口號,這將指引流量到我們的本地網站。這對於我們自己創建它,或者使用類似 MAMP Pro 之類的工具進行設置都是有效的。

~/ngrok http -host-header=sitename.localhost 8888

一旦 ngrok 啟用並運行,就會顯示如下的信息:

會話狀態 在線
帳戶 Theme.id (計劃:專業版)
版本 2.3.35
地區 美國(us)
Web 介面 http://127.0.0.1:4040
轉發 http://yourapp.ngrok.io -> http://localhost:8888
轉發 https://yourapp.ngrok.io -> http://localhost:8888

最低要求

WordPress 版本必須為 5.0 或更高
PHP 版本必須為 5.6 或更高
MySQL 版本必須為 5.0 或更高

我們推薦您的主機支援:

PHP 版本必須為 7.0 或更高
MySQL 版本必須為 5.6 或更高
WordPress 記憶體限制必須為 64 MB 或更大(最好是 128 MB 或更高)

請在 WordPress 支援中發問

如有關於此外掛的問題,請隨時在 WordPress 支援中提問

原文外掛簡介

Expose a WordPress local web server to the internet ngrok allows you to expose a web server running on your local machine to the internet.
This plugin works by hooking to the start and end of the page creation and capturing it into an output buffer, it then uses the URL from the database for a str_replace, stripping it out before sending back out to the shutdown hook. This means that I can share either the HTTP or HTTPS versions of the ngrok URLs.
How To Use
Step One: Install ngrok
Download and install ngrok here https://ngrok.com/download
Step Two: Install WP-NGROK

Upload wp-ngrok.zip folder to the /wp-content/plugins/ directory
Activate the plugin through the ‘Plugins’ menu in WordPress

run command in your terminal
~/ngrok http -host-header=localdomain.test 8888
Step Three: Creating the localtunnel
Send through the host name of the site that we use locally as well as the port number and this will then direct the traffic to my local site. This works whether we had created it, or using something like MAMP Pro to set this up for me.
~/ngrok http -host-header=sitename.localhost 8888

Once ngrok is up and running I will be presented with the display that you can see below
Session Status online
Account Theme.id (Plan: Pro)
Version 2.3.35
Region United States (us)
Web Interface http://127.0.0.1:4040
Forwarding http://yourapp.ngrok.io -> http://localhost:8888
Forwarding https://yourapp.ngrok.io -> http://localhost:8888

Minimum Requirements
WordPress 5.0 or greater
PHP version 5.6 or greater
MySQL version 5.0 or greater
We recommend your host supports:
PHP version 7.0 or greater
MySQL version 5.6 or greater
WordPress Memory limit of 64 MB or greater (128 MB or higher is preferred)
Please ask in WordPress Support
Please to ask about this plugin

各版本下載點

  • 方法一:點下方版本號的連結下載 ZIP 檔案後,登入網站後台左側選單「外掛」的「安裝外掛」,然後選擇上方的「上傳外掛」,把下載回去的 ZIP 外掛打包檔案上傳上去安裝與啟用。
  • 方法二:透過「安裝外掛」的畫面右方搜尋功能,搜尋外掛名稱「WP-ngrok」來進行安裝。

(建議使用方法二,確保安裝的版本符合當前運作的 WordPress 環境。


wp-ngrok-1.0 |

延伸相關外掛(你可能也想知道)

  • Debug Using Ngrok 》此外掛可將除錯日誌傳送至您的 ngrok 伺服器,您可以檢視瀏覽器無法見到或除錯的代碼執行日誌。, 安裝與使用方式, , 安裝外掛並進入「工具 => Ngrok Debug」...。

文章
Filter
Apply Filters
Mastodon