Hi,

I hope you can help me with a dilemma that I have encountered.

I am rendering data in an HTML page. The data is coming from my database (mysql). The database gets updated on a nightly
basis from an external source.

When rendering the title of a book, a few, not many, show a '?'. When I check the database it does not show the '?'.
I copied and pasted the title into VI. VI showed <200b>.

So I inserted a regex substitution as I looped through the list of books. It did not remove it.

This is what I see in HTML, Sustainable B?usiness?
This is what I see in the database, Sustainable Business

I am using Class::DBIx. In the connection package I include 'use utf8;'. In the HTML page, I use <meta charset="UTF-8">.
Yet, it still shows the '?'. I have also tried several substitution Perl regexes. Here are a few:

$booktitle =~ s/\u200b//g; $booktitle =~ s/\x200b//g; $booktitle =~ s/\<200b\>//g:

Has anyone encountered this issue with a hidden unicode character? If yes, how did you remove the unicode character?

Thanks


In reply to Remove u200b unicode From String by phildeman

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.