Results 1 to 1 of 1
  1. #1
    Join Date
    May 2010
    Posts
    1
    Plugin Contributions
    0

    bug PHPBB: information.php tpl_site_map_default.php with URL reference to phpBB3 forum

    version Zen Cart v1.3.9b/v1.3.9b
    clean new install
    no addons

    I'm familiar with PHP but no were near Pro so I was only able to trace the problem back to:
    information.php
    tpl_site_map_default.php

    The problem behaviour:

    When clicking on the "Forum" link inside the Information box it will try to go to
    http://www.your-site.com/zen-cart-dir//forum/index.php

    but that is incorrect as the forum is located on:
    http://www.your-site.com/forum/index.php

    I was able to trace the problem to be in this line, but i was unable to figure out where it gets the phpbb_url from, since the configure.php (from ..\includes) references the full local server path to phpBB forum, so no idea how it determines or assumes it's just "/forum/"

    Code:
      define('DIR_WS_PHPBB', '/home/your-site/public_html/forum/');
    Assuming that even if phpBB was installed within Zen Cart at the root folder, it's still creating a double slash // before the forum/index.php
    which actually would read like

    Code:
    ...some variable/+/phpbb_url/FILENAME_BB_INDEX
    and that "some variable" is what i can't figure out where it's coming from.

    Code:
    <?php if ( (isset($phpBB->phpBB['db_installed_config']) && $phpBB->phpBB['db_installed_config']) && (isset($phpBB->phpBB['files_installed']) && $phpBB->phpBB['files_installed'])  && (PHPBB_LINKS_ENABLED=='true')) { ?>
                <li><?php echo '<a href="' . zen_href_link($phpBB->phpBB['phpbb_url'] . FILENAME_BB_INDEX, '', 'NONSSL', false, '', true) . '" target="_blank">' . BOX_BBINDEX . '</a>'; ?></li>
    <?php } ?>
    So my workaround was to modify that line of code to read like

    Code:
    <?php if ( (isset($phpBB->phpBB['db_installed_config']) && $phpBB->phpBB['db_installed_config']) && (isset($phpBB->phpBB['files_installed']) && $phpBB->phpBB['files_installed'])  && (PHPBB_LINKS_ENABLED=='true')) { ?>
                <li><?php echo '<a href="http://www.your-site.com/forum/index.php"' . '" target="_blank">' . BOX_BBINDEX . '</a>'; ?></li>
    <?php } ?>
    it'll be nice to know where it's getting those values from, to fix it properly as it affects 2 pages:
    information.php
    tpl_site_map_default.php
    Last edited by ITslick; 12 May 2010 at 02:51 PM.

 

 

Similar Threads

  1. Replies: 4
    Last Post: 17 Jul 2015, 04:44 AM
  2. v154 PHP Fatal error Call-time pass-by-reference - tpl_yahootreemenu.php
    By RubenZ in forum Upgrading to 1.5.x
    Replies: 3
    Last Post: 6 Feb 2015, 05:24 PM
  3. Replies: 1
    Last Post: 9 Oct 2011, 06:24 AM
  4. Replies: 2
    Last Post: 21 Aug 2010, 09:13 PM
  5. Could I change the URL from information.php?
    By XiaoChin in forum General Questions
    Replies: 4
    Last Post: 19 Mar 2010, 01:15 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg