replace_first
功能說明
僅替換第一個出現的目標字串。
語法
{{ 字串 | replace_first: "原字串", "新字串" }}
範例
{{ "one fish two fish red fish" | replace_first: "fish", "cat" }}
one cat two fish red fish
Updated 21 days ago
功能說明
僅替換第一個出現的目標字串。
語法
{{ 字串 | replace_first: "原字串", "新字串" }}
範例
{{ "one fish two fish red fish" | replace_first: "fish", "cat" }}
one cat two fish red fish
Updated 21 days ago