Code Comments
Programming Forum and web based access to our favorite programming groups.Thanks, it is www-data but this is what it was before. I have set up the
following simple script as a test:
//php code -----------------------------------------------------------
<?php
include('/usr/share/php/smarty/libs/Smarty.class.php');
// create object
$smarty =3D new Smarty;
//config
$smarty->template_dir =3D
'/var/www/ioc3.unesco.org/www/apps/test/templates/';
$smarty->compile_dir =3D
'/var/www/ioc3.unesco.org/www/apps/test/templates_c/';
$smarty->cache_dir =3D '/var/www/ioc3.unesco.org/www/apps/test/cache/';
$smarty->config_dir =3D =
'/var/www/ioc3.unesco.org/www/apps/test/configs/';
// display it
$smarty->display('index.tpl');?>
//end code -----------------------------------------------------------
The index.tpl file contains only:
'This is a test'
I have also executed (to be sure):
Chown -R www-data /var/www/myserver.com/www/apps/test
Chmod 777 -r /var/www/myserver.com/www/apps/test
Still cannot read resource! Is there any way I can alter Smarty.class to
get a full path/name for the template it is going for?
Ben
-----Original Message-----
From: Riviere Informatique SARL [mailto:svdb
@rivinfo.com]=20
Sent: 14 April 2005 14:07
To: Sims, Benjamin
Cc: smarty-general@lists.php.net
Subject: Re: [SMARTY] Upgrade to debian testing breaks smarty sites
Hi Benjamin,
Check the access rights on the template directories and files. The user
running your apache server may have changed. Go to /etc/apache and check
the values of 'User' and 'Group' in the=20
httpd.conf file (I believe the default is www-data).
(Or do a 'ps -ef | grep apache')
Regards,
Steven.
Sims, Benjamin wrote:
>I've had a rather catastrophic failure upgrading from Debian stable to=20
>testing (ie to PHP 4.3.3 and apache 1.3).
>
>I now receive a "Warning: Smarty error: unable to read resource:=20
>"index.tpl" in /usr/share/php/smarty/libs/Smarty.class.php on line=20
>1088" when accessing the home page.
>
>The templates are in the same place as before, but it seems they can no
>longer be read.
>
>Any ideas much appreciated!
>
>Benjamin
>
> =20
>
Post Follow-up to this message
Show a Printable Version
Email This Page to Someone!
Receive updates to this thread
Powered by vBulletin
Copyright 2000-2006 Jelsoft Enterprises Limited.