plumpss/twitter

SilverStripe Twitter helper module.

Installs: 30

Dependents: 0

Suggesters: 0

Security: 0

Stars: 1

Watchers: 3

Forks: 1

Open Issues: 3

Type:silverstripe-module

0.2.2 2015-03-16 14:46 UTC

This package is not auto-updated.

Last update: 2022-06-25 06:23:21 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 %>