Haier HFR5719ENMG Frigorifero 4 Porte 446Lt Silver Nofrost
IDENTIFICATIVE | ||||||||||||||||||||||||||||||||||||||||||||||||
| ||||||||||||||||||||||||||||||||||||||||||||||||
STRUTTURALI | ||||||||||||||||||||||||||||||||||||||||||||||||
| ||||||||||||||||||||||||||||||||||||||||||||||||
FUNZIONALI | ||||||||||||||||||||||||||||||||||||||||||||||||
| ||||||||||||||||||||||||||||||||||||||||||||||||
FISICHE | ||||||||||||||||||||||||||||||||||||||||||||||||
| ||||||||||||||||||||||||||||||||||||||||||||||||
ENERGETICHE | ||||||||||||||||||||||||||||||||||||||||||||||||
|
add_filter( 'rank_math/json_ld', function( $data, $jsonld ) { if ( empty( $data['richSnippet'] ) || ! in_array( $data['richSnippet']['@type'], [ 'Product', 'ProductGroup' ] ) ) { return $data; } $data['shippingDetails'] = [ '@context' => 'https://schema.org/', '@type' => 'OfferShippingDetails', '@id' => '#shipping_policy', 'deliveryTime' => [ '@type' => 'ShippingDeliveryTime', 'handlingTime' => [ '@type' => 'QuantitativeValue', 'minValue' => 0, 'maxValue' => 1, 'unitCode' => 'DAY', ], 'transitTime' => [ '@type' => 'QuantitativeValue', 'minValue' => 1, 'maxValue' => 3, 'unitCode' => 'DAY' ], ], 'shippingRate' => [ '@type' => 'MonetaryAmount', 'value' => 7.9 'currency' => 'EUR', ], 'shippingDestination' => [ '@type' => 'DefinedRegion', 'addressCountry' => 'IT' ] ]; $data['hasMerchantReturnPolicy'] = [ '@context' => 'https://schema.org/', '@type' => 'MerchantReturnPolicy', '@id' => '#merchant_policy', 'applicableCountry' => 'IT', 'returnPolicyCountry' => 'IT', 'returnPolicyCategory' => 'https://schema.org/MerchantReturnFiniteReturnWindow', 'merchantReturnDays' => 14, 'returnMethod' => 'https://schema.org/ReturnByMail', 'returnFees' => 'https://schema.org/FreeReturn' ]; if ( 'Product' === $data['richSnippet']['@type'] ) { $data['richSnippet']['offers']['shippingDetails'] = [ '@id' => '#shipping_policy' ]; $data['richSnippet']['offers']['hasMerchantReturnPolicy'] = ['@id' => '#merchant_policy']; return $data; } if ( empty( $data['richSnippet']['hasVariant'] ) ) { return $data; } foreach ( $data['richSnippet']['hasVariant'] as $key => $value ) { if ( empty( $value['offers'] ) ) { continue; } $data['richSnippet']['hasVariant'][ $key ]['offers']['shippingDetails'] = [ '@id' => '#shipping_policy' ]; $data['richSnippet']['hasVariant'][ $key ]['offers']['hasMerchantReturnPolicy'] = [ '@id' => '#merchant_policy' ]; } return $data; }, 99, 2);