invp_get_the_carfax_url_report( int|null $post_ID = null )
Template tag. Returns a URL to a CARFAX vehicle history report.
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
Return Return
(string)
Source Source
File: includes/template-tags.php
function invp_get_the_carfax_url_report( $post_ID = null ) { $raw = INVP::get_meta( 'carfax_url_report', $post_ID ); if ( ! empty( $raw ) ) { return $raw; } /** * Fallback to the pre-August-2019 URLs, save for the partner * querystring parameter. */ return 'https://www.carfax.com/VehicleHistory/p/Report.cfx?vin=' . invp_get_the_VIN( $post_ID ); }
Expand full source codeCollapse full source codeView on Github