I would like to amend the best product price link that is referred to by this call:
<?php
print $product_bestPriceMerchants;
?>
I would like to have beneath the merchants name a button that allows us to take the customer to the site, as well as the textual link with the merchants name. What do I need to amend to make this happen?
Thanks as always, love this software and forum!
Chris
Hi Chris,
Thank you for your comments!
The $product_bestPriceMerchants HTML is constructed at the top of html/product.php. To create merchant name / Visit Store buttons (same as appear in price comparison table), look for the following code beginning at line 12:
$html = "<a href='".tapestry_buyURL($p)."'>".$p["merchant"]."</a>";
if ($p["voucher_code"])
{
$html .= " (".translate("using voucher code")." <span class='pt_pr_vouchercode'>".$p["voucher_code"]."</span>)";
}
$product_bestPriceMerchants[] = $html;
...and REPLACE with:
$html = "<li style='text-align:center;'>";
$html .= "<a href='".tapestry_buyURL($p)."'>".$p["merchant"]."</a>";
if ($p["voucher_code"])
{
$html .= " (".translate("using voucher code")." <span class='pt_pr_vouchercode'>".$p["voucher_code"]."</span>)";
}
$html .= "<br /><a class='button tiny radius success' href='".tapestry_buyURL($p)."'>".translate("Visit Store")."</a>";
$html .= "</li>";
$product_bestPriceMerchants[] = $html;
Then look for the following code at line 23:
$product_bestPriceMerchants = implode(", ",$product_bestPriceMerchants);
...and REPLACE with:
$product_bestPriceMerchants = "<ul class='small-block-grid-1 medium-block-grid-2'>".implode(", ",$product_bestPriceMerchants)."</ul>";
This uses Foundation's block-grid-n classes so that the merchants and buttons will be aligned neatly...
Hope this helps!
Cheers,
David.
--
PriceTapestry.com