Posted: Mon 13. Dec 2004, 11:47
ups try this frontlogin[/url]
The phpwcms support forum will help to find answers to your questions. The small but strong community is here since more than 10 years.
https://forum.phpwcms.org/
Ok, this files needed custom_front_func_inc.php:pyhavaim wrote:ups try this frontlogin
Code: Select all
Warning: main(custom/custom_front_func_inc.php): failed to open stream: No such file or directory in c:\var\www\fl\include\inc_front\content.func.inc.php on line 35
Fatal error: main(): Failed opening required 'custom/custom_front_func_inc.php' (include_path='.;c:\php4\pear') in c:\var\www\fl\include\inc_front\content.func.inc.php on line 35
Overwriten all files, and come back this (in source, after login form submit):pyhavaim wrote:ups. Basically you didn't need that, it has been long time since I written this hack, but here is frontlogin 1.1
Code: Select all
<form name="login_formular" method="post" action="http://localhost/fl/fl/frm_Login.php?" autocomplete="off">
<tr><td width="389" class="title"></td></tr>
<tr><td><img src="http://localhost/fl/img/leer.gif" width="1" height="12"></td></tr>
<tr><td class="v10">:</td></tr>
<tr><td><input name="form_loginname" type="text" id="form_loginname" class="f11b" style="width:250px;" size="30" maxlength="30" value="<br />
<b>Fatal error</b>: Call to undefined function: html_specialchars() in <b>c:\var\www\fl\frm_login.php</b> on line <b>14</b><br />
<br /><img src="img/leer.gif width="1" height="20" alt="" /><br />
Code: Select all
$_SERVER['DOCUMENT_ROOT'] = '.';
pyhavaim wrote:Well it seems that you have a config problem.
in include\inc_conf\conf.inc.php what are your constants in this file?
Take a look at if there is a constant like thisCode: Select all
$_SERVER['DOCUMENT_ROOT'] = '.';
Code: Select all
Warning: main(./fl/include/inc_front/content.article.inc.php): failed to open stream: No such file or directory in c:\var\www\fl\include\inc_front\content.func.inc.php on line 200
Warning: main(): Failed opening './fl/include/inc_front/content.article.inc.php' for inclusion (include_path='.;c:\php4\pear') in c:\var\www\fl\include\inc_front\content.func.inc.php on line 200
Code: Select all
.
.
.
// site values
$phpwcms["site"] = "http://localhost/";
$phpwcms["admin_email"] = "pal.palocz@is-energy.hu";
// paths
$phpwcms["root"] = "fl"; //default: ""
.
.
.
// Try to check and uncomment the DOCUMENT_ROOT if you have problems
// often neccessary on IIS or default MacOS X webserver settings
// Do not use backslash "" on Windows - always replace "" by "/"
$_SERVER['DOCUMENT_ROOT'] = '.';
Code: Select all
.
.
.
// site values
$phpwcms["site"] = "http://localhost/";
$phpwcms["admin_email"] = "pal.palocz@is-energy.hu";
// paths
$phpwcms["root"] = "fl"; //default: ""
.
.
.
// Try to check and uncomment the DOCUMENT_ROOT if you have problems
// often neccessary on IIS or default MacOS X webserver settings
// Do not use backslash "\" on Windows - always replace "\" by "/"
//$_SERVER['DOCUMENT_ROOT'] = '.';
Code: Select all
<form name="login_formular" method="post" action="http://localhost/fl/fl/frm_Login.php?" autocomplete="off">
<tr><td width="389" class="title"></td></tr>
<tr><td><img src="http://localhost/fl/img/leer.gif" width="1" height="12"></td></tr>
<tr><td class="v10">:</td></tr>
<tr><td><input name="form_loginname" type="text" id="form_loginname" class="f11b" style="width:250px;" size="30" maxlength="30" value="<br />
<b>Fatal error</b>: Call to undefined function: html_specialchars() in <b>c:\var\www\fl\frm_login.php</b> on line <b>14</b><br />
<br /><img src="img/leer.gif width="1" height="20" alt="" /><br />Bejelentkezés. Kérjük adja meg felhasználónevét és jelszavát!</p>
document_root.php:Pappnase wrote:hello paal
please call your document_root.php and look what the server root is.
then edit your conf.inc.php
Code: Select all
<?php
/*************************************************************************************
Copyright notice
(c) 2002-2003 Oliver Georgi (oliver@phpwcms.de) // All rights reserved.
This script is part of PHPWCMS. The PHPWCMS web content management system is
free software; you can redistribute it and/or modify it under the terms of
the GNU General Public License as published by the Free Software Foundation;
either version 2 of the License, or (at your option) any later version.
The GNU General Public License can be found at http://www.gnu.org/copyleft/gpl.html
A copy is found in the textfile GPL.txt and important notices to the license
from the author is found in LICENSE.txt distributed with these scripts.
This script is distributed in the hope that it will be useful, but WITHOUT ANY
WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A
PARTICULAR PURPOSE. See the GNU General Public License for more details.
This copyright notice MUST APPEAR in all copies of the script!
*************************************************************************************/
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<title>phpwcms DOCUMENT_ROOT test</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-2"><style type="text/css">
<!--
body,td,th {
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 12px;
color: #000000;
}
body { background-color: #FFFFFF;}
h1 {font-size: 24px;}
h2 {font-size: 21px;}
pre {font-size: 14px;}
-->
</style></head>
<body>
<h2>phpwcms DOCUMENT_ROOT test</h2>
<p>This file has to be placed in your web root - do not <br>put it into any subdir of your webspace</p>
<?php
$doc_root = str_replace("\", '/', $_SERVER['DOCUMENT_ROOT']);
echo "<pre>";
echo '1) your default $_SERVER[\'DOCUMENT_ROOT\']: <span style="color:#009933">'.$doc_root;
echo "</span>\n";
echo '2) real DOCUMENT_ROOT based on this file : <span style="color:#CC3300">';
$path = preg_replace('/(.*)[\/|\\\].(.*)/', '$1', $_SERVER['PATH_TRANSLATED']);
echo $path;
echo "</span></pre>";
?>
If <strong>(1)</strong> and <strong>(2)</strong> not equal then add following<br>
line at the end of your <strong>conf.inc.php</strong> but before ending "?>":
<pre style="color:#CC3300">
$_SERVER['DOCUMENT_ROOT'] = '<?php echo $path ?>';
</pre>
Check if this is corresponding with the subdir<br>
in which phpwcms is installed:
<pre style="color:#CC3300">$phpwcms['root'] = "<?php
$subdir = str_replace($doc_root, '', $path);
if(trim($subdir)) {
echo preg_replace('/^\/(.*)/', '$1', $subdir);
}
?>";</pre>
If so - everything is fine too, also if this is empty.<br>
Maybe some leading/ending slash "/" is there.<br>
That's no problem here, but remove leading or<br>
ending slashes.
Do never use the backslash "\"<br>
in paths on Windows - this may fail.
<hr size="1" noshade>
<span style="font-size:11px">Copyright © 2004 Oliver
Georgi, <a href="http://www.phpwcms.de">http://www.phpwcms.de</a></span>
</body>
</html>
Oh, man, understand now :Pappnase wrote:hello
it helps nothing if you send me the source of the document_root.php
when psot the result of the document_root.php!
Code: Select all
phpwcms DOCUMENT_ROOT test
This file has to be placed in your web root - do not
put it into any subdir of your webspace
1) your default $_SERVER['DOCUMENT_ROOT']: c:/var//www
2) real DOCUMENT_ROOT based on this file : c:/var//www/fl
If (1) and (2) not equal then add following
line at the end of your conf.inc.php but before ending "?>":
$_SERVER['DOCUMENT_ROOT'] = 'c:/var//www/fl';
Check if this is corresponding with the subdir
in which phpwcms is installed:
$phpwcms['root'] = "fl";
If so - everything is fine too, also if this is empty.
Maybe some leading/ending slash "/" is there.
That's no problem here, but remove leading or
ending slashes. Do never use the backslash ""
in paths on Windows - this may fail.