This one has really got me stumped - I have tried for about a week now using various different sites for advice all to no avail.
I am trying to load (and run) Smarty on xampp. I have followed all the advice given but when I run https://localhost/index_1.php I get the following:
Warning: require(Smarty.class.php) [function.require]: failed to open stream: No such file or directory in C:\xampp\htdocs\index_1.php on line 13
Fatal error: require() [function.require]: Failed opening required 'Smarty.class.php' (include_path='.;C:\xampp\php\pear";.') in C:\xampp\htdocs\index_1.php on line 13
To explain what has happened so far:
1. Loaded Smarty as follows -
2. Loaded c:/xampp/htdocs/smarty/configs
3. Having checked the PHPInfo that this is the correct file I have edited c:/xampp/php/php.ini 'paths & Directories' -
include_path = ".;C:\xampp\php\pear\";".;C:\xampp\smarty\libs\"
4. Created c:/xampp/htdocs/index_1.php with the following code -
// load Smarty library
$smarty = new Smarty;
$smarty->template_dir = 'C:/xampp/htdocs/smarty/templates';
$smarty->config_dir = 'C:/xampp/htdocs/smarty/configs';
$smarty->cache_dir = 'C:/xampp/smarty/cache';
$smarty->compile_dir = 'C:/xampp/smarty/templates_c';
5. Created c:/xampp/htdocs/smarty/templates/index_1.tpl with the following code -
As I say, I have tried changing most of the parameters without any success and it is just about driving me round the bend. If anyone can see where I have gone wrong I would be very grateful.