Guys,
I am trying to use ASP.net integration with Auth.Net.. Trying to use Silent Post url by setting the silent post url value to my aspx link in my Authrize.net account. Load event of the page is not getting called . I am using the receipt_LINK method = "LINK". Did not work!! Nothing happens...
If I am using the receipt_LINK method = "POST" I amgetting the below error:
Validation of viewstate MAC failed. If this application is hosted by a Web Farm or cluster, ensure that <machineKey> configuration specifies the same validationKey and validation algorithm. AutoGenerate cannot be used in a cluster
My payment form and receipt form is with Authorize.Net. I want to save the transaction details after the completion wile navigates back to my URL.
Please Help!! Urgent Plz..
Thanks...
-K
Solved! Go to Solution.
04-20-2012 12:19 PM - edited 04-20-2012 12:23 PM
What is this?
x_receipt_link_URL.Value = SilentForm.aspx;
Need to be "Post", "Link" will never work.
x_receipt_link_method.Value ="Link";
So even if you have EnableViewStateMAC="false" on both those pages. It it still getting
Validation of viewstate MAC failed. If this application is hosted by a Web Farm or cluster, ensure that <machineKey> configuration specifies the same validationKey and validation algorithm. AutoGenerate cannot be used in a cluster
When you click on "click here to return to our home page"
04-23-2012 08:58 AM
1)"Link" do NOT pass any param to your asp.net page
2)For viewstat MAC failed. set EnableViewStateMac="false" on both your SIM form page and the "silent post" page. Or as the error said, set the machineKey in the web.config.
3)You don't need to post to "silent post" page from receipt page. Authorize.net will it when it process the transaction.
04-20-2012 12:37 PM
Thanks Ray!
But if I donot post to silent page from reeipt page. LOAD fuction from silent page is not getting called. I have only set the Silent Post URL value to y sientpage.aspx.
Am I missing anything??
04-20-2012 01:26 PM
Did you set the silent post URL on the merchant account setting?
04-20-2012 01:29 PM
Yes I dd!! Actually I only did that.
04-20-2012 01:30 PM
That mean the authorize.net can't get to your slient post URL, or encounter an error or something.
Using https? SSL certificate valid?
Read this
Relay Response Basics and Troubleshooting
You can also set it up as a relay response and test it, it will give you a better idea of what might be causing problem.
04-20-2012 01:37 PM
I am using HTTP only.
I got failed implementing the relay response and wanting to try this SILENT POST :(
Are there any other Auth.NET variables i need to set other than the Merchant interface value?
04-20-2012 01:41 PM
If you getting an error on relay response, you will get the same problem on the silent post. Did it get a timeout error?
Did the post from the reciept page to your silent post URL work? after adding the EnableViewStateMac="false"?
04-20-2012 01:54 PM
Yes Sir! I got the time out error. I tried to have my receipt page (in my website)
Later this afternoon when the called Authorize.NET and said
I am using the Auth's Payment form. And so I have to use their receipt page only it seems . (Said by a customer care agent). So now wanting to use this silent url feature to store some transaction values after the completion of the transaction in my log file.
I have this function in the load function of my SilentPost url page.
if (this.Request.Form["x_response_code"] != null)
{
int icount = 0;
string data = "Started to write " + DateTime.Now.ToString() + "\n\r";
string destPath = System.Web.HttpContext.Current.Server.MapPath("~/bin");
System.IO.
File.WriteAllText(destPath + "\\SilentPost.txt", data);
data =
" ";
while (icount < Request.Form.Count)
{
data = data + Request.Form[icount].ToString() +
"\n\r";
icount++;
}
data +=
"**********DONE**********";
System.IO.
File.AppendAllText(destPath + "\\SilentPost.txt", data);
}
I have EnableViewStateMac = "false" in my silent post page.
04-20-2012 05:58 PM
Just want to be clear so.
Relay response didn't work.
Silent post didn't work.
Post from the receipt page didn't work either?
04-21-2012 09:35 AM