Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

$payload = json_decode($_POST['payload']); would always be empty #1

Open
n3tfl0w opened this issue Mar 12, 2014 · 1 comment
Open

Comments

@n3tfl0w
Copy link

n3tfl0w commented Mar 12, 2014

I had the above issue where $payload would always be null.

Now, I just know just enough php to get myself into trouble but I was able to resolve it like so:

  $data = $_REQUEST["payload"];           
  $unescaped_data = stripslashes($data);
  $payload = json_decode($unescaped_data);

Obviously I could be opening up all kinds of issues but just wanted to make this visible.

@adamfratino
Copy link

I'm having a similar issue. Draft webhook is returning an empty file simply named ".md".

e: forgot to mention that your solution worked perfect for me, thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants