WordPress.org

Ready to get started?Download WordPress

Forums

Another WordPress Classifieds Plugin
[resolved] Can you comment on the alternate methods of creating templates? (3 posts)

  1. moens
    Member
    Posted 1 year ago #

    OK, it looks like a template filter option in the code (below) is an idea still in gestation(?). It seems that it would at least require the actual filter method to be added in functions_awpcp.php (maybe), which would still be overwritten in a plugin upgrade. Maybe it would be better if the filter was _always_ called, and if it returns null or FALSE, then it continues to the other options. The awpcp_browse_ads_template_filter method could load a db field to see if there is an alternate file to process, and process it, or not...

    Do you have plans for this? Are you open to me making the necessary updates and pushing you the code?

    // filters to provide alternative method of storing custom layouts (e.g. can be outside of this plugin's directory)
    if ( has_action('awpcp_browse_ads_template_action') || has_filter('awpcp_browse_ads_template_filter') ) {
      do_action('awpcp_browse_ads_template_action');
      $output = apply_filters('awpcp_browse_ads_template_filter');
      return;
    
    }

    http://wordpress.org/extend/plugins/another-wordpress-classifieds-plugin/

  2. awpcp
    Member
    Plugin Author

    Posted 1 year ago #

    Hi moens,

    As we are making major internal updates to the plugin, I don't think we can incorporate your changes at this time. We can consider a formal template system for the future, as we've been migrating it slowly since it predates WP 3.0 where that functionality became available.

  3. moens
    Member
    Posted 1 year ago #

    I see, thanks for the reply! I'll just update through git merges until you finalize a post wp3 version. Thanks!

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic

Tags

No tags yet.