Skip to content
master
Switch branches/tags
Code
This branch is 1 commit ahead, 13 commits behind J7mbo/twitter-api-php:master.
Contribute

Latest commit

 

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
 
 
 
 
 
 
 
 

twitter-api-php

Even more simple PHP Wrapper for sending tweets to twitter via API v1.1 calls

The aim of this class is simple. You need to:

You really can't get much simpler than that.

Installation

Just include TwitterAPI.php in your application.

How To Use

Include the class file

require_once('TwitterAPI.php');

Create a new object

$twitter = new TwitterAPI(
    "YOUR_OAUTH_ACCESS_TOKEN",
    "YOUR_OAUTH_ACCESS_TOKEN_SECRET",
    "YOUR_CONSUMER_KEY",
    "YOUR_CONSUMER_SECRET"
);

Send a tweet

$twitter->tweet("THIS IS YOUR TWEET");

Send a tweet with an image

$twitter->tweetImage('THIS IS A TWEET WITH AN IMAGE', 'path/to/image.jpg');

That is it! Really simple, works great with the 1.1 API.
Thanks to @lackovic10 and @rivers on SO and James Mallison for their awesome work!

About

Simple PHP Wrapper for Twitter API v1.1 calls

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages