Skip to content

Instantly share code, notes, and snippets.

@andrewlimaza
Created January 22, 2018 07:05
Show Gist options
  • Star 2 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save andrewlimaza/3d10790c532585d825050cf69c89efea to your computer and use it in GitHub Desktop.
Save andrewlimaza/3d10790c532585d825050cf69c89efea to your computer and use it in GitHub Desktop.
Show checkout time for Paid Memberships Pro invoices.
<?php
/**
* Show the time of checkout on Paid Memberships Pro Invoices.
* Add this code to your PMPro Customizations Plugin - https://www.paidmembershipspro.com/create-a-plugin-for-pmpro-customizations/
* See date parameters available to adjust time/date - http://php.net/manual/en/function.date.php#refsect1-function.date-parameters
* www.paidmembershipspro.com
*/
function pmpro_time_for_invoice( $invoice ) {
echo '<li><strong>Time of Checkout: </strong>' . date_i18n( "H:i", $invoice->timestamp ) . '</li>';
}
add_action( 'pmpro_invoice_bullets_top', 'pmpro_time_for_invoice' );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment