Wordpress Themes - WP Forum at BFA

Wordpress Themes - WP Forum at BFA (http://forum.bytesforall.com/index.php)
-   Montezuma Theme (http://forum.bytesforall.com/forumdisplay.php?f=53)
-   -   RFE: callback function passed to bfa_loop for Not Found processing (http://forum.bytesforall.com/showthread.php?t=22680)

marklevine Jul 27, 2014 07:00 PM

RFE: callback function passed to bfa_loop for Not Found processing
 
My current project has six custom post types. The default "Not Found" message is good for five of them but the sixth, Job Postings, is different. It would be nice to be able to pass an optional callback function to bfa_loop to process the case where the query returned no results. For example:

Code:

<?php bfa_loop( 'postformat-job_posting' ,'no_jobs_found'); ?>
Actually, I don't really care if the 2nd argument were a callback function or the name of a sub-template.

Currently, I don't believe that there is a way to change the message on a per post type basis. The alternative is to code a completely separate loop. My custom post type (jobs) has a lot of custom taxonomies (location, experience, function, ...) so separate loops would mean a lot of extra code to maintain.


All times are GMT -6. The time now is 10:41 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.