invp_get_the_payment( int|null $post_ID = null )

invp_get_the_payment


Parameters Parameters

$post_ID

(int|null) (Optional) The post ID of a vehicle. Must be passed when using this method outside the loop.

Default value: null


Top ↑

Return Return

(string)


Top ↑

Source Source

File: includes/template-tags.php

736
737
738
739
740
741
742
743
744
745
746
747
function invp_get_the_payment( $post_ID = null ) {
    if ( invp_is_sold( $post_ID ) ) {
        return '';
    }
 
    $payment = INVP::get_meta( 'payment', $post_ID );
    if ( empty( $payment ) ) {
        return '';
    }
 
    return INVP::currency_symbol() . number_format( $payment, 0, '.', ',' );
}