alb/oembed 问题修复 & 功能扩展

解决BUG、新增功能、兼容多环境部署,快速响应你的开发需求

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

alb/oembed

Composer 安装命令:

composer require alb/oembed

包简介

oEmbed consumer library

关键字:

README 文档

README

Build Status

Simple consumer library for oEmbed with discovery support.

Usage

In this example the library automatically discovers the oEmbed enpoint for the http://vimeo.com/31423544 resource, and asks for informations about the resource.

<?php

use Alb\OEmbed;

$response = OEmbed\Simple::request('http://vimeo.com/31423544', array(
    'maxwidth' => 400,
    'maxheight' => 300,
));

echo $response->getTitle();
echo $response->getHtml();

Advanced usage:

<?php

use Alb\OEmbed;

// instanciate a Provider from a known endpoint
$provider = new OEmbed\Provider('http://vimeo.com/api/oembed.json', 'json');

// request information about a resource
$response = $provider->request('http://vimeo.com/31423544');

The library is also capable of discovering the oEmbed enpoint from a resource URL (if the site supports it):

<?php

use Alb\OEmbed;

$discovery = new OEmbed\Discovery;
$provider = $discovery->discover('http://vimeo.com/31423544');

// or, using OEmbed\Simple:

$provider = OEmbed\Simple::getProvider('http://vimeo.com/31423544');

统计信息

  • 总下载量: 101.61k
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 18
  • 点击次数: 11
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 17
  • Watchers: 3
  • Forks: 7
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2011-11-03

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固