如果你正在尋找一種更靈活、更高級的菜單展示方式,Blocksy Pro 提供的 Advanced Menus(高級菜單)擴展正好滿足這種需求。本文將介紹如何結合 Gutenberg 編輯器和 Content Blocks,自定義構建一個動態(tài)、交互性強的菜單系統(tǒng),提升桌面端瀏覽體驗。
![圖片[1]-Blocksy 教程:打造高級動態(tài)菜單系統(tǒng)(結合 Content Blocks 與 Gutenberg)](http://gqxi.cn/wp-content/uploads/2025/05/20250508105907823-image.png)
啟用高級菜單擴展
首先,進入 WordPress 后臺的 Blocksy Dashboard,開啟 Advanced Menus 擴展模塊。完成后,即可開始構建菜單中要顯示的內容。
![圖片[2]-Blocksy 教程:打造高級動態(tài)菜單系統(tǒng)(結合 Content Blocks 與 Gutenberg)](http://gqxi.cn/wp-content/uploads/2025/05/20250508110126144-image.png)
創(chuàng)建 Content Blocks
高級菜單的內容來自 Content Blocks。以下是基本操作流程:
- 進入 Blocksy > Content Blocks 頁面
- 點擊右上角 Add New
![圖片[3]-Blocksy 教程:打造高級動態(tài)菜單系統(tǒng)(結合 Content Blocks 與 Gutenberg)](http://gqxi.cn/wp-content/uploads/2025/05/20250508110248555-image.png)
- 選擇標準的 Content Block 類型
- 命名內容塊(建議名稱帶有標識性,便于區(qū)分)
![圖片[4]-Blocksy 教程:打造高級動態(tài)菜單系統(tǒng)(結合 Content Blocks 與 Gutenberg)](http://gqxi.cn/wp-content/uploads/2025/05/20250508110328946-image.png)
每一個菜單展示項都可以關聯(lián)一個 Content Block。雖然文中提供了預設內容演示,但在你的站點中,需要自行設計區(qū)塊內容。
![圖片[5]-Blocksy 教程:打造高級動態(tài)菜單系統(tǒng)(結合 Content Blocks 與 Gutenberg)](http://gqxi.cn/wp-content/uploads/2025/05/20250508110457518-image.png)
建議使用 Gutenberg 可復用模塊(Reusable Blocks)來構建這些內容塊,也可以混合靜態(tài)模塊實現(xiàn)更豐富的布局。
![圖片[6]-Blocksy 教程:打造高級動態(tài)菜單系統(tǒng)(結合 Content Blocks 與 Gutenberg)](http://gqxi.cn/wp-content/uploads/2025/05/20250508110528904-image.png)
完成后,進入「Display Conditions」,將內容塊設置為 Entire Website(全站顯示)。不需要調整其他設置,因為菜單擴展會自動調用這些內容。
![圖片[7]-Blocksy 教程:打造高級動態(tài)菜單系統(tǒng)(結合 Content Blocks 與 Gutenberg)](http://gqxi.cn/wp-content/uploads/2025/05/20250508110636600-image.png)
我們要像上面的操作一樣,創(chuàng)建菜單項的內容塊,比如“博客“和“關于我們”
![圖片[8]-Blocksy 教程:打造高級動態(tài)菜單系統(tǒng)(結合 Content Blocks 與 Gutenberg)](http://gqxi.cn/wp-content/uploads/2025/05/20250508111005708-image.png)
配置菜單結構
進入 WordPress 后臺的「外觀 > 菜單」,開始設置菜單項:
![圖片[9]-Blocksy 教程:打造高級動態(tài)菜單系統(tǒng)(結合 Content Blocks 與 Gutenberg)](http://gqxi.cn/wp-content/uploads/2025/05/20250508111247650-image.png)
1. 啟用高級菜單選項
點擊你想自定義的一級菜單項,系統(tǒng)會顯示 “Menu Item Settings” 按鈕。點擊后可以設置:
![圖片[10]-Blocksy 教程:打造高級動態(tài)菜單系統(tǒng)(結合 Content Blocks 與 Gutenberg)](http://gqxi.cn/wp-content/uploads/2025/05/20250508111346776-image.png)
- 下拉菜單布局(如單列、兩列等)
- 是否移除菜單標簽或鏈接
- 是否添加圖標或標記(badge)
- 自定義樣式設置(Design)
2. 添加自定義鏈接(Custom Links)
為了將內容塊作為菜單內容展示,建議使用自定義鏈接作為子項:
![圖片[11]-Blocksy 教程:打造高級動態(tài)菜單系統(tǒng)(結合 Content Blocks 與 Gutenberg)](http://gqxi.cn/wp-content/uploads/2025/05/20250508111825528-image.png)
- URL 處填寫
#
(代表無鏈接) - 名稱可以自定,方便識別
![圖片[12]-Blocksy 教程:打造高級動態(tài)菜單系統(tǒng)(結合 Content Blocks 與 Gutenberg)](http://gqxi.cn/wp-content/uploads/2025/05/20250508111916132-image.png)
- 將該項拖動到對應的父級菜單下方,建立層級結構
![圖片[13]-Blocksy 教程:打造高級動態(tài)菜單系統(tǒng)(結合 Content Blocks 與 Gutenberg)](http://gqxi.cn/wp-content/uploads/2025/05/20250508112004132-image.png)
展開該菜單項,在“內容類型”中選擇 Content Block,并從列表中選擇你剛創(chuàng)建的內容塊。
![圖片[14]-Blocksy 教程:打造高級動態(tài)菜單系統(tǒng)(結合 Content Blocks 與 Gutenberg)](http://gqxi.cn/wp-content/uploads/2025/05/20250508112200492-image.png)
建議同時關閉該項的標簽和鏈接顯示,以便完整展示內容塊樣式。
![圖片[15]-Blocksy 教程:打造高級動態(tài)菜單系統(tǒng)(結合 Content Blocks 與 Gutenberg)](http://gqxi.cn/wp-content/uploads/2025/05/20250508112240669-image.png)
按照相同方式,完成其他內容塊的插入。
![圖片[16]-Blocksy 教程:打造高級動態(tài)菜單系統(tǒng)(結合 Content Blocks 與 Gutenberg)](http://gqxi.cn/wp-content/uploads/2025/05/20250508112354339-image.png)
查看最終效果
保存菜單后,切換到前端,即可看到全新的高級動態(tài)菜單效果。這些菜單可以展示豐富信息,如分類概覽、產品推薦、圖文展示等,完全突破傳統(tǒng)下拉菜單的限制。
![圖片[17]-Blocksy 教程:打造高級動態(tài)菜單系統(tǒng)(結合 Content Blocks 與 Gutenberg)](http://gqxi.cn/wp-content/uploads/2025/05/20250508112456659-image.png)
回顧構建流程
- 使用 Content Blocks 構建各類菜單內容
- 在菜單中為頂級項目啟用高級菜單功能
- 添加子項并關聯(lián)內容塊
- 保存設置,前往前端查看展示效果
總結
借助 Blocksy Pro 的高級菜單功能,搭配 Content Blocks 與 Gutenberg 編輯器,可以構建具有高度互動性與美觀性的菜單系統(tǒng)。整個過程無需編碼,操作直觀,適合對菜單設計有更高要求的站點使用。
最近更新
聯(lián)系我們 | |
---|---|
教程看不懂?聯(lián)系我們?yōu)槟赓M解答!免費助力個人,小企站點! |
![]() 客服微信
|
① 電話:020-2206-9892 | |
② QQ咨詢:1025174874 | |
③ 郵件:info@361sale.com | |
④ 工作時間:周一至周五,9:30-18:30,節(jié)假日休息 |
暫無評論內容