Extract domain from text in Mandarin

From LemonWiki共筆
Revision as of 15:19, 28 March 2025 by Planetoid (talk | contribs)
Jump to navigation Jump to search

從文章內容,擷取網址中的網域部分

🌐 Switch language: English, 漢字


使用 Google sheet 擷取網域

使用 Google 試算表 REGEXEXTRACT 函數

=REGEXEXTRACT(A1, "(http[s]?\://[^/]+)")

輸入:

Yahoo! 新聞 https://tw.news.yahoo.com/abc

輸出:

https://tw.news.yahoo.com

說明:

  1. 網域指以 http:// 或 https:// 開頭,與相臨不是符號 / 的多個文字:[^/]+