How to create your own result template

[vc_row][vc_column][vc_row_inner][vc_column_inner width=”1/4″][vc_widget_sidebar sidebar_id=”sidebar_3″][/vc_column_inner][vc_column_inner width=”3/4″][vc_column_text]

How to create your own result template

WPCargo has already have a hooks that are very useful for developers.

There are two types of Hooks, the filters and actions
For more info about hooks please visit the WordPress Codex

 

On WPCargo Custom Field there is a file name “wpc-cf-hooks.php” you can see it on wpcargo-custom-field-addons/classes/wpc-cf-hooks.php

There is a action hook called wpcargo_track_shipper_details and wpcargo_track_shipment_details
wpcargo_track_shipper_details
is the shipper and receiver details on results and wpcargo_track_shipment_details is the shipment details on results. We can remove it by using remove_action
[/vc_column_text][vc_raw_js]JTNDc2NyaXB0JTIwc3JjJTNEJTIyaHR0cHMlM0ElMkYlMkZnaXN0LmdpdGh1Yi5jb20lMkZ2aXJ0dW9zb21hc3RlciUyRmNlZTYxNmFjNmVmMDVlOTk5Nzc3Mzk2N2JhNzIzZGMxLmpzJTIyJTNFJTNDJTJGc2NyaXB0JTNF[/vc_raw_js][vc_column_text]After removing the hooks, you can now add the function for your results and make sure to put it on your theme function file.
You can view other wpcargo meta_key on you admin dashboard > WPCargo > Manage Form Fields[/vc_column_text][vc_raw_html]JTNDc2NyaXB0JTIwYXN5bmMlMjBzcmMlM0QlMjIlMkYlMkZwYWdlYWQyLmdvb2dsZXN5bmRpY2F0aW9uLmNvbSUyRnBhZ2VhZCUyRmpzJTJGYWRzYnlnb29nbGUuanMlMjIlM0UlM0MlMkZzY3JpcHQlM0UlMEElM0NpbnMlMjBjbGFzcyUzRCUyMmFkc2J5Z29vZ2xlJTIyJTBBJTIwJTIwJTIwJTIwJTIwc3R5bGUlM0QlMjJkaXNwbGF5JTNBYmxvY2slM0IlMjB0ZXh0LWFsaWduJTNBY2VudGVyJTNCJTIyJTBBJTIwJTIwJTIwJTIwJTIwZGF0YS1hZC1sYXlvdXQlM0QlMjJpbi1hcnRpY2xlJTIyJTBBJTIwJTIwJTIwJTIwJTIwZGF0YS1hZC1mb3JtYXQlM0QlMjJmbHVpZCUyMiUwQSUyMCUyMCUyMCUyMCUyMGRhdGEtYWQtY2xpZW50JTNEJTIyY2EtcHViLTA1MDY1Mzg0MjY0NTY4NzclMjIlMEElMjAlMjAlMjAlMjAlMjBkYXRhLWFkLXNsb3QlM0QlMjIxNjk0OTc1MjIyJTIyJTNFJTNDJTJGaW5zJTNFJTBBJTNDc2NyaXB0JTNFJTBBJTIwJTIwJTIwJTIwJTIwJTI4YWRzYnlnb29nbGUlMjAlM0QlMjB3aW5kb3cuYWRzYnlnb29nbGUlMjAlN0MlN0MlMjAlNUIlNUQlMjkucHVzaCUyOCU3QiU3RCUyOSUzQiUwQSUzQyUyRnNjcmlwdCUzRQ==[/vc_raw_html][/vc_column_inner][/vc_row_inner][/vc_column][/vc_row]

How to remove Receiver and Shipper information in shipment tracking Result

[vc_row][vc_column width=”1/4″][vc_widget_sidebar sidebar_id=”sidebar_3″][/vc_column][vc_column width=”3/4″][vc_column_text]

How to remove Receiver  and Shipper information in  shipment tracking Result

Each of these snippets can be inserted in your theme/child themes functions.php file.[/vc_column_text][vc_raw_js]JTNDc2NyaXB0JTIwc3JjJTNEJTIyaHR0cHMlM0ElMkYlMkZnaXN0LmdpdGh1Yi5jb20lMkZ2aXJ0dW9zb21hc3RlciUyRjQ1ZmVhZGFkMDFmODU5YWVmOWUxZmY5OGE5YjI3ZmE5LmpzJTIyJTNFJTNDJTJGc2NyaXB0JTNF[/vc_raw_js][vc_raw_html]JTNDc2NyaXB0JTIwYXN5bmMlMjBzcmMlM0QlMjIlMkYlMkZwYWdlYWQyLmdvb2dsZXN5bmRpY2F0aW9uLmNvbSUyRnBhZ2VhZCUyRmpzJTJGYWRzYnlnb29nbGUuanMlMjIlM0UlM0MlMkZzY3JpcHQlM0UlMEElM0NpbnMlMjBjbGFzcyUzRCUyMmFkc2J5Z29vZ2xlJTIyJTBBJTIwJTIwJTIwJTIwJTIwc3R5bGUlM0QlMjJkaXNwbGF5JTNBYmxvY2slM0IlMjB0ZXh0LWFsaWduJTNBY2VudGVyJTNCJTIyJTBBJTIwJTIwJTIwJTIwJTIwZGF0YS1hZC1sYXlvdXQlM0QlMjJpbi1hcnRpY2xlJTIyJTBBJTIwJTIwJTIwJTIwJTIwZGF0YS1hZC1mb3JtYXQlM0QlMjJmbHVpZCUyMiUwQSUyMCUyMCUyMCUyMCUyMGRhdGEtYWQtY2xpZW50JTNEJTIyY2EtcHViLTA1MDY1Mzg0MjY0NTY4NzclMjIlMEElMjAlMjAlMjAlMjAlMjBkYXRhLWFkLXNsb3QlM0QlMjIxNjk0OTc1MjIyJTIyJTNFJTNDJTJGaW5zJTNFJTBBJTNDc2NyaXB0JTNFJTBBJTIwJTIwJTIwJTIwJTIwJTI4YWRzYnlnb29nbGUlMjAlM0QlMjB3aW5kb3cuYWRzYnlnb29nbGUlMjAlN0MlN0MlMjAlNUIlNUQlMjkucHVzaCUyOCU3QiU3RCUyOSUzQiUwQSUzQyUyRnNjcmlwdCUzRQ==[/vc_raw_html][/vc_column][/vc_row]

How to manually change text in WPCargo Track & Trace

[vc_row][vc_column width=”1/3″][vc_widget_sidebar sidebar_id=”sidebar_3″][/vc_column][vc_column width=”2/3″][vc_column_text]

Use the gettext filter to change any translatable string in WPCargo Track & Trace

We added the “apply filter”  to change the other Title’s on Admin and Search Results

For Example on your shipment at the admin page
Add-shipment

If you want to change the Title you can use add_filter Hook.

add_filter('change_shipper_information','function_here');

add_filter('change_receiver_information','function_here');

add_filter('change_shipment_information','function_here');

 

For example on your function.php
[/vc_column_text][vc_raw_js]JTNDc2NyaXB0JTIwc3JjJTNEJTIyaHR0cHMlM0ElMkYlMkZnaXN0LmdpdGh1Yi5jb20lMkZ2aXJ0dW9zb21hc3RlciUyRjk4YjI2YThkYzM4M2Y4M2QzNzkyZTBjMGY4MDg3ZTA4LmpzJTIyJTNFJTNDJTJGc2NyaXB0JTNF[/vc_raw_js][vc_column_text]
edit-title-shipment

 

Sample Hooks Tags

Admin

change_shipper_information –  Change the “Shipper Information” Text

change_receiver_information – Change the “Receiver Information” Text

change_shipment_information – Change the “Shipment Information” Text

 

Result Page

result_tracking_num – Change the “Tracking Number” Text

result_shipper_address – Change the “Shipper Address” Text

result_receiver_address – Change the “Receiver Address” Text

 

Shipment History

shipment_history_title – Change the “History Title”

results_history_date – Change the “Date” Text

results_history_time – Change the “Time” Text

results_history_location –  Change the “Location” Text

results_history_status – Change the “Status” Text

results_history_remarks – Change the “Remarks” Text

Guide

wpcargo-track-result[/vc_column_text][vc_raw_html]JTNDc2NyaXB0JTIwYXN5bmMlMjBzcmMlM0QlMjIlMkYlMkZwYWdlYWQyLmdvb2dsZXN5bmRpY2F0aW9uLmNvbSUyRnBhZ2VhZCUyRmpzJTJGYWRzYnlnb29nbGUuanMlMjIlM0UlM0MlMkZzY3JpcHQlM0UlMEElM0NpbnMlMjBjbGFzcyUzRCUyMmFkc2J5Z29vZ2xlJTIyJTBBJTIwJTIwJTIwJTIwJTIwc3R5bGUlM0QlMjJkaXNwbGF5JTNBYmxvY2slM0IlMjB0ZXh0LWFsaWduJTNBY2VudGVyJTNCJTIyJTBBJTIwJTIwJTIwJTIwJTIwZGF0YS1hZC1sYXlvdXQlM0QlMjJpbi1hcnRpY2xlJTIyJTBBJTIwJTIwJTIwJTIwJTIwZGF0YS1hZC1mb3JtYXQlM0QlMjJmbHVpZCUyMiUwQSUyMCUyMCUyMCUyMCUyMGRhdGEtYWQtY2xpZW50JTNEJTIyY2EtcHViLTA1MDY1Mzg0MjY0NTY4NzclMjIlMEElMjAlMjAlMjAlMjAlMjBkYXRhLWFkLXNsb3QlM0QlMjIxNjk0OTc1MjIyJTIyJTNFJTNDJTJGaW5zJTNFJTBBJTNDc2NyaXB0JTNFJTBBJTIwJTIwJTIwJTIwJTIwJTI4YWRzYnlnb29nbGUlMjAlM0QlMjB3aW5kb3cuYWRzYnlnb29nbGUlMjAlN0MlN0MlMjAlNUIlNUQlMjkucHVzaCUyOCU3QiU3RCUyOSUzQiUwQSUzQyUyRnNjcmlwdCUzRQ==[/vc_raw_html][/vc_column][/vc_row]