Download & Extend

Decode of title suggested to handle special characters

Project:Custom Breadcrumbs
Version:7.x-2.x-dev
Component:Code
Category:feature request
Priority:normal
Assigned:Unassigned
Status:postponed (maintainer needs more info)

Issue Summary

I have a website with a single quote in its breadcrumb title:
Something's fishy with China algae plant

This was being displayed as:
Something's fishy with China algae plant

In custom_breadcrumb.module's custom_breadcrumb_nodeapi(), I added the html decode in the following line:
$trail[] = l(html_entity_decode($title, ENT_QUOTES, 'UTF-8'), trim($paths[$i]));

This fixed the problem nicely.

Comments

#1

Thanks for the idea. An alternative solution would be to use decode_entities($title) (see http://api.drupal.org/api/function/decode_entities ). Older sites still running php4 will have problems with html_entity_decode producing a warning something like "cannot yet handle MBCS in html_entity_decode" but decode_entities from the drupal 6 api seems to work fine.

#2

Version:6.x-1.3» 6.x-2.x-dev
Status:active» fixed

This has been implemented in custom breadcrumbs 6.x-2.x-dev.

#3

Status:fixed» closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.

#4

Version:6.x-2.x-dev» 7.x-1.0-alpha1

A patch for the same bug in D7 version of the custom breadcrumbs module.

AttachmentSize
custom-breadcrumbs.patch 693 bytes

#5

Status:closed (fixed)» patch (to be ported)

Update the status to patch the D7 version.

#6

Patch works great for D7.

#7

Thanks for the patch Herve.

#8

Version:7.x-1.0-alpha1» 7.x-2.x-dev
Status:patch (to be ported)» postponed (maintainer needs more info)

Is this still needed in the 7.x-2.x branch?

nobody click here