Beefy Boxes and Bandwidth Generously Provided by pair Networks
XP is just a number
 
PerlMonks  

Re: How to remove other language character from a string

by Tux (Monsignor)
on Nov 26, 2012 at 07:00 UTC ( #1005581=note: print w/ replies, xml ) Need Help??


in reply to How to remove other language character from a string

If what I read is actually your code, you'll need HTML::Entities and a /g modifier to s///:

$ cat test.pl use 5.14.1; use warnings; use HTML::Entities; my $image; $image ='ครัวซองเ&#364 +8;ซนด์วิชไข&#36 +56;ดาว Croissant Egg Sandwich ครั +วซองเเซนด&#3660 +;วิชไข่ดาว'; $image = decode_entities ($image); $image =~ s/\p{Thai}//g; print $image; $ perl test.pl Croissant Egg Sandwich $

Enjoy, Have FUN! H.Merijn


Comment on Re: How to remove other language character from a string
Select or Download Code

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (6)
As of 2015-07-07 06:48 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (87 votes), past polls