Suzanne Wrede - 2014-01-18 08:11:01
Hi,
I have no idea what I am doing but here goes. After using your impressive solution to access data from Fitbit using the login_with_fitbit.php, I am now trying to store the OAuth session info and suspect I have introduced a whole new world of bugs by updating the classes to work with PDO for SQL Server.
My efforts continue to fail because the $oauth variable is NULL and it seems to be NULL because the CreateOAuthSession does not perform the insert.
I find that the session variables all hold more than one value. For example, when CreateOAuthSession is called, the $parameters variable has more than one value for each variable - there are multiple arrays in the parameter which caused the insert to fail. A simple var_dump($session->state) in the CreateOAuthSession class returns: array(0) { } string(32) "299d5ca70a7bb06cee2f8a96b904caef" array(0) { } array(0) { } string(32) "83a19b40b5cb0433eb17599fbf96cbaf" array(0) { } array(0) { }
If I hard code values, the Insert succeeds so I know success is possible but clearly I am overloading the variables. Well, I say clearly but all that is really clear is that I don't know what I am doing...
Am I making any sense? Have a created this scenarios because of the PDO modifications or perhaps with my testing having created too many sessions floating around and if so, how do I address those/create a reasonable testing ground?
Thank you for any light you can shed,
Suzanne