ad8n-2
Forum Replies Created
-
Forum: Fixing WordPress
In reply to: Menus disappear when using rewrite rulesLatest update!
It goes without saying that I can hardcode the menus into the header. This seems pointless to me, so I’m trying to avoid it.
However, if I go to one of the pages where the menu is not displaying, the page title is not displaying in the browser header/tab either. For instance, my ABOUT page should read: ‘About | GA Airport Report’.
Instead it reads: ‘ | GA Airport Report’.
What gives?
Thanks,
A.Forum: Fixing WordPress
In reply to: Menus disappear when using rewrite rulesToday I tried removing the functions code to see if the menus would display properly without it. Although I expected the loop to fail, I was hoping that I could at least isolate what code is causing the problem.
Unfortunately, simply removing the functions code made no difference to the menus. (And yes, I did resave the permalinks).
So does this mean that there’s a problem with the way I’m calling the category page?
Anybody have any suggestions?Forum: Fixing WordPress
In reply to: Menus disappear when using rewrite rulesWould I be right in thinking that the problem is most likely in the functions.php code, rather than the city.php template? Because the menus must be processed before the body code is.
I’m not sure why the second block of code didn’t display properly in the previous post, so here it is again!// Identify and decode query variable into Category Slug if(isset($wp_query->query_vars['loc_city'])) { $sLocCity = urldecode($wp_query->query_vars['loc_city']); } // Create new variable and query while passing slug using WP 'category_name' parameter $myQuery = new WP_Query(); $myQuery->query( 'category_name=' . $sLocCity ); // WP Loop continues from here if ($myQuery->have_posts()) : while($myQuery->have_posts()) : $myQuery->the_post();