PDA

View Full Version : Passing API Vales from 1 page to another


jferg
10-26-2009, 10:08 PM
Hello-

I want to pass some API values from 1 page to another so I can create a sub set API for customers we have that gives them additional benefits beyond the main API we wil be using. Is this possible to do and if so what would be a good methodology?

For example, Primary API place post request to our URL, we then pass the variables of that post on to another page that reads what the API posts and includes additional data from our end to our clients.

Thanks for any help.

Mike_O
10-27-2009, 04:23 AM
Hey jferg,

It is not a problem to pass values from page to page. The question is how you want to do it. Here are some common methods that you might choose from:

1. Use the post method. Prior to submitting, put values in hidden tags (that is if they are already not contained in some tag). When you get to the next page, request them.

2. Store values in a database. One big reason you might want to do this is for security, as hidden tags can be seen in the source code of the page.

3. Another choice is to store them in session variables.

So, now you have a few possible options to ponder about. I would dwell a bit into each one and see what works better for you.

Regards,
Mike