سؤال

I'm working on a responsive webdesign where my navigation should swap into a select-menu when resizing the window in smaller sizes.

Is it somehow possible to add another param to functions like wp_list_categories() or wp_list_pages() so that it outputs <option>item</option> instead of <li>item</li>?

So what I wanna do is use wp_list_pages() and wp_list_categories() to ouput its default stuff in order to have a normal menu. However I also want to ouput the same pages and categories in a second <select><option>… navigation that is hidden by default but shown when a media-query is triggerd. Any idea how to dynamically produce this second menu?

Thank you in advance!

لا يوجد حل صحيح

مرخصة بموجب: CC-BY-SA مع الإسناد
لا تنتمي إلى wordpress.stackexchange
scroll top