Email/Print Templates

Email / Print template functions – Requires WPPizza v3.9.3+ wppizza_template_parameters / wppizza_template_markup (functions) query for a certain set of orders and return print or email template markup – according to template selected – for each order example : /********************************************************* * [get email or print template 

On (admin) order status update

Sending an email whenever you change the status of an order in WPPizza -> Orderhistory send an email (or whatever else it is you would like to do) when you change the status of an order in the order history wppizza_on_orderstatus_change @param: array (order details) 

Customise order id

A filter to further ( or use instead) modify the order number than is possible in WPPizza->Order Settings->Global Note, this will NOT change the entry in the db. Only in emails and order history. if you change this filter at any time later , the 

Gateway filters frontend

Conditionally display gateways if you wanted to disable a gateway conditionally (lets say no cash on delivery for non logged in users) you could add this to your themes functions.php wppizza_filter_gateways_orderpage @param: array @return: array example: add_filter(‘wppizza_filter_gateways_orderpage’, ‘my_custom_gateways_filter’); function my_custom_gateways_filter($gateways){ /* disable Cash on delivery 

Get (logged in) users previous order details

Gettings ome info about a logged in users previous orders programatically the ‘wp’ action hooks is only for demonstration purposes. you will probably want to use another action or filter hook as required /* change wp hook to whatever is appropriate */ add_action(‘wp’, ‘my_custom_loggedin_customer’); function 

Change prices of menu item(s) depending on day of week

Dynamically change menu items prices depending on weekday a filter to change menu items prices depending on day of week. To use in your theme’s functions.php using the wordpress standard get_post_metadata filter get_post_metadata (wordpress standard filter) @param: array @return: array example: /*** change “myprefix” occurences 

Prices output in loop

Dynamically change menu items prices display in loop an example to add “from” in front of a particular menu item’s price wppizza_filter_post_prices @param: array @param: obj @param: str @return: array example: add_filter(‘wppizza_filter_post_prices’, ‘myprefix_wppizza_item_prices’, 10, 3); function myprefix_wppizza_item_prices($prices, $post, $style) { /* add “from” before price 

Additional validation function

Adding additional validation functions to fields in WPPizza -> Order form There are a number of additional javascript validation functions in-built into the plugin. However, aside from the default ones you can already select you have to selectively enable the ones that are of use 

Changing post type arguments

Altering WPPizza custom post type and taxonomy labels and arguments there are several filters you can use to change the WPPizza custom post type as well as taxonomies labels, arguments. Please refer to WordPress codex regarding register_posttype and register_taxonomy. wppizza_filter_cpt_lbls filter wppizza custom post type 

Global WPPizza functions

Below you will find a number of globally available WPPizza related functions you could use in your own plugin development or for use in filters / actions wppizza_is_checkout (alias of wppizza_is_orderpage) determine if the current page the user is on is the WPPizza checkout page