Solved

Need to post form data from java and proceed to a website

Posted on 2006-06-20
7
403 Views
Last Modified: 2010-03-31
Hi  all,

We have a site developed using struts. We are adding a payment gateway to it, however, my problem is this.
We need to post data to this site then proceed to this site for the customer to enter their credit card information and when successfully completed they are returned to our website. We sell online learning so the real issue is if they saw the return URL they could use this and get enrolled in classes without actually paying for them.

I need to know how to post form data to another website but have it hidden from the user. I can post from Java that's not the issue and retrieve the response, the issue is I need to go to the website with the posted data and have the customer interact with the site before returning to our site. I want it hidden and would prefer to do it using Java.

I may not have explained this correctly but hopefully, you get the idea.
A page that displays hidden text boxes would allow a user to see the return URL.
Any ideas would be appreciated.

0
Comment
Question by:rj_stone
[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
  • 2
  • 2
  • 2
  • +1
7 Comments
 
LVL 1

Expert Comment

by:sharath_kulal
ID: 16945407
don't know what payment gateway u're using, but if the gateway provider has webservice for CC check. then you could have you're own screen for the customer to enter CC details and from your servlet call the webservice of the provider with CC details for authorization.

even if the provider doesn't provide you webservice, then check if they would accept URL query strings which you could create at the server.

hope this helps
0
 

Author Comment

by:rj_stone
ID: 16945551
Payment gateway the customer wants to use is internetsecure
0
 
LVL 1

Accepted Solution

by:
sharath_kulal earned 300 total points
ID: 16945864
i just went thru their site and there is an option of "Merchant Direct" on this page:

http://www.internetsecure.com/solutions-integration.htm

This is based on  XML-based API and so you should be able to communicate from your server to their server thru XML for Credit Card authorizations, this seems to be a more flexible option and you would have better control of transactions on your server.

0
Get 15 Days FREE Full-Featured Trial

Benefit from a mission critical IT monitoring with Monitis Premium or get it FREE for your entry level monitoring needs.
-Over 200,000 users
-More than 300,000 websites monitored
-Used in 197 countries
-Recommended by 98% of users

 
LVL 30

Assisted Solution

by:Mayank S
Mayank S earned 100 total points
ID: 16948785
The other web-site would've exposed a servlet or a web-service to which you need to post data and get the response - make use of that and you don't need to display anything to the user while that processing is taking place.
0
 
LVL 35

Assisted Solution

by:girionis
girionis earned 100 total points
ID: 16949221
> if they saw the return URL they could use this and get enrolled in classes without actually paying for them.

you could make this page secure and require a form-based authentication. Then anyone that would need to have access to this page would need to supply a username/password. By doing it you ensure that noone that hasn't paid can access the site.
0
 

Author Comment

by:rj_stone
ID: 16951551
I saw the XML API but the client does not want any processing to take place on our site. They want all processing done on internetsecur's website.

So unfortunately we need to allow the users to interact with the site before redirecting back to us. I think I can make use of a hidden page and post from it via struts. If the address bar is hidden then the page name probably won't e visible.

Thanks for the ideas though. Its appreciated. I'll split the points betwwen you all.




0
 
LVL 35

Expert Comment

by:girionis
ID: 16952231
Thanks for accepting, glad I was of help :)
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

Introduction Java can be integrated with native programs using an interface called JNI(Java Native Interface). Native programs are programs which can directly run on the processor. JNI is simply a naming and calling convention so that the JVM (Java…
Introduction This article is the last of three articles that explain why and how the Experts Exchange QA Team does test automation for our web site. This article covers our test design approach and then goes through a simple test case example, how …
Viewers learn about the “for” loop and how it works in Java. By comparing it to the while loop learned before, viewers can make the transition easily. You will learn about the formatting of the for loop as we write a program that prints even numbers…
Viewers will learn how to properly install Eclipse with the necessary JDK, and will take a look at an introductory Java program. Download Eclipse installation zip file: Extract files from zip file: Download and install JDK 8: Open Eclipse and …

696 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