Forum
Twitter App
I've successfully installed the Twitter app and tweets are being downloaded successfully and pulled into the backend.
However, when I add the following function to a page it returns nothing and stops any code below it from running:
<?php perch_twitter_get_latest(); ?>
I've tried using the more complicated examples with parameters and get much the same result.
How can I fix this or at least debug it?
Thank you!
Have you simplified this to the point of a php page with just the function and see if works, also, have you viewed the source of the page to see if an error was output before the script died? Sometimes this will be the last lines of the output. Also, a look at your logs may yield answers.
Can you post your diagnostics report please?
You need to add the app to your
config/apps.php
file. Those instructions are on the app's installation page if you're unfamiliar with how to do that.Ah! Neglected to do that. Working now. Thanks for the swift response - much appreciated Drew and Robert!
I've tried setting up a cron job to pull the tweets but I'm having another problem.
I'm running this command:
And getting this error in my server logs:
The version of PHP you're using on the command line is too old. You need PHP 5.4 or greater.
I'm now running the cron command with PHP 7 and I'm getting the message back: "no secret found". I'm definitely using the secret provided as the URL works correctly. Just not the cron :/
Are you providing the secret to the cron job?
Yep like so:
That should be sufficient.
Telling me no secret found. Could be it anything to do with PHP 7? How can I debug this further?
It shouldn't be PHP 7, no. I'm not sure how you'd debug that without being in front of it, I'm afraid.