https://github.com/soderlind/class-wp-23-video
23 Video for WordPress
https://github.com/soderlind/class-wp-23-video
Last synced: 4 months ago
JSON representation
23 Video for WordPress
- Host: GitHub
- URL: https://github.com/soderlind/class-wp-23-video
- Owner: soderlind
- License: gpl-2.0
- Created: 2014-08-05T12:11:29.000Z (over 11 years ago)
- Default Branch: master
- Last Pushed: 2014-08-11T16:06:04.000Z (over 11 years ago)
- Last Synced: 2025-08-16T06:58:30.460Z (6 months ago)
- Language: PHP
- Homepage:
- Size: 145 KB
- Stars: 2
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# 23 Video for WordPress
A simple WordPress library for communicating with your [23 Video site](http://www.23video.com/) using the [23 Video API](http://www.23video.com/api/). I wrote this library since I needed it for my [23 Video extension for WordPress Media Explorer](https://github.com/soderlind/mexp-23).
## Requirements and prerequisites
This library requires WordPress and uses [wp_remote_get](http://codex.wordpress.org/Function_Reference/wp_remote_get) and [wp_remote_post](http://codex.wordpress.org/Function_Reference/wp_remote_post) to access the [23 Video API](http://www.23video.com/api/)
You are required to [manually obtain all the credentials necessary](http://www.23video.com/api/oauth#setting-up-your-application) for the 23 Video site you're communicating with.
## Usage
The library contains a single source code file, `class-wp-23-video.php`, which contains the class `WP_23_Video`. The first step to communicating with your 23 Video site is to set up an instance of this class:
```php
get( '/api/photo/list' , array(
'include_unpublished_p' => 0
, 'video_p' => 1
, 'p' => 1
) );
```
Performing a `POST` request happens in the exact same way, although only URL encoded `POST` requests are supported by this library, which means that file uploads must be implemented manually:
```php
post( '/api/photo/list' , array(
'include_unpublished_p' => 0
, 'video_p' => 1
, 'p' => 1
) );
```
The methods in the examples above, returns an associative array.