Advanced search  

News:

cpg1.5.48 Security release - upgrade mandatory!
The Coppermine development team is releasing a security update for Coppermine in order to counter a recently discovered vulnerability. It is important that all users who run version cpg1.5.46 or older update to this latest version as soon as possible.
[more]

Pages: [1]   Go Down

Author Topic: Buddy manager bugfix  (Read 4745 times)

0 Members and 1 Guest are viewing this topic.

jesusarmy

  • Contributor
  • Coppermine novice
  • ***
  • Offline Offline
  • Posts: 34
Buddy manager bugfix
« on: January 08, 2008, 02:37:33 pm »

I hope it's OK to post this here. I guess there must be some instructions on bug reports, but I really can't find them :-(

1. The buddy manager meta refresh pages don't display gracefully, as they show the main buddy manage page as well as the notifications. Depending on the custom theme, that may result in headers being shown halfway down the page. To fix this, in buddy_manage.php, find:

Code: [Select]
pagefooter();replace (10* times) with:

Code: [Select]
pagefooter();ob_end_flush();die();
*That is, every time except the last one, 2 or 3 lines just before the end.

2. The second "form" doesn't terminate if there are no buddies. This potentially affects the display of the footer (for example, I have language and theme select forms at the bottom of the page). Also, the "select all" check box doesn't work, as the second form starts after the check box.

Find:
Code: [Select]
if ($tot_view[$view] == 0) { // if no buddies in this box we don't need the check/ uncheck all box in the toptable header
$display_checkall = "";
} else {
$display_checkall = <<<EOT
<span class="smallfont" style="float:right">
<label for="checkall_all">
$lang_buddy[users]: <strong>$total</strong>
<input type="checkbox" name="allbox" id="checkall_all"  onclick="checkBoxes(this.form, this.checked)">
</label>
</span>
EOT;
}



echo <<<EOT
<form action="buddy_manage.php" method="post" name="form">

Change to:

Code: [Select]
if ($tot_view[$view] == 0) { // if no buddies in this box we don't need the check/ uncheck all box in the toptable header
$display_checkall = "";
} else {
$display_checkall = <<<EOT
<form action="buddy_manage.php" method="post" name="form">
<span class="smallfont" style="float:right">
<label for="checkall_all">
$lang_buddy[users]: <strong>$total</strong>
<input type="checkbox" name="allbox" id="checkall_all"  onclick="checkBoxes(this.form, this.checked)">
</label>
</span>
EOT;
}



echo <<<EOT
« Last Edit: January 08, 2008, 04:13:57 pm by Joachim Müller »
Logged

Stramm

  • Moderator
  • Coppermine addict
  • ****
  • Country: 00
  • Offline Offline
  • Gender: Male
  • Posts: 6006
    • Bettis Wollwelt
Re: Buddy manager bugfix
« Reply #1 on: January 08, 2008, 03:11:37 pm »

Thank you ;)
Pages: [1]   Go Up
 

Page created in 0.022 seconds with 20 queries.