Home / Admin / Company Field on Receipt
Duplicate Snippet

Embed Snippet on Your Site

Company Field on Receipt

Outputs the "Company" on the payment receipt.

Code Preview
php
<?php
function pw_cfm_company_field( $payment, $edd_receipt_args ) {
	/*
	 * TODO
	 *
	 * 1. Replace field label as appropriate
	 * 2. Replace "company" with the meta_key entered in Checkout Fields Manager
	 */
	?>
	<tr>
		<td><strong><?php esc_html_e( 'Company', 'edd' ); ?>:</strong></td>
		<td><?php echo edd_get_payment_meta( $payment->ID, 'company', true ); ?></td>
	</tr>
	<?php
}
add_action( 'edd_payment_receipt_after', 'pw_cfm_company_field', 10, 2 );

Comments

Add a Comment