Created
January 22, 2018 07:05
-
-
Save andrewlimaza/3d10790c532585d825050cf69c89efea to your computer and use it in GitHub Desktop.
Show checkout time for Paid Memberships Pro invoices.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?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