473,322 Members | 1,417 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,322 software developers and data experts.

How to remove diacritic of a string

....in the easiest possible way. Do you have any idea? Any function or
regexp?

Thanx

Spaiky
Jul 17 '05 #1
2 8791
On Thu, 22 Jan 2004 23:47:58 +0100, "Vladish" <V.*******@sh.cvut.cz> wrote:
...in the easiest possible way. Do you have any idea? Any function or
regexp?


Depends what character set the string is encoded in.

--
Andy Hassall <an**@andyh.co.uk> / Space: disk usage analysis tool
<http://www.andyh.co.uk> / <http://www.andyhsoftware.co.uk/space>
Jul 17 '05 #2
[ Please, but your question in the body of the post ]

Vladish wrote:
Subject: Re: How to remove diacritic of a string
...in the easiest possible way. Do you have any idea? Any function or
regexp?


Do you want "João Graça" -- my brother's name :) --
transformed into "Joao Graca"?

hmmmm ...

strtr()
<?php
$in = 'João Graça';
$with = 'áàãéèêíìîóç'; ## . other characters,
$wout = 'aaaeeeiiioc'; ## . uppercase, etc.
$out = strtr($in, $with, $wout);
?>

but you'll have all sorts of problems with different charsets.
--
--= my mail box only accepts =--
--= Content-Type: text/plain =--
--= Size below 10001 bytes =--
Jul 17 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: soni29 | last post by:
hi, how can i remove a string from an existing string in javascript. i have a textbox in a form and want to make sure that when the user clicks a button that certain words are moved, like all...
0
by: TomislaW | last post by:
is it possible?
10
by: teenIce | last post by:
Hi all, Does anyone have suggestion what can I do to remove some string from a string? Like this : Original : I have a cat. Remove : have Result : I a cat. Thanks in advance.
36
by: laredotornado | last post by:
Hi, I'm using PHP 5. I have an array of strings. What is the simplest way to remove the elements that are empty, i.e. where the expression "empty($elt)" returns true? Thanks, - Dave
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.