The problem I have is that the glossary terms description is showing special HTML characters

Lorum ispum "dolor > sit" amet!

will render as:

Lorum ispum &rsqou;dolor > sit&rsqou; amet!

This problem only seems to occur when the term is linking to the Lexicon page. I've been playing around with the settings, without any succes.
How can I prevent this from happening, while keeping the link on the term?

Thanks in advance,

Jeroen

CommentFileSizeAuthor
lexicon_description.jpg174.43 KBJeroenD
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

Marty2081’s picture

What is in the term description a '"' or a '"'? The title attribute that is used for the hover effect by default cannot handle HTML characters and will display " as ". I can image that when you use a WYSIWYG editor it will replace special characters by their HTML encoded equivalent. Then maybe you want to use another method of providing a hover effect by overriding the lexicon-mark-term.tpl.php and use jQuery Dialog or something like that.

Shoffner’s picture

It's a bit of a hack, but I'm on a deadline, so is what it is... I needed to deal with ampersand, "&", there are obviously more cases that should be dealt with... Anyway, I grabbed a copy of lexicon-mark-term.tpl.php, dropped it in my themes template folder and put this in instead of what was there :

<?php 
if ($text == "amp"){
  print $text;
}
else {
  print l($text, $term["linkto"], array(
  'attributes' => array(
    'title' => $term["term"]->safe_description,
    'class' => array($term["term_class"]),
  ),
  'fragment' => $term["fragment"],
  'absolute' => $term["absolute_link"],
  ));
}
?>
ilgriso’s picture

Issue summary: View changes

I had this issue and I solved by set in my ckeditor under Advanced Options the HTML entities to No, as reported here:
https://drupal.org/node/1851406

kalistos’s picture

Status: Active » Needs review

Fixed it in this issue.
https://www.drupal.org/node/1823066#comment-10186194

I think this issue should be closed as dublicate.

kunjaljoshi’s picture

The patch for html chars in hover worked for us as well. Thank you.