WordPress.org

Ready to get started?Download WordPress

Forums

WPPizza
[resolved] Custom fields/tags for menu items? (6 posts)

  1. frogsplash
    Member
    Posted 5 months ago #

    Love the plugin, it appears it will be a perfect solution to posting all these menus as PDFs! The plugin has been working like a champ on my beta site, but I'm wondering about a couple of things:

    – Is it possible to add custom fields functionality to these posts? I am using the plugin to build a beer menu, and they have lots of different traits – brewer, brewer city, type of beer, etc. It would be awesome if I could get custom fields working, is there a functions.php hack that might get that working?

    – Possible in the shortcode to omit the title, or just use the description by itself?

    Many thanks for your hard work on a great plugin!

    http://wordpress.org/plugins/wppizza/

  2. ollybach
    Member
    Plugin Author

    Posted 5 months ago #

    > ....is there a functions.php hack that might get that working?

    not at the moment, but it's easy to do and not such a bad idea to make those things customisable.
    I'll put it in the next update (maybe even later today) and post some example code here

    >Possible in the shortcode to omit the title....
    which shortcode in particular are we talking about here ?

  3. frogsplash
    Member
    Posted 5 months ago #

    Thanks so much for the quick response. I'll keep an eye out for the code, much appreciated.

    Shortcode: sorry, that was a bit vague. I'd like to essentially split the header into its title and description components.

    Example: [wppizza category='burgers' noheader='1'] will kill the title/description, whereas [wppizza category='burgers' ] will show both. I'd love to be able to get either one individually.

  4. ollybach
    Member
    Plugin Author

    Posted 5 months ago #

    re functions.php

    in v2.6.1 you could now use a filter like so:

    add_filter('wppizza_cpt_args','wppizza_cpt_arguments');
    	function wppizza_cpt_arguments($args){
    		$args['supports'][]='custom-fields';
    	return $args;
    	}

    re shortcode etc:
    you will have to edit the templates really (which you will probably have to do anyway if you want to display your custom fields somewhere)

    http://wordpress.org/plugins/wppizza/faq/
    -> can i edit the templates

    hope that helps (?)

  5. frogsplash
    Member
    Posted 5 months ago #

    BRILLIANT! Many thanks for the update and the code snippet.

  6. nostahl
    Member
    Posted 5 months ago #

    frogsplash can you tell me more about what your doing with the custom fields?

Reply

You must log in to post.

About this Plugin

About this Topic

Tags

No tags yet.