|
Validates_format_of :price_in_cents, :with =>
What is the regexp for this simple validation
Started by Sam on
, 3 posts
by 3 people.
Answer Snippets (Read the full thread at stackoverflow):
/[0-9]+/ Matches one or more integers, however there are better ways to do this (as seen in marklai's answer). .
You can use validates_numericality_of with only_integer, combined with positive numbers to represent price in pennies .
|
|
I am looking for active clicker. You could click at least 5 days per week.
1. I will pay 5 cent for sign up bonus once registration & click all ads
2. You can request refback every 100 clicks & you will receive 20 cents/100 clicks (variety clicking rate...
Started by ijbank on
, 15 posts
by 8 people.
Answer Snippets (Read the full thread at emoneyspace):
|
|
I am storing a cost in my application. The cost is not formatted in the database. For example: 00.00 saves as 0, 1.00 saves as 1, and 40.50 saves as 40.5
I need to read these values from the database and convert them to strings for dollars and cents. ...
Started by Tony on
, 6 posts
by 6 people.
Answer Snippets (Read the full thread at stackoverflow):
If it exists, split on '....
Alternatively, if you don't mind a bit of performance overhead, check for '.' in the database's value .
So 1 dollar is stored as 100 in the database .
Instead of storing as a decimal, store as an integral number of cents.
|
Ask your Facebook Friends
|
25 Cent On A 1 Cent Planchet Have had this for quite some time..bought it from an older gentleman who got it in the 1980's.
Started by D@7 on
, 7 posts
by 7 people.
Answer Snippets (Read the full thread at numissociety):
Very nice error pick up....I have a nickel on a cent.
I really like that one a lot, very cool.
|
|
I have a label (literal, whatever), that is being filled with currency ($5000.00). Is there an easy way to style the cents, like make the font-size smaller.
I know I can split the two up, but I am using MVP, and am looking for an easy way than passing...
Started by Martin on
, 6 posts
by 6 people.
Answer Snippets (Read the full thread at stackoverflow):
$5000.<span class="Cents">00</span>
How you accomplish this is a bit tricky, you can have a "Dollars" and a "Cents" property and then manipulate the string into the format.
Ideally you need to format it like the following.
|
|
Hi,
I need help identifying these errors and I'd like to know if they are worth keeping.
#1 - 25 cents 2011:
#2 - 25 cents 2011:
#3 - 25 cents 2011:
#4 - 25 cents 2006:
#5 - 25 cents 2011:
Thanks!
Started by patsass on
, 11 posts
by 7 people.
Answer Snippets (Read the full thread at coincommunity):
The lowest image features a bubble that occurred post....
Unfortunately the margin of error they are working with now is enormous .
I don't see anything I'd identify as a die chip, most of the look like plating errors caused by incorrect planchet cleaning .
|
|
Value of 1984 1 cent coin what is todays value of a 1984 1 cent coin?
Started by AntyAnts on
, 15 posts
by 13 people.
Answer Snippets (Read the full thread at za):
cent? "Le mieux est l'ennemi du bien." FM Arouet
"All that is necessary for the triumph of evil shilling
1961 half cent
1967 English silver R1? It's true that before we die, our life passes before our.
|
|
I found this cent roll searching (last roll). I believe it is mad and was wondering if it had much more value then a cent.
Started by brenpickle on
, 12 posts
by 8 people.
Answer Snippets (Read the full thread at coincommunity):
That would sell for $3 to $5 on the bay .
I so far have only found 1.
Nice find!
David yup, nice find.
Save in a 2x2.
Nice mad example Keeper for sure ...
My guess is it should have some extra value.
Don't know much about these but that is a nice one .
|
|
Hi,
I'm trying to figure out how to round a monetary amount upwards to the nearest 5 cents. The following shows my expected results
1.03 => 1.05 1.051 => 1.10 1.05 => 1.05 1.900001 => 1.10
I need the result to be have a precision of 2 (as ...
Started by Don on
, 5 posts
by 5 people.
Answer Snippets (Read the full thread at stackoverflow):
Tom has the right idea, but you need to use BigDecimal methods, since you ostensibly are using BigDecimal because your ... .
It's a hack, but should get you the right answer .
I'd try multiplying by 20, rounding to the nearest integer, then dividing by 20 .
|
|
Hi team,
this is my second Question on Server Fault.
Devices in hand:
Cent OS - 32bit (update) Squid installed (not configured) Sarg installed (not configured) I'm looking for a solution to the following problem:
log all the LAN traffic on Squid. I need...
Started by kartook on
, 5 posts
by 5 people.
Answer Snippets (Read the full thread at serverfault):
So I don't think that a battle you can win, from... .
Or move to a secure one like skype you can't monitor .
Not sure about the over all site monitoring, but as you try an monitor one chat system once people figure out you are they'll just move to another one .
|