cfhttp

Hi,

I am using the <cfhttp tag in combination with the <cfhttpparam with the post method.
The problem I have is that the target of the post does not recive the Session variables.
I see I can set up the <cfhttp tag to work with form, url, cgi and file variables but I did not see how the Session or Client ones can be passed.

Thanks.
simiAsked:
Who is Participating?

Improve company productivity with a Business Account.Sign Up

x
 
snakehollywoodConnect With a Mentor Commented:
simply pull the data out of the database and populate the form next time the user returns. No need to use cfhttp.

0
 
YogCommented:
hmm, you can't. Sessions wont work across domain. You have to try cookie.
0
 
MediaStormCommented:
Any variables must be passed across in one of two ways:

1) As URL variables (http://www.xyz.com/index.cfm?session=1
2) As form variables
(input type="hidden" name="session" value="#session.cfid#")

Alternatively you might also want to look at WDDX and/or XML.

MediaStorm
0
Easily Design & Build Your Next Website

Squarespace’s all-in-one platform gives you everything you need to express yourself creatively online, whether it is with a domain, website, or online store. Get started with your free trial today, and when ready, take 10% off your first purchase with offer code 'EXPERTS'.

 
simiAuthor Commented:
What I am trying to do is to save the state of a form and post it at a later time.
Like I have a form, the user checks some of the forme elemens, and then can either perform a post right away or save it and perform the post later. If so, I load all the values saved and perform a cfhttp.

Is there any better way for this ?
Thanks.
0
 
Scott BennettManager TechnologyCommented:
what you can do is save the original form post into session variables then when you wish to post them to the other server convert them into url or formfield variables using <cfhttp>
0
 
simiAuthor Commented:
I meant I want to save the forms between sessions.
0
 
Scott BennettManager TechnologyCommented:
oh, then you can save them into a database table or save them into client variables. then access them when you need them
0
 
simiAuthor Commented:
That's what I did.
I saved them on a file.
Then I can recreate a form and cfhttp it.
I was just wondering if there is a better way.
The difference is that when I use cfhttp the url remains the one of the caller, while using a regular form, the submit makes the url to change.
0
 
Scott BennettManager TechnologyCommented:
well, if you want the URL to change you can use cfhttp to send the form data then <cflocation> to send the user to the other site.

-Scott
0
 
simiAuthor Commented:
I dont't want to show the form, just to run the report.
Anyway I will create hidden fields in a form, then post it on load using a java script statement.
Thanks to all but I can assign the points to only one.
0
 
snakehollywoodCommented:
just out of interested, I saw someone once post that you can distribute points.
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.