cancel
Showing results for 
Search instead for 
Did you mean: 

Allowing Users to Enter Their Own Payment Amount

Hi,

 

I am trying to find a code so a user can input their own payment amount instead of having a set amount in the payment form.

 

This is for a live account, using the Direct Post Method, following integration instructions here:

http://developer.authorize.net/integration/fifteenminutes/

 

Thanks!

3 REPLIES 3

Just use a two-stage process. The first stage has them choose an amount; the second is the regular DPM form. Alternately, you can cheat and use AJAX to pass the amount to a separate page and get back the field values you need to update in the form for it to work for that value. That will require some knowledge of Javascript, though, and you need to remember to set a minimum and maximum amount in the AJAX page so they can't charge 1 cent or something.

TJPride
Expert

Sounds complicated. I am not very familiar with this. I know with some services you can just remove the amount from the code and it will open up that field for editing by the user. I tried that with this service but it didn't work.

 

Any chance there is a simple line of code I can addor edit to the direct_post.php?

Or you can use the "Simple Checkout", just login to the merchant account to setup one up. Set it as a donation and then the "Allow donors to specify the amount they wish to donate" checkbox.

 

Else you could hire one of the certified developers