How to Upload Tracking for Shipped Items

  • Add together shipment tracking data to your orders
  • Provide customers with an easy way to rails their shipment
  • Integrates with major shipping providers and softwares

If you need a mode to hands add together shipment tracking details to orders in your WooCommerce store, then we've got the solution for you.

In this tutorial, we'll show you how to set up Shipment Tracking on your WooCommerce store. Shipment Tracking is an easy mode to permit customers to track their shipments.

It costs just $49 a year and supports over 15 of the world's major aircraft providers out of the box. Yes, that includes USPS, FedEx, UPS, and DHL. See the total aircraft provider listing.

The plugin also integrates with 3rd party tools like ShipStation, Shippo, ShippingEasy, and others.

For case, let's say yous want to use ShipStation and are trying to figure out how to connect with your WooCommerce shop. When a new shipment is created in ShipStation it will sync the tracking number back to WooCommerce and likewise update the gild in WooCommerce from Processing to Completed. Y'all will not have to manually add the tracking number for each shipment. I as well recommend turning off the notification email in ShipStation that sends to your customers. How come? The Completed Order email in WooCommerce will include the tracking number. But make sure you are using the free ShipStation plugin and the Shipment Tracking plugin and everything will exist integrated.

If you are more of a visual learner, see the video below that goes over how to do this! I also have another video at the lesser of the post that may exist helpful likewise!

Let'southward jump into it!

How to setup Shipment Tracking in WooCommerce

The start step is to purchase the Shipment Tracking plugin.

Next, download the .zip file and navigate to your WordPress dashboard.

So, become to Plugins, add a new plugin, and upload the .cypher file.

Finally, actuate the plugin. If you navigate to the WooCommerce Orders folio in your WooCommerce backend, yous will run across that the Shipment Tracking column has been added.

How to add a tracking number to an society

If you utilise ShipStation, Shippo, Shipping Easy, or another shipping platform they will automatically integrate with the Shipment Tracking plugin. For example, if a shipment is created in ShipStation information technology will automatically send the tracking number to WooCommerce and update the Gild Status from Processing to Completed and transport out the Completed Order electronic mail with the tracking number. Even so, if yous are curious how to add a tracking number or want to manually add a tracking number here is how to do and then.

– On your WooCommerce Orders page, click on a recent order.

– Adjacent, in the elevation righthand corner, click Add Tracking Number.

– Then, add the Provider and Tracking Number.

– Finally, click Save Tracking.

Finally, if y'all desire to permit your customer know that their guild has been shipped and provide an email notification with their tracking URL, simply update the order status from Processing  to Completed .

This will trigger the Completed Club Email to send to the client with your branding and includes a tracking number that is linked to USPS, FedEx, UPS, or whatever yous use as your shipping provider.

Hither is an case:

In addition, your customer will too be able to see their tracking number on the My Business relationship page.

For instance:

Pretty absurd eh!?

How can you lot automate this process further?

If you use a plugin such as ShippingEasy or ShipStation to impress off your labels, these aircraft tools will automatically POST back to your WooCommerce store with the tracking number.

Hither is how the process works:

  1. Customer orders a product on your store
  2. Orders that are "processing" volition be exported to ShipStation or ShippingEasy
  3. Shop director prints off label and ships product to the customer
  4. ShippingEasy or ShipStation POST back to your WooCommerce store and updates social club condition to "completed"
  5. Automated email goes out to the client that their shipment is on their way with tracking code available on the email

How to add shipment tracking from custom club meta

Y'all are trying to integrate a third political party integration (like Beloved Inventory) with the WooCommerce Shipment Tracking plugin.

Yet, the issue is that the _wc_shipment_tracking_items order meta is in an array.

I CANNOT specify the field name when it's inside an array.

Thus, we have to practice a workaround!

First, add together the following fields to your order meta data:

  • _tracking_number
  • _tracking_provider
  • _date_shipped

This will show up as order meta data in your WooCommerce Society, just non yet inside the meta key_wc_shipment_tracking_items.

woocommerce-shipment-tracking-dear-inventory-integration

Next, add together this snippet to your functions.php file:

          role auf_order_status_completed($order_id) {      if (class_exists('WC_Shipment_Tracking')) {      	if (function_exists('wc_st_add_tracking_number')) {      		$tracking_number = get_post_meta($order_id, '_tracking_number', true);     		$carrier = get_post_meta($order_id, '_tracking_provider', true);     		$timestamp = get_post_meta($order_id, '_date_shipped', truthful);     		 			wc_st_add_tracking_number($order_id, $tracking_number, $carrier, $timestamp);  		}     } }  add_action('woocommerce_order_status_completed', 'auf_order_status_completed', ten, 1 );        

This snippet updates the _wc_shipment_tracking_items order meta when the Club is shipped, based on your custom fields you defined.

Let me know if this snippet works for you!

How to return real-time rates to customers during Checkout?

If y'all want to return real time rates to your customers during the Checkout procedure, USPS, UPS, and FedEx accept separate plugins for that.

Customizations

To further meliorate the experience with the Shipment Tracking plugin, you'll want your customers to exist able to access their tracking info directly from the frontend of your site's My Account folio.

Let'southward look at how to set this up and then your customers tin run across the Rail Shipment link adjacent to their Orders.

First, edit your active WordPress theme via SFTP or SSH. I use FileZilla.

Next, create a 'woocommerce' binder inside your active WordPress theme if you accept non already. This will allow you to override core WooCommerce files.

And then, inside the /woocommerce/ binder, create some other binder titled 'myaccount'.

Next, open up the file inside your /woocommerce/myaccount/ folder called orders.php.

Edit your electric current orders.php file and search for the post-obit snippet on lines 56 and 57:

          // Search for this line of lawmaking in your orders.php file <?php elseif ( 'order-condition' === $column_id ) : ?> 	<?php echo esc_html( wc_get_order_status_name( $order->get_status() ) ); ?>                  

Replace with this snippet beneath:

          // replace with the following code below in your orders.php file <?php elseif ('gild-status' === $column_id) :  	$status = $society->get_status(); 	$column_output = "";  	// evidence tracking link 	if ($condition == 'completed' && class_exists('WC_Shipment_Tracking_Actions')) {  		$st_actions = WC_Shipment_Tracking_Actions::get_instance();  		if ($tracking_items = $st_actions->get_tracking_items($gild->get_id(), true)) {  			foreach ($tracking_items as $tracking_item) {  				if ($tracking_item['formatted_tracking_link'] !== '') {  					$column_output = sprintf("<a href='%s' target='_blank'>%southward</a>", 						$tracking_item['formatted_tracking_link'], __('Track Shipment', 'bdl'));  					break; 				} 			} 		} 	}  	if (empty($column_output)) 		$column_output = esc_html(wc_get_order_status_name($condition));  	echo $column_output; ?>                  

If you lot would rather merely supercede the entire orders.php file, copy the code beneath and supercede it.

          <?php /**  * Orders  *  * Shows orders on the account page.  */  divers( 'ABSPATH' ) || leave;  do_action( 'woocommerce_before_account_orders', $has_orders ); ?>  <?php if ( $has_orders ) : ?>  	<tabular array class="woocommerce-orders-table woocommerce-MyAccount-orders shop_table shop_table_responsive my_account_orders account-orders-table"> 		<thead> 			<tr> 				<?php foreach ( wc_get_account_orders_columns() as $column_id => $column_name ) : ?> 					<th course="woocommerce-orders-table__header woocommerce-orders-table__header-<?php echo esc_attr( $column_id ); ?>"><span class="nobr"><?php echo esc_html( $column_name ); ?></bridge></th> 				<?php endforeach; ?> 			</tr> 		</thead>  		<tbody> 			<?php 			foreach ( $customer_orders->orders as $customer_order ) { 				$gild      = wc_get_order( $customer_order ); // phpcs:ignore WordPress.WP.GlobalVariablesOverride.OverrideProhibited 				$item_count = $lodge->get_item_count() - $club->get_item_count_refunded(); 				?> 				<tr course="woocommerce-orders-table__row woocommerce-orders-table__row--status-<?php echo esc_attr( $order->get_status() ); ?> order"> 					<?php foreach ( wc_get_account_orders_columns() equally $column_id => $column_name ) : ?> 						<td class="woocommerce-orders-table__cell woocommerce-orders-table__cell-<?php echo esc_attr( $column_id ); ?>" data-title="<?php echo esc_attr( $column_name ); ?>"> 							<?php if ( has_action( 'woocommerce_my_account_my_orders_column_' . $column_id ) ) : ?> 								<?php do_action( 'woocommerce_my_account_my_orders_column_' . $column_id, $social club ); ?>  							<?php elseif ( 'guild-number' === $column_id ) : ?> 								<a href="<?php echo esc_url( $lodge->get_view_order_url() ); ?>"> 									<?php echo esc_html( _x( '#', 'hash earlier gild number', 'woocommerce' ) . $order->get_order_number() ); ?> 								</a>  							<?php elseif ( 'order-engagement' === $column_id ) : ?> 								<time datetime="<?php echo esc_attr( $club->get_date_created()->appointment( 'c' ) ); ?>"><?php echo esc_html( wc_format_datetime( $order->get_date_created() ) ); ?></time>  							<?php elseif ('social club-status' === $column_id) :  								$condition = $order->get_status(); 								$column_output = "";  								// show tracking link 								if ($status == 'completed' && class_exists('WC_Shipment_Tracking_Actions')) {  									$st_actions = WC_Shipment_Tracking_Actions::get_instance();  									if ($tracking_items = $st_actions->get_tracking_items($order->get_id(), true)) {  										foreach ($tracking_items every bit $tracking_item) {  											if ($tracking_item['formatted_tracking_link'] !== '') {  												$column_output = sprintf("<a href='%s' target='_blank'>%s</a>", 													$tracking_item['formatted_tracking_link'], __('Runway Shipment', 'bdl'));  												break; 											} 										} 									} 								}  								if (empty($column_output)) 									$column_output = esc_html(wc_get_order_status_name($status));  								echo $column_output; ?>  							<?php elseif ( 'order-total' === $column_id ) : ?> 								<?php 								/* translators: i: formatted order total 2: full order items */ 								echo wp_kses_post( sprintf( _n( '%1$s for %ii$due south item', '%i$s for %2$s items', $item_count, 'woocommerce' ), $order->get_formatted_order_total(), $item_count ) ); 								?>  							<?php elseif ( 'order-deportment' === $column_id ) : ?> 								<?php 								$actions = wc_get_account_orders_actions( $social club );  								if ( ! empty( $deportment ) ) { 									foreach ( $actions as $cardinal => $action ) { // phpcs:ignore WordPress.WP.GlobalVariablesOverride.OverrideProhibited 										echo '<a href="' . esc_url( $action['url'] ) . '" class="woocommerce-button push ' . sanitize_html_class( $key ) . '">' . esc_html( $action['name'] ) . '</a>'; 									} 								} 								?> 							<?php endif; ?> 						</td> 					<?php endforeach; ?> 				</tr> 				<?php 			} 			?> 		</tbody> 	</table>  	<?php do_action( 'woocommerce_before_account_orders_pagination' ); ?>  	<?php if ( 1 < $customer_orders->max_num_pages ) : ?> 		<div course="woocommerce-pagination woocommerce-pagination--without-numbers woocommerce-Pagination"> 			<?php if ( 1 !== $current_page ) : ?> 				<a class="woocommerce-button woocommerce-button--previous woocommerce-Button woocommerce-Push--previous button" href="<?php echo esc_url( wc_get_endpoint_url( 'orders', $current_page - 1 ) ); ?>"><?php esc_html_e( 'Previous', 'woocommerce' ); ?></a> 			<?php endif; ?>  			<?php if ( intval( $customer_orders->max_num_pages ) !== $current_page ) : ?> 				<a class="woocommerce-button woocommerce-push button--next woocommerce-Button woocommerce-Button--next button" href="<?php echo esc_url( wc_get_endpoint_url( 'orders', $current_page + 1 ) ); ?>"><?php esc_html_e( 'Side by side', 'woocommerce' ); ?></a> 			<?php endif; ?> 		</div> 	<?php endif; ?>  <?php else : ?> 	<div class="woocommerce-bulletin woocommerce-message--info woocommerce-Message woocommerce-Message--info woocommerce-info"> 		<a form="woocommerce-Button button" href="<?php echo esc_url( apply_filters( 'woocommerce_return_to_shop_redirect', wc_get_page_permalink( 'shop' ) ) ); ?>"> 			<?php esc_html_e( 'Go to the shop', 'woocommerce' ); ?> 		</a> 		<?php esc_html_e( 'No order has been made yet.', 'woocommerce' ); ?> 	</div> <?php endif; ?>  <?php do_action( 'woocommerce_after_account_orders', $has_orders ); ?>                  

Video Tutorials

Video 1

Video 2

Summary

The WooCommerce Shipment Tracking plugin is an easy-to-use plugin if y'all demand a solid way to allow your customers to track their shipments.

You tin use this plugin to allow your customers to track their order with the world's major shipping providers, ensuring your brand remains linked in their minds to a high-quality and professional person commitment service.

Additional Resources

  • Docs: WooCommerce Shipment Tracking plugin
  • ShippingEasy
  • ShipStation

clintonplase1950.blogspot.com

Source: https://simongondeck.com/setup-woocommerce-shipment-tracking/

0 Response to "How to Upload Tracking for Shipped Items"

Publicar un comentario

Iklan Atas Artikel

Iklan Tengah Artikel 1

Iklan Tengah Artikel 2

Iklan Bawah Artikel