I have a transactional email which resides here: System > Transactional Emails > Shipment Update
Here is what is inside of Shipment Update:
{{block type="core/template" template="email/header.phtml"}}
<h1 style="font-size:22px; font-weight:normal; line-height:22px; margin:0 0 11px 0;">Dear {{htmlescape var=$order.getCustomerName()}},</h1>
<p style="font-size:12px; line-height:16px; margin:0 0 10px 0;">
Your order # {{var order.increment_id}} has been shipped and now has a status of <strong>{{var order.getStatusLabel()}}</strong>.
</p>
<p style="font-size:12px; line-height:16px; margin:0 0 10px 0;">You can check the status of your order by
<a href="https://mystore.narvar.com/mystore/tracking/fedex?tracking_numbers=<?php echo $this->escapeHtml($_track->getTrackNumber()) ?>">Find tracking here</a>.
<p style="font-size:12px; line-height:16px; margin:0 0 10px 0;">{{var comment}}</p>
<p style="font-size:12px; line-height:16px; margin:0 0 10px 0;">
{{layout handle="sales_email_order_shipment_items" shipment=$shipment order=$order}}
</p>
<p style="font-size:12px; line-height:16px; margin:0 0 10px 0;">
{{block type='core/template' area='frontend' template='email/order/shipment/track.phtml' shipment=$shipment order=$order}}
</p>
<p style="font-size:12px; line-height:16px; margin:0;">
If you have any questions, please feel free to contact us at
<a href="mailto:{{config path='trans_email/ident_support/email'}}" style="color:#1E7EC8;">{{config path='trans_email/ident_support/email'}}</a>
or by phone at {{config path='general/store_information/phone'}}.
</p>
{{block type="core/template" template="email/footer.phtml"}}
I have a block type and file which correlates with the email above and it's located here: /email/order/shipment/track.phtml
<?php $_shipment=$this->getShipment() ?>
<?php $_order=$this->getOrder() ?>
<?php if ($_shipment && $_order && $_shipment->getAllTracks()): ?>
<table cellspacing="0" cellpadding="0" border="0" width="650" style="border:1px solid #EAEAEA;">
<thead>
<tr>
<th align="left" bgcolor="#EAEAEA" style="font-size:13px; padding:3px 9px"><?php echo $this->__('Shipped By') ?></th>
<th align="center" bgcolor="#EAEAEA" style="font-size:13px; padding:3px 9px"><?php echo $this->__('Tracking Number') ?></th>
<th align="center" bgcolor="#EAEAEA" style="font-size:13px; padding:3px 9px"><?php echo $this->__('Tracking URL') ?></th>
</tr>
</thead>
<tbody>
<?php $i=0; foreach ($_shipment->getAllTracks() as $_item): $i++ ?>
<tr <?php echo $i%2?'bgcolor="#F6F6F6"':'' ?>>
<td align="left" valign="top" style="padding:3px 9px"><?php echo $this->escapeHtml($_item->getTitle()) ?></td>
<td align="center" valign="top" style="padding:3px 9px"><?php echo $this->escapeHtml($_item->getNumber());//getConsignmentNumber()) ?></td>
<?php $trackUrl = "https://mystore.narvar.com/mystore/tracking/fedex?tracking_numbers=";?>
<td align="center" valign="top" style="padding:3px 9px"><a href="<?php echo $trackUrl. $_item->getNumber();?>" target="_blank"><?php echo $trackUrl. $_item->getNumber();?></a></td> </tr>
<?php endforeach ?>
</tbody>
</table>
<?php endif; ?>
I store the track_number in our DB. Please see image below.
My question is how do i set my variables in the on the end of this URL which will be going to a third party site.
<a href="https://mystore.narvar.com/mystore/tracking/fedex?tracking_numbers=<?php echo $this->escapeHtml($_track->getTrackNumber()) ?>">Find tracking here</a>.