Adding a pre-fix to tracking number for specific providers
-
We mainly use DPD UK and DHL to ship our products, DPD accounts for about 85% of our shipments and we have a four digit account number that is that is present at the start of our tracking numbers with them.
However, their system unhelpfully doesn’t provide tracking numbers with tis incorporated so we have to manually add it in each time we enter a tracking number.
This is quite an effort so I want to automate it.
I tried amendinding the
class-wc-advanced-shipment-tracking.php
file by adding our prefix as a value in the tracking number field but this creates a tracking number for every update of the order (for example when cancelling an order).`woocommerce_wp_text_input( array(
‘id’ => ‘tracking_number’,
‘label’ => __( ‘Tracking number:’, ‘woo-advanced-shipment-tracking’ ),
‘placeholder’ => ”,
‘description’ => ”,
// Pre-populate DPD account prefix
‘value’ => ‘1234’,
) );`Is there away to add the prefix in if DPD UK is selected in the
shipping provider
field.The page I need help with: [log in to see the link]
- The topic ‘Adding a pre-fix to tracking number for specific providers’ is closed to new replies.