[Koha-bugs] [Bug 10626] Remove doubled up TT plugins

bugzilla-daemon at bugs.koha-community.org bugzilla-daemon at bugs.koha-community.org
Wed Jul 24 11:47:06 CEST 2013


http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10626

--- Comment #6 from Kyle M Hall <kyle at bywatersolutions.com> ---
The use of encode is to make diacritics display correctly. This issue came up
during the development of the Course Reserves ( Bug 10626 ) feature. You can
see the patch where Paul added the encode to solve the issue here:
http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=18283&action=diff

(In reply to Chris Cormack from comment #5)
> Comment on attachment 19870 [details] [review]
> Bug 10626 - Remove doubled up TT plugins - Merge KohaBranchName and Branches
> 
> Review of attachment 19870 [details] [review]:
> -----------------------------------------------------------------
> 
> ::: Koha/Template/Plugin/Branches.pm
> @@ +32,4 @@
> >      my $sth   = C4::Context->dbh->prepare($query);
> >      $sth->execute($branchcode);
> >      my $b = $sth->fetchrow_hashref();
> > +    return $b ? encode( 'UTF-8', $b->{'branchname'} ) : q{};
> 
> By switching our templates to use this plugin, instead of KohaBranchName.pm
> we have changed the behaviour.
> 
> We are now not using the GetBranchName subroutine, but instead doing a db
> query ourselves (which is probably better we shouldnt be using C4:: modules
> in the Koha:: space) but we are also doing this encode.
> 
> And I am not convinced encode is what we should be doing here. Could you
> please explain why we are doing the encode?

-- 
You are receiving this mail because:
You are watching all bug changes.


More information about the Koha-bugs mailing list