Fork me on GitHub

PHPNuke Theme Convert to PN, Center Block Killing ME!  Bottom

  • I am trying to convert a theme from PHPNuke to Post Nuke. Using a core theme, I was able to identify all of the variable changes and differences between the two themes, with one exception, the center block. I can not for the life of me, figure out where to put the Block('centre') function call in my code. Would someone mind taking a look at this and telling me where it needs to go? I thought it should be in the header, but that is breaking everything. I've tried to reverse engineer the core themes, but that isn't working either.

    Would someone who understands this better than me take a look at the code and see if they can make sense of it. I'm not sure what you need, but here is the header code. Keep in mind that I am modifying existing code. There could be something wrong with the table structure that I am not able to figure out.

    Code

    function themeheader()
        {
            $slogan = pnConfigGetVar('slogan');
            $sitename = pnConfigGetVar('sitename');
            $banners = pnConfigGetVar('banners');

            echo "</head>\n"
        ."<body bgcolor=\"#000000\" text=\"#ffffff\" link=\"0000ff\" leftmargin=0 rightmargin=0 topmargin=0><br>\n";

        echo "<table border=\"0\" cellpadding=\"0\" cellspacing=\"1\" width=\"800\" align=\"center\">\n"

        ."<tr><td width=\"100%\" height=\"11\" valign=\"bottom\">\n"
        ."<tr><td width=\"100%\">\n"
        ."<table border=\"0\" cellpadding=\"0\" cellspacing=\"0\" width=\"800\">\n"
        ."<tr><td width=\"100%\"><table width=\"100%\" cellspacing=\"0\" cellpadding=\"0\" border=\"0\"><tr><td bgcolor=\"$GLOBALS[bgcolor1]\">\n"
        ."<tr><td bgcolor=\"$GLOBALS[bgcolor1]\"><img src=\"themes/$GLOBALS[thename]/images/pixel.gif\" width=\"100%\" height=\"3\"></td></tr>\n";
        echo "</td></tr></table><table width=\"800\" cellpadding=\"0\" bgcolor=\"$GLOBALS[bgcolor1]\" cellspacing=\"0\" border=\"0\">\n"
        ."<tr valign=\"top\">\n"
        ."<td><img src=\"themes/$GLOBALS[thename]/images/pixel.gif\" width=\"4\" height=\"1\" border=\"0\" alt=\"\"></td>\n"
        ."<td width=\"130\" bgcolor=\"$GLOBALS[bgcolor1]\" valign=\"top\">\n";
       blocks('left');

       echo "</td><td><img src=\"themes/$GLOBALS[thename]/images/pixel.gif\" width=\"4\" height=\"1\" border=\"0\" alt=\"\"></td><td width=\"100%\">\n";

    if(pnModAvailable('Banners'))
        {
        echo"<center>";
            pnBannerDisplay();
        echo"</center><br>";
        }

    /*
    if ($GLOBALS['index'] == 1) {
            blocks('centre');
        }
    */


    }


    The banner shows up correctly right above the news, but I want the center block to also show up. I had to rem it out because it was breaking everything.

    Any help would be greatly apprecaited.

    Atomm Nihilo
    GamersRadio.com/post (the site I am working on)
  • Can I suggest you use AutoTheme to do this? I know its not what you are looking with help for and I may look like an arse now, but AutoTheme uses 90% HTML so its just damn easy to call any blocks and whatever else you want to do. Also means you don't have sodding echo tags!

This list is based on users active over the last 60 minutes.