adrian Posted June 19, 2013 Share Posted June 19, 2013 Have you tried stripping your template code down to the basic example on the github page? Basic example: $t = $modules->get('MarkupTwitterFeed');echo $t->render(); Link to comment Share on other sites More sharing options...
Sinmok Posted June 19, 2013 Share Posted June 19, 2013 Adrian, the code I am using is exactly as follows: <?php //Twitter stuff $t = $modules->get('MarkupTwitterFeed'); ?> <?=$t->render()?> Link to comment Share on other sites More sharing options...
ryan Posted June 19, 2013 Share Posted June 19, 2013 That may have just saved me a wack of trouble. Didn't realize it was 2.3 compatible only. Thanks Willy. Edit June 18: upgraded PW to 2.3 and twitter feed is up again. Note to self: read compatibility before spending 5 hours troubleshooting. Actually on the original update it said it was compatible with 2.2.9, as I thought it was at first. I realized later that day it wasn't and updated. So it's my mistake, not yours. I've put in all the information required in the module admin page and double checked that the information is correct, but no matter what I try, I keep getting "Error retrieving Twitter status" You might need to enable debug mode. Also check here to make sure that your server is compatible with the requirements/dependencies listed: https://github.com/themattharris/tmhOAuth 1 Link to comment Share on other sites More sharing options...
Sinmok Posted June 19, 2013 Share Posted June 19, 2013 Alrighty, switched on debug mode. I'm now getting: Error retrieving Twitter status: 0 I can verify that Curl is installed PHP5-curl is installed PHP is at least 5.4 hash_hmac is installed According to their site, it might have something to do with the cacert..but I can see it there in the module folder. Odd. Link to comment Share on other sites More sharing options...
ryan Posted June 19, 2013 Share Posted June 19, 2013 The module actually only logs the errors in PW 2.3.1+ (current dev branch), as it's using the new $log API variable. So in 2.3.0. it's not going to be quite as clear. But try adding this line after your $t->render(): foreach(wire('notices') as $n) echo "<p>$n->text</p>"; See if it gives any more detail on the error? I've really tried to avoid throwing exceptions in this module (which would produce more obvious errors) so that some problem at Twitter doesn't interrupt your own site beyond the rendered markup from this module. And since I didn't know all the potential errors that tmhOAuth or Twitter might report, I didn't want to have it echoing any error messages that might potentially contain authentication related stuff. Link to comment Share on other sites More sharing options...
Sinmok Posted June 19, 2013 Share Posted June 19, 2013 Honestly, the switch to Twitter 1.1 has caused me a truck load of headaches across apps. Anyway, put that line of code in and nothing is being echo'd out. I'm going to triple check that I've put the details in correctly in the module page.. Edit: Yup, definitely correct. Link to comment Share on other sites More sharing options...
Sinmok Posted June 19, 2013 Share Posted June 19, 2013 Oh for £$%^ sake, this has been an epic case of PEBKAC. I have never tweeted before..I didn't think the module would throw an error instead of displaying nothing if there were no tweets to display. The easy fix was to make a tweet. Link to comment Share on other sites More sharing options...
ryan Posted June 19, 2013 Share Posted June 19, 2013 It sounds to me like no error is actually being generated by anything. You mentioned that you got this "Error retrieving Twitter status: 0". That indicates that oAuth didn't report any errors, since it's now reporting the status of the JSON decode. A status of 0 means json_decode() reported no errors. Unless you literally don't have any tweets on the timeline you are checking, chances are that we are getting tricked by the cache. Try disabling the cache by setting the # seconds to 0: $t->cacheSeconds = 0; Any change in the errors? -- edit: Ah, no tweets. Glad you found it. 1 Link to comment Share on other sites More sharing options...
Sinmok Posted June 19, 2013 Share Posted June 19, 2013 Can I suggest an appropriate message be displayed if the issue is that there is nothing to display? In its current form, the message indicates that there's something gone wrong. Something like "There are no tweets to show" would work quite nicely. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now