Combine multiple menus using the filter wp_nav_menu_items

Thankful to the Lord, I found a solution for anyone else that comes across this issue. I took this function from the WordPress codex and modified it to soot my needs function get_menu($menu_name) { $menu_items = wp_get_nav_menu_items($menu_name); $menu_list=””; $count = 0; $submenu = false; foreach( $menu_items as $menu_item ) { $link = $menu_item->url; $title = … Read more

WordPress meta query with meta serialized data array value

Probably should have waited a bit but after posting the question I found a solution based on my points above and repeated here: https://codex.wordpress.org/Class_Reference/WP_Meta_Query https://generatewp.com/filtering-data-with-wp_meta_query/ My Solution: $metaSearchSubQuery = [ ‘relation’ => ‘OR’ ]; foreach($eventTypeId as $id) { $metaSearchSubQuery[] = [ ‘key’ => ‘EventId’, ‘value’ => serialize($id), ‘compare’ => ‘like’ ]; } $metaSearchQuery[] = $metaSearchSubQuery;

adding additional class to get the post thumbnail [duplicate]

Sorry for late reply, already fixed, i miss understood about array, so here the code that completely run as i want it. <?php $next_post = get_next_post(); next_post_link(‘%link’, get_the_post_thumbnail($next_post->ID, ‘prev_next_img’, array( ‘class’ => ’rounded-lg object-fill w-full max-h-full’ )) . ‘<h4 class=”text-center mt-2 lg:text-base text-sm no-underline text-black leading-snug font-medium”>%title</h4>’, false); ?> in function.php i put custome image … Read more