Skip to content

Instantly share code, notes, and snippets.

@phillipsj
Created February 27, 2015 02:20
Show Gist options
  • Save phillipsj/541f16ab8cae65e07994 to your computer and use it in GitHub Desktop.
Save phillipsj/541f16ab8cae65e07994 to your computer and use it in GitHub Desktop.
BeginDirectPostForm Helper
@using (Html.BeginDirectPostForm("ApiLogin", "TransactionKey", 2.25M, "https://YOUR_RELAY_RESPONSE_URL", true))
{
<p>
<div style='float: left; width: 250px;'>
<label> Credit Card Number </label>
<div id='CreditCardNumber'>
<input type='text' size='28' name='x_card_num'
value='4111111111111111' id='x_card_num' />
</div>
</div>
<div style='float: left; width: 70px;'>
<label>Exp.</label>
<div id='CreditCardExpiration'>
<input type='text' size='5' maxlength='5' name='x_exp_date'
value='0116' id='x_exp_date' />
</div>
</div>
<div style='float: left; width: 70px;'>
<label>CCV</label>
<div id='CCV'>
<input type='text' size='5' maxlength='5' name='x_card_code' id='x_card_code'
value='123' />
</div>
</div>
</p>
<div style='clear: both'></div>
<p>
<input type='submit' class='submit' value='Order with DPM!' />
</p>
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment