PHP Nuke: Sections error

Any ideas anyone??

  • (2 Pages)
  • +
  • 1
  • 2

25 Replies - 3461 Views - Last Post: 25 August 2001 - 02:36 AM Rate Topic: -----

#16 Mark  Icon User is offline

  • D.I.C Head

Reputation: 0
  • View blog
  • Posts: 93
  • Joined: 06-August 01

Re: PHP Nuke: Sections error

Posted 16 August 2001 - 11:49 PM

i think it's just PHP Nuke getting corrupted...it looks like you might wanna upload an old copy of theme.php --

IMO PHP Nuke is good sometimes...but it's crap like this that makes its sloppy code fail :(

Was This Post Helpful? 0
  • +
  • -

#17 Lord Manimal  Icon User is offline

  • D.I.C Regular

Reputation: 0
  • View blog
  • Posts: 413
  • Joined: 07-April 01

Re: PHP Nuke: Sections error

Posted 17 August 2001 - 02:11 PM

Okay guys. Can someone tell me which part the sections tables are compiled?? I had thought it would be in sections.php, but since this problem only effects a few themes, it seems to me that the problem is in the themes.php.

Here is an exact copy of the one I wish to repair:

<?php

/************************************************************/
/* Theme Defaults Definition                                  */
/*                                                          */
/* Control the header for your site. You need to define the */
/* BODY tag and in some part of the code call the blocks    */
/* function for left side with: block(left);                */
/************************************************************/

global $thename,$bgcolor1,$bgcolor2,$bgcolor3,$bgcolor4,$bgcolor5,$textcolor1,$textcolor2,$textcolor3,$textcolor4,$textcolor5,$textcolor6,$welcomeMessage;

$thename = "Kaput2";
$bgcolor1 = "#FFFFFF";  # primary background color
$bgcolor2 = "#FFFFFF";  # header and footer background color
$bgcolor3 = "#FFFFFF";  # block area background color
$bgcolor4 = "#FFFFFF";  # center block background color
$bgcolor5 = "#7b91AC";  # left and right block background color
$textcolor1 = "#000000"; # center block default title text color
$textcolor2 = "#000000"; # left and right block default title text color
$textcolor3 = "#505050"; # upper center block default text color
$textcolor4 = "#999999"; # lower center block default text color
$textcolor5 = "#000000"; # right and left block default text color
$textcolor6 = "#000000"; # header and footer default text color
$welcomeMessage = "[Insert your message here]";

/************************************************************/
/* Function OpenTable()                                     */
/*                                                          */
/*  Beginning of the Block formating for the header and     */
/*  footer of your site                                     */
/************************************************************/

function OpenTable() {
   global $thename,$bgcolor1,$bgcolor2,$bgcolor3,$bgcolor4,$bgcolor5,$textcolor1,$textcolor2,$textcolor3,$textcolor4,$textcolor5,$textcolor6,$welcomeMessage;
   echo "<table border="0" cellspacing="0" cellpadding="0" width="100%">
   <tr>
       <td width="15" height="15"><img src="themes/$thename/images/up-left2.gif" alt="" border="0"></td>
       <td background="themes/$thename/images/up2.gif" align="center" width="100%" height="15"><font size=1>&nbsp;</font></td>
       <td><img src="themes/$thename/images/up-right2.gif" width="15" height="15" alt="" border="0"></td>
   </tr>
   <tr>
       <td background="themes/$thename/images/left2.gif" width="15"><font size=1>&nbsp;</font></td>
       <td bgcolor="$bgcolor2" width="100%">";
}

/************************************************************/
/* Function OpenTable2()                                    */
/*                                                          */
/*  Beginning of the Block formating for the poll results   */
/*  and other blocks                                        */
/************************************************************/
function OpenTable2() {
   global $thename,$bgcolor1,$bgcolor2,$bgcolor3,$bgcolor4,$bgcolor5,$textcolor1,$textcolor2,$textcolor3,$textcolor4,$textcolor5,$textcolor6,$welcomeMessage;
   echo "<table border="0" cellspacing="0" cellpadding="0" align="center"><tr>
   <td width="15" height="15"><img src="themes/$thename/images/up-left2.gif" alt="" border="0"></td>
   <td background="themes/$thename/images/up2.gif" align="center" height="15"><font size=1>&nbsp;</font></td>
   <td><img src="themes/$thename/images/up-right2.gif" width="15" height="15" alt="" border="0"></td>
   </tr>
   <tr>
   <td background="themes/$thename/images/left2.gif" width="15"><font size=1>&nbsp;</font></td>
   <td bgcolor="ffffff">";
}

/************************************************************/
/* Function CloseTable()                                    */
/*                                                          */
/*  Ending of the Block formating for the header and        */
/*  footer of your site                                     */
/************************************************************/

function CloseTable() {
   global $thename,$bgcolor1,$bgcolor2,$bgcolor3,$bgcolor4,$bgcolor5,$textcolor1,$textcolor2,$textcolor3,$textcolor4,$textcolor5,$textcolor6,$welcomeMessage;
   echo "</td>
       <td background="themes/$thename/images/right2.gif"><font size=1>&nbsp;</font></td></tr>
   <tr>
       <td width="15" height="15"><img src="themes/$thename/images/down-left2.gif" alt="" border="0"></td>
       <td background="themes/$thename/images/down2.gif" align="center" height="15"><font size=1>&nbsp;</font></td>
       <td><img src="themes/$thename/images/down-right2.gif" width="15" height="15" alt="" border="0"></td>
   </tr>
   </td></tr></table>
   <br>";
}

/************************************************************/
/* Function CloseTable2()                                   */
/*                                                          */
/*  Ending of the Block formating for the poll results   */
/*  and other blocks                                        */
/************************************************************/
function CloseTable2() {
   global $thename,$bgcolor1,$bgcolor2,$bgcolor3,$bgcolor4,$bgcolor5,$textcolor1,$textcolor2,$textcolor3,$textcolor4,$textcolor5,$textcolor6,$welcomeMessage;
   echo "</td>
       <td background="themes/$thename/images/right2.gif"><font size=1>&nbsp;</font></td></tr>
   <tr>
       <td width="15" height="15"><img src="themes/$thename/images/down-left2.gif" alt="" border="0"></td>
       <td background="themes/$thename/images/down2.gif" align="center" height="15"><font size=1>&nbsp;</font></td>
       <td><img src="themes/$thename/images/down-right2.gif" width="15" height="15" alt="" border="0"></td>
   </tr>
   </td></tr></table>
   <br>";
}

/************************************************************/
/* Function FormatStory()                                   */
/*                                                          */
/*  Displays the news item text in the center blocks        */
/************************************************************/
function FormatStory($thetext, $notes, $aid, $informant) {
   global $thename,$bgcolor1,$bgcolor2,$bgcolor3,$bgcolor4,$bgcolor5,$textcolor1,$textcolor2,$textcolor3,$textcolor4,$textcolor5,$textcolor6,$welcomeMessage;
   global $anonymous;
   if ($notes != "") {
$notes = "<b>"._NOTE."</b> <i>$notes</i>
";
   } else {
$notes = "";
   }
   if ("$aid" == "$informant") {
echo "<font size="2" color="$textcolor3">$thetext<br>$notes</font>
";
   } else {
if($informant != "") {
   $boxstuff = "<a href="user.php?op=userinfo&amp;uname=$informant">$informant</a> ";
} else {
   $boxstuff = "$anonymous ";
}
$boxstuff .= ""._WRITES." <i>"$thetext"</i> $notes
";
echo "<font size="2" color="$textcolor3">$boxstuff</font>
";
   }
}

/************************************************************/
/* Function themeheader()                                   */
/*                                                          */
/* Control the header for your site. You need to define the */
/* BODY tag and in some part of the code call the blocks    */
/* function for left side with: blocks(left);                */
/************************************************************/

function themeheader() {
   global $thename,$bgcolor1,$bgcolor2,$bgcolor3,$bgcolor4,$bgcolor5,$textcolor1,$textcolor2,$textcolor3,$textcolor4,$textcolor5,$textcolor6,$welcomeMessage;
   global $user, $sitename;
   cookiedecode($user);
   $username = $cookie[1];
   if ($username == "") {
       $username = "Anonymous";
   }
   echo "<body bgcolor="$bgcolor1" text="#000000" link="#363636" vlink="#363636" alink="#d5ae83">
"
."<br>
";
   if ($banners) {
include("banners.php");
   }
   OpenTable();

   /******************************/
   /* If you comment this echo statement and uncomment the statment below this one you can */
   /* replace the search with a the welcome statement defined above.  I liked this option  */
   /* better since the search and menu are in blocks of the portal.                        */
   /******************************/
   echo "<table border="0" width="100%"><tr><td rowspan="2">"
."<a href="index.php"><img src="themes/$thename/images/logo.gif" border="0" alt=""._WELCOMETO." $sitename" align="left"></a></td>"
."<td align=right width=100%>"
       ."<form action="search.php" method="post">"
       ."<font size="2" color="$textcolor6"><b>"._SEARCH." </b>"
       ."<input type="text" name="query" size="14"></font></form>"
       ."</td></tr><tr>"
       ."<td align="right" valign="bottom" width="100%">"
       ."<font size="2"><b>"
."<A href="/">Home</a>&nbsp;&middot;&nbsp;<A href="topics.php">"._TOPICS."</a>&nbsp;&middot;&nbsp"
       ."<A href="download.php">"._DOWNLOADS."</a>&nbsp;&middot;&nbsp;<A href="user.php">"._USERLOGIN."</a>"
       ."&nbsp;&middot;&nbsp;<A href="forum.php">"._FORUMS."</a>&nbsp;&middot;&nbsp;<A href="top.php">"._TOP10."</a>"
       ."</b></font></td></tr></table>
";

   /******************************/
   /* If you uncomment this echo statement and comment off the above you can replace the search */
   /* with a welcome statement.  I liked this option better since the search and menu are in    */
   /* blocks of the portal.                                                                     */
   /******************************/
   /*
   echo "<table border="0" width="100%"><tr><td>"
."<a href="index.php"><img src="themes/$thename/images/logo.gif" border="0" alt=""._WELCOMETO." $sitename" align="left"></a></td>"
."<td width=100%><font color="$textcolor6">"
       .$welcomeMessage
       ."</font></td></tr></table>
";
   */
   CloseTable();
   echo "<table cellpadding="0" cellspacing="0" width="99%" border="0" align="center" bgcolor="$bgcolor3">
"
."<tr><td valign="top">
";
   blocks(left);
   echo "</td><td><img src="themes/$thename/images/pixel.gif" width="15" height="1" border="0" alt=""></td><td width="100%" valign=top>
";
}

/************************************************************/
/* Function themefooter()                                   */
/*                                                          */
/* Control the footer for your site. You don't need to      */
/* close BODY and HTML tags at the end. In some part call   */
/* the function for right blocks with: blocks(right);       */
/* Also, $index variable need to be global and is used to   */
/* determine if the page your're viewing is the Homepage or */
/* and internal one.                                        */
/************************************************************/

function themefooter() {
   global $thename,$bgcolor1,$bgcolor2,$bgcolor3,$bgcolor4,$bgcolor5,$textcolor1,$textcolor2,$textcolor3,$textcolor4,$textcolor5,$textcolor6,$welcomeMessage;
   global $index;
   if ($index == 1) {
echo "</td><td><img src="themes/$thename/images/pixel.gif" width="15" height="1" border="0" alt=""></td><td valign="top" width="150">
";
blocks(right);
   }
   echo "</td></tr></table>
";
}

/************************************************************/
/* Function themeindex()                                    */
/*                                                          */
/* Displays the center blocks                               */
/************************************************************/

function themeindex ($aid, $informant, $time, $title, $counter, $topic, $thetext, $notes, $morelink, $topicname, $topicimage, $topictext) {
   global $thename,$bgcolor1,$bgcolor2,$bgcolor3,$bgcolor4,$bgcolor5,$textcolor1,$textcolor2,$textcolor3,$textcolor4,$textcolor5,$textcolor6,$welcomeMessage;
   global $anonymous, $tipath;
   echo "<table border="0" cellspacing="0" cellpadding="0" width="100%">
   <tr>
       <td width="15" height="15"><img src="themes/$thename/images/up-left2.gif" alt="" border="0"></td>
       <td background="themes/$thename/images/up2.gif" align="center" width="100%" height="15"><font size=1>&nbsp;</font></td>
       <td width="15" height="15"><img src="themes/$thename/images/up-right2.gif" width="15" height="15" alt="" border="0"></td>
   </tr>
   <tr>
       <td background="themes/$thename/images/left2.gif" width="15"><font size=1>&nbsp;</font></td>
       <td bgcolor="$bgcolor4" width="100%">
               <font color="$textcolor4"><b><a href="search.php?query=&amp;topic=$topic"><img src="$tipath$topicimage" border="0" Alt="$topictext" align="right" hspace="10" vspace="10"></a></B></font>
               <font color="$textcolor1"><b>$title</b></font>
               <font color="$textcolor3">";
               FormatStory($thetext, $notes, $aid, $informant);
               echo "</font>
       </td>
       <td background="themes/$thename/images/right2.gif"><font size=1>&nbsp;</font></td>
   </tr>
   <tr>
       <td width="15" height="15"><img src="themes/$thename/images/middle-left.gif" alt="" border="0"></td>
       <td background="themes/$thename/images/middle.gif" align="center" height="15"><font size=1>&nbsp;</font></td>
       <td><img src="themes/$thename/images/middle-right.gif" width="15" height="15" alt="" border="0"></td>
   </tr>
   <tr>
       <td background="themes/$thename/images/left3.gif" width="15"><font size=1>&nbsp;</font></td>
       <td align=center bgcolor="$bgcolor4">
               <font color="$textcolor4" size="1">"._POSTEDBY." ";
                       formatAidHeader($aid);
                       echo " "._ON." $time $timezone ($counter "._READS.")<br></font>
       <font size="2">$morelink</font>
       </td>
       <td background="themes/$thename/images/right3.gif" width="15"><font size=1>&nbsp;</font></td>
   </tr>
   <tr>
       <td width="15" height="11" valign=top><img src="themes/$thename/images/down-left3.gif" alt="" border="0"></td>
       <td background="themes/$thename/images/down3.gif" align="center" height="11" width=100%><font size=1>&nbsp;</font></td>
       <td width="15" height="11" valign=top><img src="themes/$thename/images/down-right3.gif" alt="" border="0"></td>
   </tr>
   </table>
   <br>";
}

/************************************************************/
/* Function themearticle()                                  */
/*                                                          */
/* Controls how an article appears when read.               */
/************************************************************/
function themearticle ($aid, $informant, $datetime, $title, $thetext, $topic, $topicname, $topicimage, $topictext) {
   global $thename,$bgcolor1,$bgcolor2,$bgcolor3,$bgcolor4,$bgcolor5,$textcolor1,$textcolor2,$textcolor3,$textcolor4,$textcolor5,$textcolor6,$welcomeMessage;
   global $admin, $sid, $tipath;
   Opentable();
   echo "<font size="3" color="#363636"><b>$title</b></font><br>
"
       ."<font size="2">"._POSTEDON." $datetime by ";
   formatAidHeader($aid);
   if (is_admin($admin)) {
echo "<br>[ <a href="admin.php?op=EditStory&amp;sid=$sid">"._EDIT."</a> | <a href="admin.php?op=RemoveStory&amp;sid=$sid">"._DELETE."</a> ]
";
   }
   echo "";
   echo "<a href="search.php?query=&amp;topic=$topic"><img src="$tipath$topicimage" border="0" Alt="$topictext" align="right" hspace="10" vspace="10"></a>
";
   FormatStory($thetext, $notes="", $aid, $informant);
   echo "<br>


";
   CloseTable();
}

/************************************************************/
/* Function themeidebox()                                   */
/*                                                          */
/* left and right block formating                           */
/************************************************************/

function themesidebox($title, $content) {
   global $thename,$bgcolor1,$bgcolor2,$bgcolor3,$bgcolor4,$bgcolor5,$textcolor1,$textcolor2,$textcolor3,$textcolor4,$textcolor5,$textcolor6,$welcomeMessage;
   echo "<table border=0 cellspacing=0 cellpadding=0 width=150><tr>"
."<td width=17 height=17><img src=themes/$thename/images/up-left.gif alt="" border=0></td>"
       ."<td background=themes/$thename/images/up.gif align=center width=100% height=17><font size=1>&nbsp;</font></td>"
       ."<td width=17 height=17><img src=themes/$thename/images/up-right.gif width=17 height=17 alt="" border=0></td></tr>"
       ."<tr>"
       ."<td background=themes/$thename/images/left.gif width=17><font size=1>&nbsp;</font></td>"
       ."<td bgcolor="$bgcolor5" width=126><center><font color="$textcolor2" size=2><b>$title</b></font></center><br><font color="$textcolor5">$content</font></td>"
       ."<td background=themes/$thename/images/right.gif><font size=1>&nbsp;</font></td></tr>"
       ."<tr>"
       ."<td width=17 height=17><img src=themes/$thename/images/down-left.gif alt="" border=0></td>"
       ."<td background=themes/$thename/images/down.gif align=center width=100% height=17><font size=1>&nbsp;</font></td>"
       ."<td width=17 height=17><img src=themes/$thename/images/down-right.gif width=17 height=17 alt="" border=0></td></tr>"
       ."</td></tr></table>"
       ."<br>";
}

?>


Now, which part is making the tables fuqqed up?!! If you viewsource on the sections page, you can see clearly what the problem is. It's got an extra unclosed table added into it. But where to change that?!!

Was This Post Helpful? 0
  • +
  • -

#18 tsmoke  Icon User is offline

  • D.I.C Head

Reputation: 1
  • View blog
  • Posts: 50
  • Joined: 20-April 01

Re: PHP Nuke: Sections error

Posted 17 August 2001 - 03:51 PM

I have been looking to see if I could find anything, found some possible problems, but still in the process of trying to test them. I f I can't come up with anything by tomorrow, I will send you what I've got to see if it works. I still haven't downloaded the actual app so am trying to test through other errors.

tsmoke

Was This Post Helpful? 0
  • +
  • -

#19 Mark  Icon User is offline

  • D.I.C Head

Reputation: 0
  • View blog
  • Posts: 93
  • Joined: 06-August 01

Re: PHP Nuke: Sections error

Posted 17 August 2001 - 05:21 PM

trust me when I say it's not a PHP error.  PHP is a compile langauge, that means that the php program looks at the whole script and checks for errors of any nature, it won't run the script if it finds an error, and if it find an error it would print it -- im not seeing any errors.

Most likely something is wrong with the sections.php where it is printing multiple opentable() functions for some unknown obscure reason..

Was This Post Helpful? 0
  • +
  • -

#20 tsmoke  Icon User is offline

  • D.I.C Head

Reputation: 1
  • View blog
  • Posts: 50
  • Joined: 20-April 01

Re: PHP Nuke: Sections error

Posted 19 August 2001 - 04:30 PM

Lord Manimal,

Take a look at your email if you haven't checked it yet. I did send a modified version of your file back to you to see if your web site will work with it.

tsmoke

Was This Post Helpful? 0
  • +
  • -

#21 Lord Manimal  Icon User is offline

  • D.I.C Regular

Reputation: 0
  • View blog
  • Posts: 413
  • Joined: 07-April 01

Re: PHP Nuke: Sections error

Posted 20 August 2001 - 09:41 PM

Yeah, I got it tsmoke. I tried it, and it wasn't any different oddly. I played with exactly what you did, and it looks good in an html editor, and even in a web browser, but that leads me to believe that Mark is right. Would you be willing to take a few out of you day and lend me a hand Mark? Me and tsmoke are kinda stumped at this point. Other themes work just fine, but not this one?....
Was This Post Helpful? 0
  • +
  • -

#22 Lord Manimal  Icon User is offline

  • D.I.C Regular

Reputation: 0
  • View blog
  • Posts: 413
  • Joined: 07-April 01

Re: PHP Nuke: Sections error

Posted 20 August 2001 - 09:51 PM

Here's the sections code:

<?php

/************************************************************************/
/* PHP-NUKE: Web Portal System                                          */
/* ===========================                                          */
/*                                                                      */
/* Copyright © 2001 by Francisco Burzi (fbc@mandrakesoft.com)         */
/* http://phpnuke.org                                                   */
/*                                                                      */
/* This program 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.       */
/************************************************************************/

if(!isset($mainfile)) { include("mainfile.php"); }

function listsections() {
   global $sitename, $prefix;
   include ('header.php');
   $result = mysql_query("select secid, secname, image from $prefix"._sections." order by secname");
   OpenTable();
   echo "
   <center>"._SECWELCOME." $sitename.<br><br>
   "._YOUCANFIND."</center><br><br>
   <table border="0" align="center">";
   $count = 0;
   while (list($secid, $secname, $image) = mysql_fetch_row($result)) {
       if ($count==2) {
       echo "<tr>";
       $count = 0;
       }
       echo "<td><a href="sections.php?op=listarticles&secid=$secid"><img src="images/sections/$image" border="0" Alt="$secname"></a>";
       $count++;
       if ($count==2) {
       echo "</tr>";
       }
       echo "</td>";
   }
   mysql_free_result($result);
   echo "</table></center>";
   CloseTable();
   include ('footer.php');
}

function listarticles($secid) {
   global $prefix;
   include ('header.php');
   $result = mysql_query("select secname from $prefix"._sections." where secid=$secid");
   list($secname) = mysql_fetch_row($result);
   mysql_free_result($result);
   $result = mysql_query("select artid, secid, title, content, counter from $prefix"._seccont." where secid=$secid");
   OpenTable();
   $result2 = mysql_query("select image from $prefix"._sections." where secid=$secid");
   list($image) = mysql_fetch_row($result2);
   echo "<center><img src="images/sections/$image" border="0" alt=""><br><br>
   <font class="option">
   "._THISISSEC." <b>$secname</b>.<br>"._FOLLOWINGART."</font></center><br><br>
   <table border="0" align="center">";
   while (list($artid, $secid, $title, $content, $counter) = mysql_fetch_row($result)) {
       echo "
       <tr><td align="left" nowrap><font class="content">
       <li><a href="sections.php?op=viewarticle&artid=$artid">$title</a> ($counter "._READS.")
       <a href="sections.php?op=printpage&artid=$artid"><img src="images/print.gif" border="0" Alt=""._PRINTER."" width="15" height="11"></a>
       </td></tr>
       ";    
   }
   echo "</table>
   <br><br><br><center>
   [ <a href="sections.php">"._SECRETURN."</a> ]</center>";
   CloseTable();
   mysql_free_result($result);
   include ('footer.php');
}

function viewarticle($artid, $page) {
   global $prefix;
   include("header.php");
   if (($page == 1) OR ($page == "")) {
mysql_query("update $prefix"._seccont." set counter=counter+1 where artid='$artid'");
   }
   $result = mysql_query("select artid, secid, title, content, counter from $prefix"._seccont." where artid=$artid");
   list($artid, $secid, $title, $content, $counter) = mysql_fetch_row($result);
       
   $result2 = mysql_query("select secid, secname from $prefix"._sections." where secid=$secid");
   list($secid, $secname) = mysql_fetch_row($result2);
   $words = sizeof(explode(" ", $content));
   echo "<center>";
   OpenTable();
   $contentpages = explode( "", $content );
   $pageno = count($contentpages);
   if ( $page=="" || $page < 1 )
$page = 1;
   if ( $page > $pageno )
$page = $pageno;
   $arrayelement = (int)$page;
   $arrayelement --;
   echo "<font class="option"><b>$title</b></font><br><br><font class="content">";
   if ($pageno > 1) {
echo ""._PAGE.": $page/$pageno<br>";
   }
   echo "($words "._TOTALWORDS.")<br>"
."($counter "._READS.") &nbsp;&nbsp;"
."<a href="sections.php?op=printpage&amp;artid=$artid"><img src="images/print.gif" border="0" Alt=""._PRINTER."" width="15" height="11"></a>"
."</font><br><br><br><br>
";
   echo "$contentpages[$arrayelement]";
   if($page >= $pageno)
{
 $next_page = "";
   } else {
$next_pagenumber = $page + 1;
if ($page != 1) {
   $next_page .= "<img src="images/blackpixel.gif" width="10" height="2" border="0" alt=""> &nbsp;&nbsp; ";
}
$next_page .= "<a href="sections.php?op=viewarticle&amp;artid=$artid&amp;page=$next_pagenumber">"._NEXT." ($next_pagenumber/$pageno)</a> <a href="sections.php?op=viewarticle&artid=$artid&page=$next_pagenumber"><img src="images/download/right.gif" border="0" alt=""._NEXT.""></a>";
   }

   if($page <= 1)
{
$previous_page = "";
   } else {
$previous_pagenumber = $page - 1;
$previous_page = "<a href="sections.php?op=viewarticle&amp;artid=$artid&amp;page=$previous_pagenumber"><img src="images/download/left.gif" border="0" alt=""._PREVIOUS.""></a> <a href="sections.php?op=viewarticle&artid=$artid&page=$previous_pagenumber">"._PREVIOUS." ($previous_pagenumber/$pageno)</a>";
   }
   echo "</td></tr>"
."<tr><td align="center">"
."$previous_page &nbsp;&nbsp; $next_page<br><br>"
."[ <a href="sections.php?op=listarticles&amp;secid=$secid">"._BACKTO." $secname</a> | "
."<a href="sections.php">"._SECINDEX."</a> ]";
   CloseTable();
   echo "</center>";
   mysql_free_result($result);
   mysql_free_result($result2);
   include ('footer.php');
}

function PrintSecPage($artid) {
   global $site_logo, $nukeurl, $sitename, $datetime, $prefix;
   $result=mysql_query("select title, content from $prefix"._seccont." where artid=$artid");
   list($title, $content) = mysql_fetch_row($result);
   echo "
   <html>
   <head><title>$sitename</title></head>
   <body bgcolor="#FFFFFF" text="#000000">
   <table border="0"><tr><td>
   <table border="0" width="640" cellpadding="0" cellspacing="1" bgcolor="#000000"><tr><td>
   <table border="0" width="640" cellpadding="20" cellspacing="1" bgcolor="#FFFFFF"><tr><td>
   <center>
   <img src="images/$site_logo" border="0" alt=""><br><br>
   <font class="content">
   <b>$title</b></font><br>
   </center><font class="content">
   $content<br><br>";
   echo "</td></tr></table></td></tr></table>
   <br><br><center>
   <font class="content">
   "._COMESFROM." $sitename<br>
   <a href="$nukeurl">$nukeurl</a><br><br>
   "._THEURL."<br>
   <a href="$nukeurl/sections.php?artid=$artid">$nukeurl/sections.php?artid=$artid</a></font></center>
   </td></tr></table>
   </body>
   </html>
   ";
}

switch($op) {

   case "viewarticle":
   viewarticle($artid, $page);
   break;

   case "listarticles":
   listarticles($secid);
   break;

   case "printpage":
   PrintSecPage($artid);
   break;
       
   default:
   listsections();
   break;

}

?>

I hilighted the open and close tags for ease of reading. I know it's RIGHT there in front of us.... See anythng?

(Edited by Lord Manimal at 3:56 am on Aug. 21, 2001)

Was This Post Helpful? 0
  • +
  • -

#23 Lord Manimal  Icon User is offline

  • D.I.C Regular

Reputation: 0
  • View blog
  • Posts: 413
  • Joined: 07-April 01

Re: PHP Nuke: Sections error

Posted 20 August 2001 - 10:02 PM

Also I'm sure if it IS in the sections.php that it's in betwen the 3rd set of open and close tags. The other two function properly, but not this third one....
Was This Post Helpful? 0
  • +
  • -

#24 tsmoke  Icon User is offline

  • D.I.C Head

Reputation: 1
  • View blog
  • Posts: 50
  • Joined: 20-April 01

Re: PHP Nuke: Sections error

Posted 24 August 2001 - 03:27 PM

Lord Manimal

Can you tell me where you got the theme that you use. I 've just dloaded php nuke and was looking at trying out your script. I don't get errors in any of the themes that come with it, but I have replaced the themes.php file in one of the theme folders and got the error. Just figure if I could set it as it's own theme, then I could see it with the images and what not.

Was This Post Helpful? 0
  • +
  • -

#25 Mark  Icon User is offline

  • D.I.C Head

Reputation: 0
  • View blog
  • Posts: 93
  • Joined: 06-August 01

Re: PHP Nuke: Sections error

Posted 24 August 2001 - 11:08 PM

i can't do all that much for you...but if you assume it is those tags then the solution is relatively simple, remove them and see what happens :/.

the other problem might be some kind of looping error -- but I doubt it.

If I had the time I'd help you out more..but my advice here is all I can spare :)

Was This Post Helpful? 0
  • +
  • -

#26 Lord Manimal  Icon User is offline

  • D.I.C Regular

Reputation: 0
  • View blog
  • Posts: 413
  • Joined: 07-April 01

Re: PHP Nuke: Sections error

Posted 25 August 2001 - 02:36 AM

Well, I gave up on finally. I've got a new and improved layout now, and life is peachy keen again. You can check it out at http://lanmanimal.com Thanks again fellas.
Was This Post Helpful? 0
  • +
  • -

  • (2 Pages)
  • +
  • 1
  • 2