Score:0

Book child title containing html tags is escaped

it flag
MMT

I have a Drupal 7.97 with a book e.g. node 1 that has three children nodes of e.g. nodes 2,3,4. In one of the children nodes title e.g. node 3 title I'm using an simple html tag:

Node 3 sample title <em style="color:blue;">highlighted text</em>

All the nodes are of type book page.

When displaying the page site.com/node/3 everything is fine, the html title is stripped of the tag as it should be, I understood to prevent some types of attacks.

However when displaying the site.com/node/1 meaning the book parent node, the default behavior of the books module is to display at the bottom of the page the children nodes titles in an bullet point html list.

In this bullet point list I get something like

  
    Node 2 title
    Node 3 sample title <em style="color:blue;">highlighted text</em>
    Node 4 title
    
  

How can I strip the html tags from the bullet list displayed by default by the book module?

Some might interpret this as a defect, as the html title of page 3 is stripped of html characters, whereas the book module does not strip them nor display them properly as html. For me both options would be fine to strip the html characters of display them properly.

Many thanks.

I sit in a Tesla and translated this thread with Ai:

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.