post back data

Hi

I am trying to capture some data that is coming in as POST in a jsp page

<%

String secCode=request.getParameter("ap_securitycode");

String memID=request.getParameter("apc_1");

%>

I am getting nulls

in the FAQ they say

"Make sure that you are not trying to display any information on your Alert URL page. When AlertPay posts to your Alert URL, it opens a stream. Any display information is actually sent back to AlertPay and not displayed to a user."

Does that mean anything to someone.?

Their technical support is limited to one php sample script

this is the php to capture the same string

$ap_sec_code = $_POST['ap_securitycode'];

I don't know php at all

Thanks

Lena

[852 byte] By [LenaBa] at [2007-11-27 4:11:13]
# 1
JSP and PHP are two completely different languages :o)What exactly do you want to achieve? Your code looks fine. Likely you have just invoked the request in the wrong way or you are capturing the request parameters at the wrong place.And which FAQ are you actually talking
BalusCa at 2007-7-12 9:16:58 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 2

Hi

It is a sort of web service that gets payment from people.

I have sent it the information of what to bill and they are supposed to then forward to my page with a POST the amount and security code and other data.

The FAQ I quoted is off their website to help one debug ones application.

I thought maybe I was getting the POST data wrong.

I know php is a different language but I don't know it and I thought that there were maybe hidden secrets in that piece of code some one could tell me about.

Lena

LenaBa at 2007-7-12 9:16:58 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 3

Start off with servlets. The HttpServlet provides an overrideable doPost() method. This method should be called everytime when you invokes a POST request on the servlet. Implement some business logic in it.

Check the Java EE tutorial how to use servlets: http://java.sun.com/javaee/5/docs/tutorial/doc/ It starts at chapter 3.

BalusCa at 2007-7-12 9:16:58 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 4

Hi

I realize that about the servletts but how can I get it to go there?

When I tried to put a servlet in my pages directory it gave me a huffy message that I shouldn't do that.

I have dozens of servlets that I am using in the application in different source packages. I have to give a URL to the service and I can't figure out how to send it to one of the source packages.

Lena

LenaBa at 2007-7-12 9:16:58 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 5
You have a dozen of servlets but you don't know how to use them?Anyway .. At least you need to define the new servlet in the web.xml and assign an url-pattern to it. Then you can invoke this servlet by a request URI.
BalusCa at 2007-7-12 9:16:58 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 6
I do know how to use them for data base access, streaming jpg and other odd things .If I knew how to use them for this I wouldn't be asking would I?Anyway, it is all set up.So lets deploy the thing on the net and blow our way though again.Lena
LenaBa at 2007-7-12 9:16:58 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 7
> I do know how to use them for data base access, streaming jpg and other > odd things .I was not talking about the actual tasks of those servlets, but how to use/invoke/access them by an URI request.Well, you found it out. Good work tho :)
BalusCa at 2007-7-12 9:16:58 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 8
actually no not that - and I am still playing with themand I keep getting into knots between URI URL UNC and where my page is at any given time.Sometimes I sigh for the simple days of cards and assembler code and massive 64K memories and octal dumpsLena
LenaBa at 2007-7-12 9:16:58 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 9
LOL, the good old times of 64K memories ;)Anyway, the following articles might help:URI: http://en.wikipedia.org/wiki/URIURL: http://en.wikipedia.org/wiki/URLUNC: http://en.wikipedia.org/wiki/Uniform_Naming_Convention#Universal_Naming_Convention
BalusCa at 2007-7-12 9:16:58 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 10
Nothing working stillBack to the drawing board.It would help if they had decent technical support.It doesn't seem that the URL is ever posted toSomething may not be setup right in the accountLena
LenaBa at 2007-7-12 9:16:58 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...