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)
-   -   embedded static pages, html only? (https://forum.x-cart.com/showthread.php?t=8601)

ketok 07-23-2004 11:20 AM

embedded static pages, html only?
 
I would like to run a simple php photo gallery as an embedded page from within x-cart.

However, it appears that only .html embedded static pages are created. Is this correct?

Can someone point me in the right direction.

Big Thanks!

ian_fs 07-23-2004 12:29 PM

You can if you copy the home.tpl file and rename it something else eg, photo_gallery.tpl get rid of the line home_main.tpl, where that was you can put you php code etc.

The in the actual customer php which call the tpl files copy home.php rename it photo_gallery.php and replace the line

$smarty->display("customer/home.tpl");

with

$smarty->display("customer/photo_gallery.tpl");

this should allow you to have your photo gallery page but with the x-cart features as well.

hope that helps. sorry if it seems rather rushed.

jez

ketok 07-23-2004 01:28 PM

thanks for the reply. I follow all of that.

My next question is can I put php code directly in a .tpl page?
so on photo_gallery.tpl - in that area between:





do I simply insert all the php code?
or must I do an include.
What is the syntax for that?

Sorry, I've not mixed php and smarty before.

Jon 07-23-2004 02:20 PM

to use php code in smarty you can use

{php}
echo "here is my php code";
{/php}

In this case, you'd be better doing an include, or you could do a php include

{php}
include "file.php";
{/php}

adpboss 07-23-2004 02:32 PM

FunkyDunk has a simple gallery mod for X-Cart @ http://www.prodynamix.co.uk. I used it for a while and it is good for a simple mod.

ketok 07-25-2004 04:39 PM

Thanks Jon - that is just the info I need.

Thanks adpboss - I went ahead and ordered funkydunk's mod. Just what I was looking to do.


All times are GMT -8. The time now is 10:35 AM.

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