| Author |
Message |
SpUpUz
Joined: Apr 25, 2004
Posts: 21
Status: Offline
|
  Posted:
Aug 17, 2004 - 10:02 AM |
|
the only error i have is that... down the pge
Fatal error: Cannot redeclare head() (previously declared in /web/htdocs/www.spupuz.it/home/ironandfire/pncms/header.php:44) in /web/htdocs/www.spupuz.it/home/ironandfire/pncms/header.php on line 42
the site is www.spupuz.it
maybe you can help me. |
|
|
|
 |
Chestnut
Site Admin
Joined: Oct 08, 2003
Posts: 1065
Location: Paris - France
|
  Posted:
Aug 17, 2004 - 04:17 PM |
|
mmm check if one of your root file (index.php, header.php, etc) is properly uploaded...
I often have this kind of crap and I found that one of the files doesn\'t go to the other side properly, example :
| Code: |
//blablabla
code here
ending php tag :
?>
oups, still have code here
}
another ending php tag
?>
|
I remove the last part or reupload and everything goes fine. |
_________________ Chestnut !
Administrator
PNConcept.com |
|
 |
 |
SpUpUz
Joined: Apr 25, 2004
Posts: 21
Status: Offline
|
  Posted:
Aug 17, 2004 - 04:33 PM |
|
no more code look:
| Code: |
if (strpos(\\\'header.php\\\', $_SERVER[\\\'PHP_SELF\\\'])) {
die (\\\"You can\\\'t access this file directly...\\\");
}
/**
* Include some common header for HTML generation.
*
* XHTML Support by Matt Jarjoura. <mjarjo1@umbc.edu>
*/
$header = 1;
function head() {
global $index,
$artpage,
$topic,
$hlpfile,
$hr,
$theme,
$bgcolor1,
$bgcolor2,
$bgcolor3,
$bgcolor4,
$bgcolor5,
$textcolor1,
$textcolor2,
$textcolor3,
$textcolor4,
$forumpage,
$thename,
$postnuke_theme,
//$pntheme,
$themename,
$themeimages,
$additional_header,
$themeOverrideCategory,
$themeOverrideStory;
// modification mouzaia .71
$cWhereIsPerso = WHERE_IS_PERSO;
if ( !(empty($cWhereIsPerso)) ) {
include(\\\"modules/NS-Multisites/head.inc.php\\\");
} else {
$thistheme = pnVarPrepForOs(pnUserGetTheme());
global $themesarein;
if (@file(WHERE_IS_PERSO.\\\"themes/\\\".$thistheme.\\\"/theme.php\\\")) {
$themesarein = WHERE_IS_PERSO;
} else {
$themesarein = \\\"\\\";
}
}
if (!isset($GLOBALS[\\\'xanthia_theme\\\']) || !$GLOBALS[\\\'xanthia_theme\\\']) {
ob_start();
echo \\\"<!DOCTYPE HTML PUBLIC \\\\\\\"-//W3C//DTD HTML 4.01 Transitional//EN\\\\\\\">\\\\n\\\";
echo \\\"<html>\\\\n<head>\\\\n\\\";
if (defined(\\\"_CHARSET\\\") && _CHARSET != \\\"\\\") {
echo \\\"<meta http-equiv=\\\\\\\"Content-Type\\\\\\\" \\\".
\\\"content=\\\\\\\"text/html; charset=\\\"._CHARSET.\\\"\\\\\\\">\\\\n\\\";
}
if ($artpage==1) {
/**
* article page output
*/
global $info, $hometext;
echo \\\"<title>$info[title] :: \\\".pnConfigGetVar(\\\'sitename\\\').\\\' :: \\\'.pnConfigGetVar(\\\'slogan\\\').\\\"</title>\\\\n\\\";
if (pnConfigGetVar(\\\'dyn_keywords\\\') == 1) {
$htmlless = check_html($info[\\\'maintext\\\'], $strip =\\\'nohtml\\\');
$symbolLess = trim(ereg_replace(\\\'(\\\"|\\\\?|!|:|\\\\.|\\\\(|\\\\)|;|\\\\\\\\\\\\\\\\)+\\\', \\\' \\\', $htmlless));
$keywords = ereg_replace(\\\'( |\\\'.CHR(10).\\\'|\\\'.CHR(13).\\\')+\\\', \\\',\\\', $symbolLess);
$metatags = ereg_replace(\\\",+\\\", \\\",\\\",$keywords);
echo \\\"<meta http-equiv=\\\\\\\"Keywords\\\\\\\" content=\\\\\\\"$metatags\\\\\\\">\\\\n\\\";
} else {
echo \\\"<meta name=\\\\\\\"KEYWORDS\\\\\\\" content=\\\\\\\"\\\".pnConfigGetVar(\\\'metakeywords\\\').\\\"\\\\\\\">\\\\n\\\";
}
} else {
/**
* all other page output
*/
echo \\\'<title>\\\'.pnConfigGetVar(\\\'sitename\\\').\\\' :: \\\'.pnConfigGetVar(\\\'slogan\\\').\\\"</title>\\\\n\\\";
echo \\\'<meta name=\\\"KEYWORDS\\\" content=\\\"\\\'.pnConfigGetVar(\\\'metakeywords\\\').\\\"\\\\\\\">\\\\n\\\";
}
echo \\\'<meta name=\\\"DESCRIPTION\\\" content=\\\"\\\'.pnConfigGetVar(\\\'slogan\\\').\\\"\\\\\\\">\\\\n\\\";
echo \\\"<meta name=\\\\\\\"ROBOTS\\\\\\\" content=\\\\\\\"INDEX,FOLLOW\\\\\\\">\\\\n\\\";
echo \\\"<meta name=\\\\\\\"resource-type\\\\\\\" content=\\\\\\\"document\\\\\\\">\\\\n\\\";
echo \\\"<meta http-equiv=\\\\\\\"expires\\\\\\\" content=\\\\\\\"0\\\\\\\">\\\\n\\\";
echo \\\'<meta name=\\\"author\\\" content=\\\"\\\'.pnConfigGetVar(\\\'sitename\\\').\\\"\\\\\\\">\\\\n\\\";
echo \\\'<meta name=\\\"copyright\\\" content=\\\"Copyright (c) 2003 by \\\'.pnConfigGetVar(\\\'sitename\\\').\\\"\\\\\\\">\\\\n\\\";
echo \\\"<meta name=\\\\\\\"revisit-after\\\\\\\" content=\\\\\\\"1 days\\\\\\\">\\\\n\\\";
echo \\\"<meta name=\\\\\\\"distribution\\\\\\\" content=\\\\\\\"Global\\\\\\\">\\\\n\\\";
echo \\\"<meta name=\\\\\\\"generator\\\\\\\" content=\\\\\\\"PostNuke - http://www.postnuke.com\\\\\\\">\\\\n\\\";
echo \\\"<meta name=\\\\\\\"rating\\\\\\\" content=\\\\\\\"General\\\\\\\">\\\\n\\\";
global $themesarein;
echo \\\"<link rel=\\\\\\\"StyleSheet\\\\\\\" href=\\\\\\\"\\\".$themesarein.\\\"themes/\\\".$thistheme.\\\"/style/styleNN.css\\\\\\\" type=\\\\\\\"text/css\\\\\\\">\\\\n\\\";
echo \\\"<style type=\\\\\\\"text/css\\\\\\\">\\\";
echo \\\"@import url(\\\\\\\"\\\".$themesarein.\\\"themes/\\\".$thistheme.\\\"/style/style.css\\\\\\\"); \\\";
echo \\\"</style>\\\\n\\\";
echo \\\"<script type=\\\\\\\"text/javascript\\\\\\\" src=\\\\\\\"javascript/showimages.js\\\\\\\"></script>\\\\n\\\\n\\\";
echo \\\"<script type=\\\\\\\"text/javascript\\\\\\\" src=\\\\\\\"javascript/openwindow.js\\\\\\\"></script>\\\\n\\\\n\\\";
if(isset($additional_header)) {
echo @implode(\\\"\\\\n\\\", $additional_header);
}
}
themeheader();
}
/**
* if you want to do overrides, set the global vars $themeOverrideCategory
* and/or $themeOverrideStory before including header.php
*/
head();
include_once(\\\'includes/pncbotcount.php\\\');
?>
|
|
|
|
|
 |
Chestnut
Site Admin
Joined: Oct 08, 2003
Posts: 1065
Location: Paris - France
|
  Posted:
Aug 17, 2004 - 05:02 PM |
|
And the other files ? footer especially since your problem is after the footer... |
_________________ Chestnut !
Administrator
PNConcept.com |
|
 |
 |
SpUpUz
Joined: Apr 25, 2004
Posts: 21
Status: Offline
|
  Posted:
Aug 17, 2004 - 05:11 PM |
|
problem is only in home ( i use blickhome ) module.
| Code: |
<?php
// File: $Id: footer.php,v 1.18 2004/08/10 11:16:06 markwest Exp $ $Name: HEAD $
// ----------------------------------------------------------------------
// PostNuke Content Management System
// Copyright (C) 2001 by the PostNuke Development Team.
// http://www.postnuke.com/
// ----------------------------------------------------------------------
// Based on:
// PHP-NUKE Web Portal System - http://phpnuke.org/
// Thatware - http://thatware.org/
// ----------------------------------------------------------------------
// LICENSE
//
// This program is free software; you can redistribute it and/or
// modify it under the terms of the GNU General Public License (GPL)
// as published by the Free Software Foundation; either version 2
// of the License, or (at your option) any later version.
//
// This program 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.
//
// To read the license please visit http://www.gnu.org/copyleft/gpl.html
// ----------------------------------------------------------------------
// Original Author of file: Francisco Burzi
// Purpose of file:
// ----------------------------------------------------------------------
if (stristr('footer.php', $_SERVER['PHP_SELF'])) {
die ("You can't access this file directly...");
}
// XHTML Support by Matt Jarjoura. <mjarjo1@umbc.edu>
function footmsg()
{
echo "<span class=\"pn-sub\">\n".pnConfigGetVar('foot1')."<br />\n</span>\n";
}
function foot()
{
// modification .71 multisites mouzaia
/* it should not be necessary here, since config.php is in a table.
if (!isset($index)) {
include(WHERE_IS_PERSO."config.php");
}
*/
themefooter();
if (!isset($GLOBALS['xanthia_theme']) || !$GLOBALS['xanthia_theme']) {
// show time to render
$mtime = explode(" ",microtime());
$dbg_endtime = $mtime[1] + $mtime[0];
$dbg_totaltime = ($dbg_endtime - $GLOBALS['dbg_starttime']);
if ($GLOBALS['pndebug']['pagerendertime']) {
printf("<div style=\"text-align:center\" class=\"pn-sub\">Page created in %f seconds.</div>", $dbg_totaltime);
}
if ($GLOBALS['pndebug']['debug']){
$GLOBALS['dbg']->v($dbg_totaltime,"Page created in (seconds)");
$GLOBALS['dbg']->v($GLOBALS['debug_sqlcalls'],"Number of SQL Calls");
}
// include typetool 8.0 [larsneo]
// (upload option disabled for security reasons)
$tt_enable = pnModGetVar('typetool', 'enable');
$baseURL = pnGetBaseURL();
$ModName = pnModGetName();
if ( is_numeric( $tt_enable ) && $tt_enable == 1) {
if (pnSecAuthAction(0, 'typetool::', "$ModName::", ACCESS_COMMENT) &&
$ModName != "Settings" &&
$ModName != "Permissions" &&
$ModName != "Censor") {
// enable the wysiwyg editor when user has at least comment rights
// no WYSIWYG in Settings, Permissions and Censor anyway...
echo "\n<!--Visual Editor Plug-in-->\n";
echo "<script type=\"text/javascript\">VISUAL=0; FULLCTRL=1; SECURE=1; LANGUAGE='".pnModGetVar('typetool', 'language')."';</script>\n";
echo "<script type=\"text/javascript\" src='".$baseURL."modules/typetool/pnincludes/quickbuild.js'></script>\n";
echo "<!--End Visual Editor Plug-in-->\n";
}
}
echo "</body>\n</html>";
ob_end_flush();
}
}
echo $GLOBALS['dmfooter'];
foot();
include_once('includes/pncbotcount.php');
?>
|
|
|
|
|
 |
Chestnut
Site Admin
Joined: Oct 08, 2003
Posts: 1065
Location: Paris - France
|
  Posted:
Aug 17, 2004 - 05:13 PM |
|
Use the code tag to display code...
Is it me or you have put the include pncbotcount.php both in the header AND in the footer ?
Remove the one from the header... |
_________________ Chestnut !
Administrator
PNConcept.com |
|
 |
 |
SpUpUz
Joined: Apr 25, 2004
Posts: 21
Status: Offline
|
  Posted:
Aug 17, 2004 - 05:15 PM |
|
sitll problem after removing from header.php |
|
|
|
 |
Chestnut
Site Admin
Joined: Oct 08, 2003
Posts: 1065
Location: Paris - France
|
  Posted:
Aug 17, 2004 - 05:24 PM |
|
Then it might be Blockhome doing the problem... (PNphpBB2 had this for a time by having a second header but the error was something else...)...
With the use of Xanthia (and pnRender, you could do a blank mod, set it as home mod and add the blocks you need... you would reproduce the exact same thing without the use of a third party mod to do the same thing...
Well... of course, that would be possible IF you are using a Xanthia theme............ he he ! (Maybe autotheme also.Dunno, never used it.) |
_________________ Chestnut !
Administrator
PNConcept.com |
|
 |
 |
SpUpUz
Joined: Apr 25, 2004
Posts: 21
Status: Offline
|
  Posted:
Aug 17, 2004 - 05:27 PM |
|
no i use xanthia... but i'm not ablo to create a blank mod... i installed forum 1.2g pnphpbb but i have a lot of problems.. probably i came back to 1.2f |
|
|
|
 |
Chestnut
Site Admin
Joined: Oct 08, 2003
Posts: 1065
Location: Paris - France
|
  Posted:
Aug 17, 2004 - 05:30 PM |
|
Don't worry about the 1.2g... As you can see, one of the dev point me to a new fix today for the quotes problem but there are other things (redirection page showing stuff).
I must have a blank mod somewhere... will check. |
_________________ Chestnut !
Administrator
PNConcept.com |
|
 |
 |
SpUpUz
Joined: Apr 25, 2004
Posts: 21
Status: Offline
|
  Posted:
Aug 17, 2004 - 05:32 PM |
|
tnx. for the blank module..
but for the forum i do have to have one working correclty.. i'm not a able scripter... i'm a system engineer  |
|
|
|
 |
Chestnut
Site Admin
Joined: Oct 08, 2003
Posts: 1065
Location: Paris - France
|
  Posted:
Aug 17, 2004 - 05:38 PM |
|
Try this one...
(It's a fast build but should work)... |
_________________ Chestnut !
Administrator
PNConcept.com |
|
 |
 |
SpUpUz
Joined: Apr 25, 2004
Posts: 21
Status: Offline
|
  Posted:
Aug 17, 2004 - 06:06 PM |
|
|
|
 |
Chestnut
Site Admin
Joined: Oct 08, 2003
Posts: 1065
Location: Paris - France
|
  Posted:
Aug 17, 2004 - 06:56 PM |
|
Glad it had a fix...
(and that I was far from the real answer. ) |
_________________ Chestnut !
Administrator
PNConcept.com |
|
 |
 |
|
|