Solved

Request.setCharacterEncoding(CharacterEncoding)

Posted on 2010-11-15
1
974 Views
Last Modified: 2012-05-10
Dear Team,

I have integrated one payment gateway in one of my project when i am doing some transaction its redirecting me to payment gateway page but after transaction when its redirecting me to result page ,page giving me some error please check the below link to check error.

And also i am attaching my code.
<%@ Page Language="C#" AutoEventWireup="true" CodeFile="msg.aspx.cs" Inherits="msg" %>


<%
// encoding
String CharacterEncoding = "UTF-8";
Request.setCharacterEncoding(CharacterEncoding);
String BillNo = Request.getParameter("BillNo");
String Currency = Request.getParameter("Currency");
String Amount = Request.getParameter("Amount");
String Succeed = Request.getParameter("Succeed");
String Result = Request.getParameter("Result");
String MD5info = Request.getParameter("MD5info");
String MD5key = "IWMkrbnm";
System.Security.Cryptography.MD5 md5 = new System.Security.Cryptography.MD5();
String md5src = BillNo + Currency + Amount + Succeed + MD5key;
String md5str;
md5str = md5.getMD5ofStr(md5src);
%>
<html>
<head><title> Payment Result </title></head>
<body>
<p align="center"> Payment Result </p>
<table align="center" border="1" cellpadding="4">
<tr>
<td> BillNo:</td>
<td><%=BillNo%>
</td>
</tr>
<tr>
<td> Currency </td>
<td><%=Currency%>
</td>
</tr>
<tr>

<td> Amount </td>
<td><%=Amount%>
</td>
</tr>
<tr>
<td> Succeed </td>
<td><%=Succeed%>
</td>
</tr>
<tr>
<td> Result </td>
<td><%=Result%>
</td>
</tr>
<tr>
<td> MD5info </td>
<td><%=MD5info%>
</td>
</tr>
<tr>
<td> Calculate md5</td>
<td><%=md5str%>
</td>
</tr>
<tr>
<td> Validate md5 hash validate </td>
<td><%=(md5str.equalsIgnoreCase(MD5info)) ? "equal" : "not equal"%>
</td>
</tr>
</table>
<p align="center"><a href="#" onclick="javascript:window.close()"><font size="2" color="blove">¿Close¿</font></a></p>
</body>
</html>

Open in new window

0
Comment
Question by:virafh
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
1 Comment
 
LVL 5

Accepted Solution

by:
soujanya_g earned 500 total points
ID: 34143178
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Today is the age of broadband.  More and more people are going this route determined to experience the web and it’s multitude of services as quickly and painlessly as possible. Coupled with the move to broadband, people are experiencing the web via …
ASP.Net to Oracle Connectivity Recently I had to develop an ASP.NET application connecting to an Oracle database.As I am doing it first time ,I had to solve several problems. This article will help to such developers  to develop an ASP.NET client…
In this video we outline the Physical Segments view of NetCrunch network monitor. By following this brief how-to video, you will be able to learn how NetCrunch visualizes your network, how granular is the information collected, as well as where to f…
Monitoring a network: how to monitor network services and why? Michael Kulchisky, MCSE, MCSA, MCP, VTSP, VSP, CCSP outlines the philosophy behind service monitoring and why a handshake validation is critical in network monitoring. Software utilized …
Suggested Courses

623 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question