X-Cart: shopping cart software

X-Cart forums (https://forum.x-cart.com/index.php)
-   Changing design (https://forum.x-cart.com/forumdisplay.php?f=51)
-   -   Including Templates (.tpl) in Product Descriptions, how? (https://forum.x-cart.com/showthread.php?t=17334)

1day2004 10-16-2005 08:32 PM

Including Templates (.tpl) in Product Descriptions, how?
 
Anyone have an idea how can I include templates (.tpl) files in the product pages?

I want to place the template in the "Detailed Descriptions" section.

I've tried "{include file="customer/main/file.tpl"} but it did not work.
It just displays the text as is: "{include file="customer/main/file.tpl"}

If it's not possible to include .tpl files, is it possible to do a php include in the "Detailed Descriptions"?

Thanks

kpayne 10-16-2005 10:05 PM

You need to change your skin1/customer/main/product.tpl template.

Find this code:

Code:

{if $product.fulldescr ne ""}{$product.fulldescr}{else}{$product.descr}{/if}

And change it to this code:

Code:

{if $product.fulldescr ne ""}{eval var=$product.fulldescr}{else}{eval var=$product.descr}{/if}

This is untested, but should work for you.

1day2004 10-18-2005 10:26 AM

That didn't work.

I received this error message when I visited the product pages:

Fatal error: Smarty error: [in evaluated template line 90]: syntax error: unrecognized tag 'return' (Smarty_Compiler.class.php, line 564) in /home/user/websitename-www/Smarty-2.6.3/Smarty.class.php on line 1082

Thanks for the suggestion though. Anyone have any other ideas?


All times are GMT -8. The time now is 02:16 PM.

Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.