1 (edited by Dijridew 2008-01-01 13:36:40)

Topic: how to remove the ",00" from price extra field?

hi,
Any idea on how to remove the ",00" from price extra field?
For example I want 12 630,00 $
to look: 12 630 $

can u help
Thanks

Thumbs up Thumbs down

Re: how to remove the ",00" from price extra field?

any idea guys neutral

thanks

Thumbs up Thumbs down

Re: how to remove the ",00" from price extra field?

Admin > Payment > Price format

AndyC

Re: how to remove the ",00" from price extra field?

AndyC wrote:

Admin > Payment > Price format

AndyC

Thank you brother....

Thumbs up Thumbs down

Re: how to remove the ",00" from price extra field?

Can you tell me what to put in price format in order to remove the "00"

For example, if the user type 500.00 I want to show 500

Thanks

Thumbs up Thumbs down

Re: how to remove the ",00" from price extra field?

I use this

::,

which gives no decimal places and a comma as the thousands separator, i.e 1000.00 becomes 1,000

AndyC

Re: how to remove the ",00" from price extra field?

Thanks,
and if I want 1000.00 to become this 1 000 (space instead of coma) ?

Thumbs up Thumbs down

Re: how to remove the ",00" from price extra field?

Sorry but it doesnt work for me.

So what I want is :
- user is not allowed to enter decimal only integer

What to put in the field "Default price (used in input fields)" ?
By default it's /^[0-9]*[.]?[0-9]{0,2}$/
I changed it to /^\d+$ /
But doesn't work

Any idea?

Thumbs up Thumbs down

Re: how to remove the ",00" from price extra field?

jploi wrote:

Thanks,
and if I want 1000.00 to become this 1 000 (space instead of coma) ?

If I remember correctly you need to replace the comma with a space in the Price format box, so

::,

becomes

::

AndyC

Re: how to remove the ",00" from price extra field?

jploi wrote:

Sorry but it doesnt work for me.

So what I want is :
- user is not allowed to enter decimal only integer

What to put in the field "Default price (used in input fields)" ?
By default it's /^[0-9]*[.]?[0-9]{0,2}$/
I changed it to /^\d+$ /
But doesn't work

Any idea?


Does /^\d*$ work?

I couldn't figure out how to change it when I set up my site, that's why is used the Price format box to get rid of the decimal places. If figures are entered after the decimal place the price just gets rounded up. Doing it this way means that the user doesn't get an error message if they do put in decimals.

AndyC

Re: how to remove the ",00" from price extra field?

No, /^\d+$ / didn't work when i put it in "Default price (used in input fields)"

But I already also put ::, in the price format as well.

so to summarize, what I have now :
price format : ::,
Default price : /^\d+$ /

Result : I can't enter anything, it keeps telling me what I enter is incorrect.

Thumbs up Thumbs down

Re: how to remove the ",00" from price extra field?

You need advice from someone familiar with regular expressions - sadly I'm not...

What happens if you return the "Default price (used in input fields)"  to its default and use ::  (colon colon space) in the Price format box?

AndyC

Re: how to remove the ",00" from price extra field?

It does anything good
If I have these :

Default price (used in input fields)  = /^[0-9]*[.]?[0-9]{0,2}$/
Price Format  = ::

I still can enter 500.00 and I don't want. I want user to be able to enter only integer like 500

Thumbs up Thumbs down

Re: how to remove the ",00" from price extra field?

jploi wrote:

It does anything good
If I have these :

Default price (used in input fields)  = /^[0-9]*[.]?[0-9]{0,2}$/
Price Format  = ::

I still can enter 500.00 and I don't want. I want user to be able to enter only integer like 500

What about

/^[0-9]*$/

AndyC

Re: how to remove the ",00" from price extra field?

Sorry for the late reply but /^[0-9]*$/ seems working. It does not allow user to use decimal only integer, that's what I wanted.

Thanks

Thumbs up Thumbs down

Re: how to remove the ",00" from price extra field?

jploi wrote:

Sorry for the late reply but /^[0-9]*$/ seems working. It does not allow user to use decimal only integer, that's what I wanted.

Thanks

No problem, glad we got there in the end smile

AndyC

Re: how to remove the ",00" from price extra field?

I put this :
Price format = ::,
Default price (used in input fields) = /^[0-9]*[.]?[0-9]{0,2}$/
So when the user enters 500.00 it will tell him that decimal is not allowed.

Thumbs up Thumbs down

Re: how to remove the ",00" from price extra field?

jploi wrote:

I put this :
Price format = ::,
Default price (used in input fields) = /^[0-9]*[.]?[0-9]{0,2}$/
So when the user enters 500.00 it will tell him that decimal is not allowed.

zhijing is a spammer - ignore him.

AndyC

Re: how to remove the ",00" from price extra field?

The BIG QUESTION is How Can I set for put the $ sign on the price?

Thumbs up Thumbs down