Ticket #342 (closed defect: fixed)

Opened 1 month ago

Last modified 4 weeks ago

Profile edit page displays empty categories

Reported by: kevin Assigned to: nobody
Priority: normal Milestone: 0.9.2
Component: core Version: 0.9.0
Severity: normal Keywords:
Cc: Patch Included: 0
Review Stage: reviewed

Description

If a category exists for one profile usertype but not another, the category still appears as a tab even if the corresponding page is empty.

Eg. even if there are no fields of category "Education" defined for a community profile, the "Education" tab still appears so long as there are such fields for personal profiles.

To fix this, change the lines:

$body .= "<div class=\"tabbertab\" title=\"$cat\">"; $body .= $html; $body .= "</div>";

in /profile/profile.class.php

to

if ($html) {

$body .= "<div class=\"tabbertab\" title=\"$cat\">"; $body .= $html; $body .= "</div>";

}

Change History

04/17/08 14:01:35 changed by kevin

As usual, Trac has managed to mangle the PHP source, but I think that you get the idea.

04/22/08 07:52:19 changed by misja

  • review_stage changed from unreviewed to reviewed.

Applied suggested fix in r1582 - consider adding a diff next time ;)

04/22/08 08:06:34 changed by misja

  • status changed from new to closed.
  • resolution set to fixed.

Forgot to close this ticket.