plumpss / twitter
SilverStripe Twitter helper module.
Installs: 33
Dependents: 0
Suggesters: 0
Security: 0
Stars: 1
Watchers: 3
Forks: 1
Open Issues: 3
Type:silverstripe-module
Requires
- abraham/twitteroauth: 0.5.*
- silverstripe/cms: ~3.1
- silverstripe/framework: ~3.1
This package is not auto-updated.
Last update: 2024-12-21 19:15:50 UTC
README
#SilverStripe Twitter Helper
##Installation
composer require plumpss/twitter
##Usage
Add YAML config for your keys, tokens and secrets:
PlumpTwitterFeed:
twitter_consumer_key: ''
twitter_consumer_secret: ''
twitter_oauth_token: ''
twitter_oauth_token_secret: ''
Then obtain Tweets for the user you require:
PlumpTwitterFeed::get_tweets('plumpdigital', 10, TRUE);
The get_tweets
method returns an ArrayList
of ArrayData
so can be output in templates using:
<% loop Tweets %>
$Html
$Date.Nice
<% end_loop %>