• Post Reply Bookmark Topic Watch Topic
  • New Topic

Working with URLs, listening, etc.  RSS feed

 
George Hutto
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Basic Tech Environment: Oracle DB & order processing.

Users place manual orders for customers who are calling in (these aren't tech-savvy customers since they're not using the company's website).

Once the order is placed in our system the user need to get authorization for the use of the customer's credit card.

So I'm to write an applet that sends basically a userid and orderid (plus other essential info) to a credit card processing site for authorization. Ideally, the cc processing site sends back a response that includes an authorization code (autcode) to a "silent post" URL that my client will host -- if the customer's card passed muster I then have to redirect the employee user to the cc processor's data entry page (passing along, of course, the unique orderid and associate autcode. The user enters all the correct information for the particular order (I know, it seems like a duplication of effort), saves it and we're on our merry way.

Now, I have an idea of how to post the data to the cc processing site's URL for authorization. What I need help with is listening at the "silent post" url. From what I've seen this will tie up port 80 on some dedicated server so that no other process/etc. can ever use that port? And then, how can I grab the autcode that is sent to that "silent post" url, associate it to the orderid and then redirect the user to the data entry web page with this list of parameters?

Sorry to ask such basic questions but it has been a while since I've worked with some of these concepts and then not all were in Java.

Thanks,

George
 
Paul Clapham
Sheriff
Posts: 22828
43
Eclipse IDE Firefox Browser MySQL Database
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Yes, your client will have to run an HTTP server to handle those requests.

And then, how can I grab the autcode that is sent to that "silent post" url, associate it to the orderid and then redirect the user to the data entry web page with this list of parameters?


It would help if you were more specific about what "I" means there. If "I" is the applet, then it already has that autcode so no "grabbing" is required. But if "I" means the HTTP server, then the applet has sent it as part of the URL. At this point I'm confused. You've said you're writing an applet, so you are already requiring an HTTP server to host it. But then you seem to be confused about the requirement for an HTTP server to receive "silent posts". Is this going to be a second HTTP server, or is it going to be the same server?
 
Campbell Ritchie
Marshal
Posts: 56536
172
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
And welcome to the Ranch
 
George Hutto
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Paul Clapham wrote:Yes, your client will have to run an HTTP server to handle those requests.

And then, how can I grab the autcode that is sent to that "silent post" url, associate it to the orderid and then redirect the user to the data entry web page with this list of parameters?


It would help if you were more specific about what "I" means there. If "I" is the applet, then it already has that autcode so no "grabbing" is required. But if "I" means the HTTP server, then the applet has sent it as part of the URL. At this point I'm confused. You've said you're writing an applet, so you are already requiring an HTTP server to host it. But then you seem to be confused about the requirement for an HTTP server to receive "silent posts". Is this going to be a second HTTP server, or is it going to be the same server?


Fair question. From what I can tell in the documentation I've been given, the user enters the information one a web page on one server, the authorization code is posted to another page on a different server. So it seems like the initial applet will have to wait for a reponse from an applet or servelet on the second server to send it the authorization code. And then, once I have the authorization code to associate with this intial orderid that has been generated I use my initial applet to redirect the user to either an "approved" page or a "disapproved" page. I expect I'll have to do some html on the fly to present the right option to the user. BUT .. I am grateful for any help or pointers.

I know, in some ways it seems like going around your rump to get to your elbow.
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!