Blog

Fixing wp_list_pages and wp_nav_menu highlighting plus breadcrumbs on Dynamic Pod Pages

Recently I took it upon myself to begin fixing what wp_list_pages and wp_nav_menu sometimes messes up — highlighting what menu/page item you’re on. The resulting code is used on the new Pods site, and it’s really only basic (wp_list_pages is basic in itself, while wp_nav_menu I’m only focusing on the ‘menu-‘ classes. It covers whenever …

Read more

Getting the Current Full URL of any page in Pods 1.9.6

Pods 1.9.6 isn’t out yet, we’re waiting on the fully working TinyMCE API to be ready, but once it is, we’ve added a new function called get_current_url() You can use get_current_url() to get the full URL including the protocol, current hostname, and URI. This differs from just using $_SERVER[‘REQUEST_URI’] because it’s absolute. You can use …

Read more

Naming Pod Templates and Pod Helpers with a Slash and why it makes sense

When things first started out with Pods, the naming conventions for Pod Templates and Pod Helpers were pretty much a free-for-all. Examples of names would be like: event_list (template) event_detail (template) event_save (pre-save helper) image_full (display helper) image_thumb (display helper) subscriber_get_info (display helper – advanced) etc… But, now that your sites are becoming more complex, …

Read more