Please find the below list of fixes for various BBtoNuke 2.0.21 files. These changes are for the PHP-Nuke 8.0 Version only; however, may also affect other 2.0.21 versions.
In modules/Forums/includes/sessions.php - Compliance Bugs
On lines 589 thr 612 find:
Code:
$url = str_replace("?", "&", $url); // As we are already in nuke, change the ? to &
$url = str_replace(".php", "", $url); // Strip the .php from all the files,
$url = "../../../modules.php?name=Forums&file=$url";
}
else if ((ereg("privmsg", $url)) && (!ereg("highlight=privmsg", $url)))
{
$url = str_replace("?", "&", $url); // As we are already in nuke, change the ? to &
$url = str_replace("privmsg.php", "modules.php?name=Private_Messages&file=index", $url); // and put it back for the modules.php
}
else if ((ereg("profile", $url)) && (!ereg("highlight", $url) && !ereg("profile", $url)))
{
$url = str_replace("?", "&", $url); // As we are already in nuke, change the ? to &
$url = str_replace("profile.php", "modules.php?name=Forums&file=profile", $url); // and put it back for the modules.php
$dummy = 1;
}
else if ((ereg("memberlist", $url)) && (!ereg("highlight=memberlist", $url)))
{
$url = str_replace("?", "&", $url); // As we are already in nuke, change the ? to &
$url = str_replace("memberlist.php", "modules.php?name=Members_List&file=index", $url); // and put it back for the modules.php
} else {
$url = str_replace("?", "&", $url); // As we are already in nuke, change the ? to &
$url = str_replace(".php", "", $url);
$url = "modules.php?name=Forums&file=".$url; //Change to Nuke format
}
Replace with:
Code:
$url = str_replace("?", "&", $url); // As we are already in nuke, change the ? to &
$url = str_replace(".php", "", $url); // Strip the .php from all the files,
$url = "../../../modules.php?name=Forums&file=$url";
}
else if ((ereg("privmsg", $url)) && (!ereg("highlight=privmsg", $url)))
{
$url = str_replace("?", "&", $url); // As we are already in nuke, change the ? to &
$url = str_replace("privmsg.php", "modules.php?name=Private_Messages&file=index", $url); // and put it back for the modules.php
}
else if ((ereg("profile", $url)) && (!ereg("highlight", $url) && !ereg("profile", $url)))
{
$url = str_replace("?", "&", $url); // As we are already in nuke, change the ? to &
$url = str_replace("profile.php", "modules.php?name=Forums&file=profile", $url); // and put it back for the modules.php
$dummy = 1;
}
else if ((ereg("memberlist", $url)) && (!ereg("highlight=memberlist", $url)))
{
$url = str_replace("?", "&", $url); // As we are already in nuke, change the ? to &
$url = str_replace("memberlist.php", "modules.php?name=Members_List&file=index", $url); // and put it back for the modules.php
} else {
$url = str_replace("?", "&", $url); // As we are already in nuke, change the ? to &
$url = str_replace(".php", "", $url);
$url = "modules.php?name=Forums&file=".$url; //Change to Nuke format
}
In modules/Forums/language/lang_english/lang_main.php - Compliance Bug
On line 561 find:
Code:
target=\'_other\'
Replace With:
Code:
target=\'_blank\'
Finally, an optional compliance fix for the FAQ function in forums:
Explanation: Please note the below is an optional fix that works and fixes compliance until a long-term solution may be identified to fix the fact that the value of each FAQ section is a number defined as an "ID/Name" field, which of course is not allowed. I am simply adding the letter "A" to the beginning of the FAQ link value to fix the problem; however, to work both the FAQ file and the corresponding theme file must both be addressed.
In modules/Forums/faq.php - FAQ Compliance ID Bug
On line 143 Find:
Code:
'U_FAQ_LINK' => '#' . $faq_block[$i][$j]['id'])
Replace with:
Code:
'U_FAQ_LINK' => '#A' . $faq_block[$i][$j]['id'])
Next, in your theme, you must edit the corresponding relationship to fix the other half of this.
Open your theme files at: /themes/YOURTHEME/forums/faq_body.tpl and find:
Code:
{faq_block.faq_row.U_FAQ_ID}
as in id={faq_block.faq_row.U_FAQ_ID} or however your theme puts it there. Simply add an "A" before it to make the ID valid.
Thus:
Code:
id={faq_block.faq_row.U_FAQ_ID}
Should actually look like this:
Code:
id=A{faq_block.faq_row.U_FAQ_ID}
NOTE: Depending on your theme, it may be listed as "name={faq_block.faq_row.U_FAQ_ID}". If so, change "name" to "id".
Finally, also in the faq_body.tpl search for:
Code:
#Top
and replace with
Code:
#
Yes, ending your link with simply # will automatically return you to the top of the file.
If you have a compliant theme, after making these changes, your forums should be W3C compliant with the exception of the bug identified at the top of this post.
Hope this helps. (This post modified 11/04/06 @ 2:40am (EST) to add the line 1059 change in posting.php so you don't have to open it twice.)
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum