Title: get_token function problem
Last modified: January 8, 2021

---

# get_token function problem

 *  [marcusr44](https://wordpress.org/support/users/marcusr44/)
 * (@marcusr44)
 * [5 years, 4 months ago](https://wordpress.org/support/topic/get_token-function-problem/)
 * Hi, I’ve been stuggling to your module working on a 2nd site (1st site works 
   well) and after several weeks of support from Microsoft they have told me:
 * Seems like an issue with the customer’s php code get_token function, see two 
   example for similar stack overflow questions, maybe get_token should be a static
   function or the request to get the token sets the request headers after sending
   the request
    [https://stackoverflow.com/questions/49784775/how-do-i-resolve-deprecated-non-static-method-sessionget-should-not-be-call](https://stackoverflow.com/questions/49784775/how-do-i-resolve-deprecated-non-static-method-sessionget-should-not-be-call)
   [https://stackoverflow.com/questions/21138800/cannot-modify-header-information-headers-already-sent-message-in-my-browser](https://stackoverflow.com/questions/21138800/cannot-modify-header-information-headers-already-sent-message-in-my-browser)
 * does your code need to be changed?
 * thanks
    Marcus
 * The page I need help with: _[[log in](https://login.wordpress.org/?redirect_to=https%3A%2F%2Fwordpress.org%2Fsupport%2Ftopic%2Fget_token-function-problem%2F%3Foutput_format%3Dmd&locale=en_US)
   to see the link]_

The topic ‘get_token function problem’ is closed to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/embed-power-bi_b2d8bc.svg)
 * [Power BI Embedded for WordPress](https://wordpress.org/plugins/embed-power-bi/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/embed-power-bi/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/embed-power-bi/)
 * [Active Topics](https://wordpress.org/support/plugin/embed-power-bi/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/embed-power-bi/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/embed-power-bi/reviews/)

## Tags

 * [authentication](https://wordpress.org/support/topic-tag/authentication/)
 * [php](https://wordpress.org/support/topic-tag/php/)

 * 0 replies
 * 1 participant
 * Last reply from: [marcusr44](https://wordpress.org/support/users/marcusr44/)
 * Last activity: [5 years, 4 months ago](https://wordpress.org/support/topic/get_token-function-problem/)
 * Status: not resolved