adambedford Posted February 9, 2010 Share Posted February 9, 2010 I'm working on a project that uses PayPal and Instant payment notification and I need to access some of the data that is stored as a session (on my site) from the paypal IPN script. Its not working at the moment because I believe the IPN script is actually executed by Paypal and so it doesn't have access to the session variables that were established by the user on my site. Is there a way to set the variables so they can be accessed by both users? I can pass 1 custom value through paypal as a hidden field so I'm thinking I could pass the Session user ID or something so that the IPN script can obtain it and use it to pretend it's the same user. Is this even possible? I've already considered passing all my data through the custom field using delimeters but there is a 140 character limit and I have more than that to pass. If anyone has any ideas or suggestions as to how to solve this they would be greatly appreciated. Quote Link to comment https://forums.phpfreaks.com/topic/191500-is-there-a-way-to-access-session-variables-from-another-website/ Share on other sites More sharing options...
mikesta707 Posted February 9, 2010 Share Posted February 9, 2010 yes you will have to send the session data as a get or post in order for paypal to get it, as session information is stored on the server itself Quote Link to comment https://forums.phpfreaks.com/topic/191500-is-there-a-way-to-access-session-variables-from-another-website/#findComment-1009481 Share on other sites More sharing options...
adambedford Posted February 9, 2010 Author Share Posted February 9, 2010 How would i go about that? What information would I have to send in order for Paypal to be able to access the session created by my user? And how would I retrieve that in the PayPal script and verify it? Thanks for your help Quote Link to comment https://forums.phpfreaks.com/topic/191500-is-there-a-way-to-access-session-variables-from-another-website/#findComment-1009491 Share on other sites More sharing options...
mikesta707 Posted February 9, 2010 Share Posted February 9, 2010 i'm not familiar with the paypal API, so I can't tell you exactly what to do, but the paypal api documentation will surely have the answer Quote Link to comment https://forums.phpfreaks.com/topic/191500-is-there-a-way-to-access-session-variables-from-another-website/#findComment-1009494 Share on other sites More sharing options...
adambedford Posted February 9, 2010 Author Share Posted February 9, 2010 Thanks for your help. But I'm not using the API, just the Web payments standard. And the documentation is quite confusing. My question is more related to sessions though, How can I get a second user to be able to view the session data of user 1? What information do I have to have available and how would I verify that it was correct. I've got my PayPal part of the script sorted, but I don't have access to the session data that was established by the client on my website. Is there another way to go about it? Such as global variables or cookies, although wouldn't cookies be too vulnerable? Thanks Quote Link to comment https://forums.phpfreaks.com/topic/191500-is-there-a-way-to-access-session-variables-from-another-website/#findComment-1009499 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.