phones[0]->internationalPrefix.$mobile_api_seller->phones[0]->nationalPrefix.$mobile_api_seller->phones[0]->number; $mobile_api_tel_formatted = '+'.$mobile_api_seller->phones[0]->internationalPrefix.' '.$mobile_api_seller->phones[0]->nationalPrefix.' '.$mobile_api_seller->phones[0]->number; $mobile_api_price = maybe_unserialize( get_post_meta( $post_id, 'mobile_api_price', true ) ); $mobile_api_condition = get_post_meta( $post_id, 'mobile_api_condition', true ); $mobile_api_mileage = get_post_meta( $post_id, 'mobile_api_mileage', true ); $mobile_api_power = get_post_meta( $post_id, 'mobile_api_power', true ); $mobile_api_fuel = get_post_meta( $post_id, 'mobile_api_fuel', true ); $mobile_api_gearbox = mobile_api_translate_data_value( get_post_meta( $post_id, 'mobile_api_gearbox', true ) ); $mobile_api_firstRegistration = get_post_meta( $post_id, 'mobile_api_firstRegistration', true ); $mobile_api_owner = get_post_meta( $post_id, 'mobile_api_numberOfPreviousOwners', true ); $mobile_api_mobile_url = get_post_meta( $post_id, 'mobile_api_detailPageUrl', true ); ?>
>
<?php the_title(); ?>
1 ) : ?>
<?php the_title(); ?>

consumerPriceGross, 0 ) ) ?> € '.sprintf( esc_html__( '%s (net)', 'ad-integration-for-mobile-de-api' ), esc_html( number_format_i18n( $mobile_api_price->consumerPriceNet, 2 ) ) ).', '.sprintf( esc_html__( '%s VAT', 'ad-integration-for-mobile-de-api' ), esc_html( round( $mobile_api_price->vatRate ).'%' ) ).''; } else echo ''.esc_html__( 'VAT not included', 'ad-integration-for-mobile-de-api' ).''; ?>

  • km
  • kW ( PS)
  • /

    values AS $mobile_api_feature ) $mobile_api_features[strtolower( str_replace( '_', '', $mobile_api_feature->name ) )] = $mobile_api_feature->description; foreach ( $mobile_api_metas as $mobile_api_key => $mobile_api_value ) : if ( !str_starts_with( $mobile_api_key, 'mobile_api' ) ) continue; $mobile_api_key = substr( $mobile_api_key, 11 ); // Remove post meta prefix 'mobile_api_' if ( in_array( $mobile_api_key, $mobile_api_meta_exclude ) || empty( reset( $mobile_api_value ) ) || reset( $mobile_api_value ) != 1 || $mobile_api_key == 'numberOfPreviousOwners' || !array_key_exists( strtolower( $mobile_api_key ), $mobile_api_features ) ) continue; ?>

$mobile_api_value ) : if ( !str_starts_with( $mobile_api_key, 'mobile_api' ) ) continue; $mobile_api_key = substr( $mobile_api_key, 11 ); // Remove post meta prefix 'mobile_api_' if ( in_array( $mobile_api_key, $mobile_api_meta_exclude ) || empty( reset( $mobile_api_value ) ) || ( reset( $mobile_api_value ) == 1 && $mobile_api_key != 'numberOfPreviousOwners' ) || ( $mobile_api_key == 'costModel' && !property_exists( unserialize( maybe_unserialize( reset( $mobile_api_value ) ) ), 'consumptionCosts' ) ) ) continue; ?>
'.wp_kses_post( mobile_api_get_data_hints( $mobile_api_key ) ).'
' : ''; ?>
consumptionPowerCombined ) echo number_format_i18n( $mobile_api_object->consumptionPowerCombined, 1 ).' '.esc_html( mobile_api_translate_consumption_unit( 'power' ) ); if ( $mobile_api_object->consumptionFuelCombined ) echo number_format_i18n( $mobile_api_object->consumptionFuelCombined, 1 ).' '.esc_html( mobile_api_translate_consumption_unit( 'fuel' ) ); else */ if ( $mobile_api_key == 'costModel' ) : $mobile_api_object = unserialize( $mobile_api_value ); echo '

'.esc_html__( 'Energy costs for 15,000 km annual mileage:', 'ad-integration-for-mobile-de-api' ).' '.esc_html( number_format_i18n( $mobile_api_object->consumptionCosts, 2 ) ).' € / '.esc_html__( 'year', 'ad-integration-for-mobile-de-api' ).'

'; if ( property_exists( $mobile_api_object, 'powerPrice' ) ) echo '

'.esc_html__( 'Electricity price:', 'ad-integration-for-mobile-de-api' ).' '.esc_html( number_format_i18n( $omobile_api_bject->powerPrice, 2 ) ).' €/kWh (⌀ '.intval( $mobile_api_object->consumptionPriceYear ).')

'; if ( property_exists( $mobile_api_object, 'fuelPrice' ) ) echo '

'.esc_html__( 'Fuel price:', 'ad-integration-for-mobile-de-api' ).' '.esc_html( number_format_i18n( $mobile_api_object->fuelPrice, 2 ) ).' €/l (⌀ '.intval( $mobile_api_object->consumptionPriceYear ).')

'; echo '

'.esc_html__( 'Motor vehicle tax:', 'ad-integration-for-mobile-de-api' ).' '.esc_html( number_format_i18n( $mobile_api_object->tax, 0 ) ).' €/'.esc_html__( 'year', 'ad-integration-for-mobile-de-api' ).'

'; ?>
'
'.esc_html( number_format_i18n( $mobile_api_object->co2Costs->middle->accumulated, 0 ) ).' €'.' '.sprintf( esc_html__( '(assuming an %1$s average CO₂ price of %2$d €/t)', 'ad-integration-for-mobile-de-api' ), esc_html__( 'medium', 'ad-integration-for-mobile-de-api' ), esc_html( number_format_i18n( $mobile_api_object->co2Costs->middle->basePrice, 0 ) ) ).'

'; // translators: %s is the level of the average CO₂ price echo '

'.esc_html( number_format_i18n( $mobile_api_object->co2Costs->low->accumulated, 0 ) ).' €'.' '.sprintf( esc_html__( '(assuming an %1$s average CO₂ price of %2$d €/t)', 'ad-integration-for-mobile-de-api' ), esc_html__( 'low', 'ad-integration-for-mobile-de-api' ), esc_html( number_format_i18n( $mobile_api_object->co2Costs->low->basePrice, 0 ) ) ).'

'; // translators: %s is the level of the average CO₂ price echo '

'.esc_html( number_format_i18n( $mobile_api_object->co2Costs->high->accumulated, 0 ) ).' €'.' '.sprintf( esc_html__( '(assuming an %1$s average CO₂ price of %2$d €/t)', 'ad-integration-for-mobile-de-api' ), esc_html__( 'high', 'ad-integration-for-mobile-de-api' ), esc_html( number_format_i18n( $mobile_api_object->co2Costs->high->basePrice, 0 ) ) ).'

'; elseif ( is_serialized( $mobile_api_value ) ) : $mobile_api_array = unserialize( $mobile_api_value ); foreach ( $mobile_api_array as $mobile_api_array_key => $mobile_api_array_value ) { if ( is_object( $mobile_api_array_value ) || $mobile_api_key == 'consumptions' ) { if ( $mobile_api_key == 'emissions' ) { $mobile_api_classes = array(); foreach ( $mobile_api_array as $mobile_api_emission ) { if ( property_exists( $mobile_api_emission, 'co2Class' ) ) $mobile_api_classes[] = $mobile_api_emission->co2Class; } if ( count( $mobile_api_classes ) > 1 ) $mobile_api_classes[] = reset( explode( '_', get_locale() ) ); if ( property_exists( $mobile_api_array_value, 'co2' ) ) : echo esc_html__( 'CO₂ emissions (combined):', 'ad-integration-for-mobile-de-api' ).' '.intval( $mobile_api_array_value->co2 ).' g/km'; echo ''.esc_attr( implode( '-', $mobile_api_classes ) ).''; endif; } elseif ( $mobile_api_key == 'wltpValues' ) { echo esc_html__( 'CO₂ emissions (combined):', 'ad-integration-for-mobile-de-api' ).' '.intval( $mobile_api_array_value ).' g/km'; } elseif ( $mobile_api_key == 'consumptions' ) { if ( $mobile_api_array_key == 'weightedCombinedFuel' ) echo '

'.esc_html__( 'Consumptions (weighted combined):', 'ad-integration-for-mobile-de-api' ).' '.esc_html( number_format_i18n( $mobile_api_array_value, 1 ) ).' '.esc_html( mobile_api_translate_consumption_unit( $mobile_api_array_key ) ); if ( $mobile_api_array_key == 'weightedCombinedPower' ) echo ' + '.esc_html( number_format_i18n( $mobile_api_array_value, 1 ) ).' '.esc_html( mobile_api_translate_consumption_unit( $mobile_api_array_key ) ).'

'; if ( is_object( $mobile_api_array_value ) && count( (array)$mobile_api_array_value ) ) { echo '

'; if ( count( get_object_vars( $mobile_api_array ) ) > 1 ) echo esc_html( mobile_api_translate_consumption_title( $mobile_api_array_key ) ).'
'; if ( !empty( $mobile_api_array_value->combined ) ) echo ''.esc_html( number_format_i18n( $mobile_api_array_value->combined, 1 ).' '.mobile_api_translate_consumption_unit( $mobile_api_array_key ).' '.__( 'combined', 'ad-integration-for-mobile-de-api' ) ).'
'; if ( !empty( $mobile_api_array_value->city ) ) echo esc_html( number_format_i18n( $mobile_api_array_value->city, 1 ).' '.mobile_api_translate_consumption_unit( $mobile_api_array_key ).' '.__( 'City', 'ad-integration-for-mobile-de-api' ) ).'
'; if ( !empty( $mobile_api_array_value->suburban ) ) echo esc_html( number_format_i18n( $mobile_api_array_value->suburban, 1 ).' '.mobile_api_translate_consumption_unit( $mobile_api_array_key ).' '.__( 'Suburban', 'ad-integration-for-mobile-de-api' ) ).'
'; if ( !empty( $mobile_api_array_value->rural ) ) echo esc_html( number_format_i18n( $mobile_api_array_value->rural, 1 ).' '.mobile_api_translate_consumption_unit( $mobile_api_array_key ).' '.__( 'Rural', 'ad-integration-for-mobile-de-api' ) ).'
'; if ( !empty( $mobile_api_array_value->highway ) ) echo esc_html( number_format_i18n( $mobile_api_array_value->highway, 1 ).' '.mobile_api_translate_consumption_unit( $mobile_api_array_key ).' '.__( 'Highway', 'ad-integration-for-mobile-de-api' ) ).'

'; } } } elseif ( $mobile_api_key == 'dimension' ) { if ( $mobile_api_array_key == 'length' ) echo esc_html__( 'Length:', 'ad-integration-for-mobile-de-api' ).' '.esc_html( number_format_i18n( $mobile_api_array_value, 0 ) ).' mm'.'
'; if ( $mobile_api_array_key == 'width' ) echo esc_html__( 'Width:', 'ad-integration-for-mobile-de-api' ).' '.esc_html( number_format_i18n( $mobile_api_array_value, 0 ) ).' mm'.'
'; if ( $mobile_api_array_key == 'height' ) echo esc_html__( 'Height:', 'ad-integration-for-mobile-de-api' ).' '.esc_html( number_format_i18n( $mobile_api_array_value, 0 ) ).' mm'.'
'; } else echo esc_html( mobile_api_translate_data_value( $mobile_api_array_value ) ).'
'; } else : if ( $mobile_api_key == 'mileage' || $mobile_api_key == 'range' || $mobile_api_key == 'equivalentAllElectricRange' ) echo esc_html( number_format_i18n( $mobile_api_value, 0 ) ).' km'; elseif ( $mobile_api_key == 'power' ) echo esc_html( $mobile_api_value ).' kW ('.intval( round( $mobile_api_value * 1.35962 ) ).' PS)'; elseif ( $mobile_api_key == 'firstRegistration' ) echo esc_html( substr( $mobile_api_value, 4, 6 ) ).'/'.esc_html( substr( $mobile_api_value, 0, -2 ) ); elseif ( $mobile_api_key == 'cubicCapacity' ) echo esc_html( number_format_i18n( mobile_api_translate_data_value( $mobile_api_value, 0 ) ) ).' cm³'; elseif ( $mobile_api_key == 'fuelTankVolume' ) echo esc_html( number_format_i18n( mobile_api_translate_data_value( $mobile_api_value, 0 ) ) ).' l'; elseif ( $mobile_api_key == 'batteryCapacity' ) echo esc_html( number_format_i18n( mobile_api_translate_data_value( $mobile_api_value, 0 ) ) ).' kWh'; elseif ( $mobile_api_key == 'weight' || $mobile_api_key == 'trailerLoadBraked' || $mobile_api_key == 'trailerLoadUnbraked' || $mobile_api_key == 'licensedWeight' || $mobile_api_key == 'maxNoseWeight' ) echo esc_html( number_format_i18n( mobile_api_translate_data_value( $mobile_api_value, 0 ) ) ).' kg'; elseif ( $mobile_api_key == 'deliveryPeriod' ) { // translators: %d is the availability in months from order echo sprintf( esc_html__( 'Available in %d months from order', 'ad-integration-for-mobile-de-api' ), intval( $mobile_api_value / 30 ) ); } elseif ( $mobile_api_key == 'lastMaintenanceDate' ) echo esc_html( explode( '-', $mobile_api_value )[1].'/'.explode( '-', $mobile_api_value )[0] ); elseif ( $mobile_api_key == 'generalInspection' ) echo esc_html( $mobile_api_value[4].$mobile_api_value[5].'/'.$mobile_api_value[0].$mobile_api_value[1].$mobile_api_value[2].$mobile_api_value[3] ); elseif ( is_string( $mobile_api_value ) ) echo esc_html( mobile_api_translate_data_value( $mobile_api_value ) ); endif; ?>

View vehicle on mobile.de.', 'ad-integration-for-mobile-de-api' ) ), esc_url( $mobile_api_mobile_url ) ) ?>

companyName ) ?>
email ) ?>
address->street ) ?>
address->country ) ?>-address->zipcode ) ?> address->city ) ?>