Smarty using php Includes for poll
| From: | MishY | Date: | Mon, 01 Apr 2002 19:14:36 +0000 |
| Subject: | Smarty using php Includes for poll | ||
| Groups: | php.smarty.general | ||
| Request: | Send a blank email to php-smarty-general+get-3425@lists.php.net to get a copy of this message | ||
Hey,
I have a poll system that I would like to add to my templates.
<?php require 'c:/program files/apache/htdocs/poll/booth.php';
display_booth(1); ?>
Would be the normal way of calling it however if I were to add this to any
of my *.tpl files the poll isn't included.
If I then turn on PHP tags in tpl files in the smarty config file upon
requesting a page where the poll is meant to be there is nothing but "Unable
to connect to database".
I should stress that I KNOW the poll system works completely. Infact I have
it working on non-templatized pages.
Is there anyway for me to include what I need to include to get this poll
working through using smartys template system ?
This is what I have to add :
<?php require 'c:/program files/apache/htdocs/poll/booth.php';
display_booth(1); ?>
Any ideas, or suggestions would be greatly appreciated !! I have just spent
the best part of 3 hrs trying to get this thing working LOL :)
Thanks