Created
September 4, 2014 19:46
-
-
Save dampee/b276deb7ddd889be9542 to your computer and use it in GitHub Desktop.
OEmbed for slideshare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// uses Newtonsoft Json | |
var slideshareOembedUrl = "http://www.slideshare.net/api/oembed/2?url=" + urlToRender + "&maxwidth=800&maxheight=400&format=json"; | |
var wc = new WebClient(); | |
var json = wc.DownloadString(slideshareOembedUrl); | |
var jsonObject = JObject.Parse(json); | |
return jsonObject.Property("thumbnail").Value.ToString(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment