Beefy Boxes and Bandwidth Generously Provided by pair Networks
Problems? Is your data what you think it is?

Re: substituting 1 escaped character for another

by herveus (Parson)
on Jul 26, 2018 at 17:02 UTC ( #1219328=note: print w/replies, xml ) Need Help??

in reply to substituting 1 escaped character for another


I executed those two lines, and it worked fine for me.

Can you tell us more about your environment? Because that code should be fine.

  • Comment on Re: substituting 1 escaped character for another

Replies are listed 'Best First'.
Re^2: substituting 1 escaped character for another
by craigt (Acolyte) on Jul 26, 2018 at 17:25 UTC

    Thanks for responding you all. My server is running Apache/2.0.64 (Win32) mod_perl/2.0.3 and Perl/v5.8.3. My server is an off the shelf PC running the latest version of Windows 10. The application executes in the WWW environment. I test on the latest versions of IE, Edge, FF, O, and Chrome.

      It looks like your problem is somewhere other than those two lines. Perhaps if you could pare down your actual code into the smallest portion that reproduces your problem we could better help figure out what's happening.

      I'm guessing a bit here, but when you say "The application executes in the WWW environment", I'm guessing that you are trying to modify an HTML page? Show us a segment of the HTML page and your code to decode and encode text -> HTML. Your regex will work fine on regular text, but I suspect that is not what you actually have.

      In recent memory, I did a quickie kludge to handle the ampersand character in one "get it done right now" LWP application, $clubName =~ s/&/&/g; &amp is what HTML needs to display the ASCII & character. I suspect something similar is going on. We need more info...

        Yes, good thinking there. More guessing:

        The string may have 'non-printable' characters, it may have been copied and pasted from an editor that contains the characters (that are not visible but are actually there. Something like this kept me awake one night).

        This may also be Unicode related. Did some googling, found a good example here:

        I'm going to play with it some more. I'll be back. Thanks everyone.

Log In?

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://1219328]
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others chilling in the Monastery: (1)
As of 2022-01-17 04:36 GMT
Find Nodes?
    Voting Booth?
    In 2022, my preferred method to securely store passwords is:

    Results (51 votes). Check out past polls.