Skip to content

Instantly share code, notes, and snippets.

@oddevan
Created July 1, 2019 02:18
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save oddevan/dee0463760df4110e776c6e0d468e6e3 to your computer and use it in GitHub Desktop.
Save oddevan/dee0463760df4110e776c6e0d468e6e3 to your computer and use it in GitHub Desktop.
<?php
/*
Plugin Name: Embed DeviantART
Description: Allow embeds from deviantART pages
Author: Evan Hildreth
Version: 1.0
*/
function eph_register_deviantart() {
wp_oembed_add_provider( 'https://*.deviantart.com/art/*', 'https://backend.deviantart.com/oembed', false );
wp_oembed_add_provider( 'http://fav.me/*', 'https://backend.deviantart.com/oembed', false );
wp_oembed_add_provider( 'https://sta.sh/*', 'https://backend.deviantart.com/oembed', false );
wp_oembed_add_provider( 'https://*.deviantart.com/*#/d*', 'https://backend.deviantart.com/oembed', false );
}
add_action( 'init', 'eph_register_deviantart' );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment