Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9141769
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 17, 20262026-06-17T09:41:20+00:00 2026-06-17T09:41:20+00:00

In MooTools More (1.4), there is a Number.format() function which takes a number and

  • 0

In MooTools More (1.4), there is a Number.format() function which takes a number and converts to a readable format, such as…

"5,003.2" === (5003.2).format()

.. considering the currently set Locale.

My question: Is there a possibility to have the reverse effect happen, e.g. for storing the plain numbers in a database? Something like:

5003.2 === "5,003.2".reverseformat()

Or do I have to use RegEx?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-17T09:41:21+00:00Added an answer on June 17, 2026 at 9:41 am

    There isn’t one that is readily available and it’s not trivial. The string you have there is easy to do via regex but regex does not really tell you what the Locale is and what the custom format looks like.

    For instance, seeing 5,300 in the UK should go to a cool 5300. In EU, it will often mean rounding to 5.3.

    Having said that, see http://josscrowcroft.github.com/accounting.js/

    it also supports unformat which can bring it back.

    Trusting client Locale is general can also be falsy, people travel with laptops… Though this is more applicable to Locale time/timezone stuff.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Currently I am using Form.Validator from Mootools 1.2.5 and Mootools-More 1.2.5, but i am
There are a number of great Javascript libraries\frameworks out there (jQuery, Prototype, MooTools, etc.),
In mootools I would do something like $('form_id').send({success:function(res){....}}); What is the parallel syntax in
I am working a project currently in which the user can add multiple news
I'm currently looking for some libraries which might help me during iPhone Development using
So I have a page that uses both Prototype and Mootools AJAX scripts. There
I translate some Mootools script to jQuery, and I have function: play:function( delay, direction,
I am using MooTools 1.4.1 (full More) and experience a problem with inheriting Locale.define('de-CH').inherit('de-DE',
I have a couple of MooTools XHR requests which I want to handle synchronously.
i'm struggling with converting a menu from mootools to jquery. there are various reasons

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.