Osclass forums

Support forums => General help => Topic started by: jack daniels on April 06, 2010, 10:34:22 pm

Title: undefined variable in theme (WIP)
Post by: jack daniels on April 06, 2010, 10:34:22 pm
The theme (horizontal nav) i have styled needs a little bit of Jazz for the homepage, so im trying to pull some database info to populate the homepage, but i keep hitting an undefined variable problem,

the variables i ned to define are $item from item.php and $a from category.php (both in the themes folder) on their respective pages they work flawlessly, once used on the homepage i get the undefined error, i have added them globally to the osclass/theme.php, this removes the undefined errors but does not populate the home.php page, anyone have any ideas?
Thanks
Title: Re: undefined variable in theme (WIP)
Post by: Juan Ramón on August 03, 2010, 07:08:19 pm
Hi,

Have you tried to require the php file in home.php? The code is:

Code: [Select]
require_once 'osclass/model/Item.php';
I hope it works fine to you.