PassMark Logo
Home » Forum


No announcement yet.

Inline elements in the title (search result page)

  • Filter
  • Time
  • Show
Clear All
new posts

  • Inline elements in the title (search result page)

    Hi folks!

    I am trying to get inline elements in the titles of my result page. The scan is on html files and the title tag is like this one:

    <html xmlns="">
    <title>This is my title <sup>333</sup> <b>bold text</b></title>

    My problem: the result page represents the inline tags as a plain text instead to interpret them as an html markup. The markup of <b> and <sup> is escaped:

    <a href="page_00003.htm?zoom_highlight=This+is+my+tit le">
    <span class="highlight">This</span> is <span class="highlight">my</span> <span class="highlight">title</span> &lt;sup&gt;333&lt;/sup&gt; &lt;b&gt;bold text&lt;/b&gt;

    How can I get inline tags in my result page titles?

  • #2
    The answer is that you can't get inline tags in your results page. The behavior you are seeing is normal, including any markup inside the <title> tag is not consider valid HTML.

    See the spec,

    You can also verify this by running your page through W3C Markup Validation Service.


    • #3
      Well,*the answer was*not unexpected * Is there*another option?*For example*-* take*the result item*from some different html-element?
      I saw that*this is possible*for PDF and for some other file formats.

      Any other*workaround would be*welcome too.


      • #4
        I can't think of any solution except to use valid HTML, or customise our script.