You are here:  » A Few layout changes that might benefit others


A Few layout changes that might benefit others

Submitted by paullas on Sat, 2012-09-08 11:59 in

Just tought i would post here what david has sent me to change a few layout.

To limit the featured product titles to the first space after X characters... There is a built in function to do this already in pto_featured.php look for the following code at line 77:

  $each = str_replace("%PRODUCT_NAME%",$row->name,$each);

...and REPLACE with:

  $each = str_replace("%PRODUCT_NAME%",pto_common_substr($row->name,20),$each);

...for a 20 character+next space limit.

----------------------------------------------------------------------------------------

To change the more information and visit store text into images... The HTML generated by the plugin via the HTML section of wp-admin > Settings > PriceTapestry.org.

For example, you'll find the More Information link down in the Search Results / Each template:

  <nobr><a href='%PRODUCT_URL%'>More Information</a></nobr>

...where you can easily change this to be an image link, eg.

  <nobr><a href='%PRODUCT_URL%'><img src='/images/moreinfo.gf'
border='0' /></a></nobr>

Similarly, you'll find the Visit Store link in the Prices / Each template.

----------------------------------------------------------------------------------------------