Thread: New template
View Single Post
  #1  
Old 03-29-2003, 11:18 AM
 
maniac maniac is offline
 

Advanced Member
  
Join Date: Mar 2003
Posts: 97
 

Default New template

I finally figured out how to pass variables from php to smarty, however I'm stuck on one thing.

Here's what I did:

1. Created a simple php file that runs through a MySQL query and brings back a series of items from a news table - the db and table I'm accesing is totally independent from x-cart.

2. created a new smarty template that displays a simple table within my customer/home.tpl file.

What I want to do:

display the sql query file in the new smarty template I created.

What do I need to do to the php file?

What do I need to do to the smarty template file?

What do I need to do to the home.php and home.tpl files?

I have managed to pass all the variables I use on the sql query to the smarty template, I defined those in home.php ($smarty->asign...), I just can't get the smarty template to display the results of the query.

Thanks in advance.
Reply With Quote