Menu

#1 failed to open stream

open
nobody
None
5
2008-03-19
2008-03-19
repcode128
No

when loading http://localhost/phpready-0.2/

Warning: Smarty::include(phpReady/builder/tpl_compile\%%F7^F7F^F7F34188%%header.tpl.php) [function.Smarty-include]: failed to open stream: No such file or directory in C:\apache\htdocs\phpReady-0.2\phpReady\smarty\Smarty.class.php on line 1258

here's my fix:
in http://localhost/phpready-0.2/index.php

move line 45:
$dir = dirname($_SERVER['SCRIPT_FILENAME']);

to line 20 just after
session_start(); and added a trailing slash like so:

$dir = dirname($_SERVER['SCRIPT_FILENAME']).'/';

added the directory path to lines 38 & 39

from:
$smarty->template_dir = 'phpReady/builder/templates';
$smarty->compile_dir = 'phpReady/builder/tpl_compile';

to:
$smarty->template_dir = $dir.'phpReady/builder/templates';

$smarty->compile_dir = $dir.'phpReady/builder/tpl_compile';

now working as expected.

awesome code!! thanks so much...

Discussion


Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.