Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
0

convert string to numeric

New Here ,
Jul 25, 2008 Jul 25, 2008
I have the following values and would like to convert them to numeric only:
eg.
(86)1234-1234 => 8612341234 ; non numeric characters
(1) 1234 1234 => 112341234 ; remove spaces

Pls kindly advise.
352
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Jul 25, 2008 Jul 25, 2008
look up REREPLACE() function in the cfml reference and regular
expressions in CF topic in the Dev Guide. specifically regex classes
will be useful to you here

Azadi Saryev
Sabai-dee.com
http://www.sabai-dee.com/
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Jul 25, 2008 Jul 25, 2008
LATEST
#REReplace(strToReplace, "[^0-9]", "", "ALL")#

--
Ken Ford
Adobe Community Expert - Dreamweaver/ColdFusion
Fordwebs, LLC
http://www.fordwebs.com


"dynason" <webforumsuser@macromedia.com> wrote in message news:g6ec7n$7a0$1@forums.macromedia.com...
>I have the following values and would like to convert them to numeric only:
> eg.
> (86)1234-1234 => 8612341234 ; non numeric characters
> (1) 1234 1234 => 112341234 ; remove spaces
>
> Pls kindly advise.
>
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Resources