簡體   English   中英

如何在 Wordpress 中創建帶有動態鏈接的按鈕(使用類別中的最后一篇博客文章鏈接自動更新)

[英]How to create button with dynamic links (that automatically updates with the last blog post link in a category) in Wordpress

正如標題所說,我正在嘗試在我的主頁上設置一個按鈕,該按鈕會自動使用特定類別中最后一篇博客文章的鏈接更新鏈接

You need to code shortcode (in child theme functions.php for example or make a plugin), that will generate this button HTML output, fetch last post url and add it to button. 然后你可以在任何你需要的地方使用類似 [last_post_button] 的東西。

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM