The Foxy forums are on the move!

We're in the process of moving our forums over to a new system, and so these forums are now read-only.
If you have a question about your store in the meantime, please don't hesitate to reach out to us via email.

sub_token

itisnot_meitisnot_me Member
in Help edited October 2010
ok so im trying to collect the subtoken after someone has bought into my subscription. but it seems like it does not want to collect it or its not sending it though to my datafeed. this is what im doing.
foreach ($xml->transactions->transaction as $transaction) {
		$sub_token_url = $transaction->sub_token_url;
		
			}
Comments
  • brettbrett FoxyCart Team
    What version, and if you do a var_dump on the $xml are you seeing what you think you should? That'd be where I'd suggest starting.
  • v6. how would i go about doing the var_dump. im still new to xml
  • lukeluke FoxyCart Team
    Add this to your php:
    print '<pre>';
    var_dump($xml);
    print '</pre>';
    
    Since we use CDATA tags it can be a little tricky looking at the actual values with var_dump though... if you google for "var dump php xml CDATA" you'll see some options there.

    Are you using the test scripts for testing out your XML datafeed stuff? Are there any other errors or warnings that might give you some ideas? Is there a reason you're on 060? The value is no longer supported in 070 at that location since the token needs to be per line item because it is possible to have multiple subscriptions in the same cart with different start dates, end dates and frequencies. 070 has a LOT of subscription improvements and we strongly recommend upgrading to take advantage of them if you're doing subscriptions.

    Hope that helps.
Sign In or Register to comment.