How to customize track form labels?

Track-hook-result

Add the following codes in your child theme’s functions.php file.

Customize WPCargo Track form header label

add_filter('wpcargo_tn_form_title', function(){
	return 'My Sample header Label';
});

Customize WPCargo Track form sample text

add_filter('wpcargo_example_text', function(){
	$text = '<tr class="track_form_tr">';
	$text .= '<td class="track_form_td" colspan="2">';
	$text .= '<h4>Ex: MYSAMPLETEXT/h4>';
	$text .= '</td>';
	$text .= '</tr>';
	return $text;
});

Customize WPCargo Track form submit button label

add_action('wpcargo_tn_submit_val', function(){
	return 'FIND MY SHIPMENT';
});

Customize WPCargo Track form Additional information

add_action('wpcargo_add_form_fields', function(){
	$text = '<tr>';
	$text .= '<td>';
	$text .= 'Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Donec odio. Quisque volutpat mattis eros. Nullam malesuada erat ut turpis. Suspendisse urna nibh, viverra non, semper suscipit, posuere a, pede.';
	$text .= '</td>';
	$text .= '</tr>';
	echo $text;
});

Customize WPCargo Track form Placeholder information

add_filter('wpcargo_tn_placeholder', function(){
	return 'My Custom Placeholder';
});
0
    0
    Your Cart
    Your cart is emptyReturn to Shop