{"id":2943776,"date":"2012-08-04T19:58:56","date_gmt":"2012-08-04T19:58:56","guid":{"rendered":"https:\/\/wordpress.org\/support\/topic\/embed-pdf-using-do_shortcode\/"},"modified":"2016-08-20T14:15:40","modified_gmt":"2016-08-20T14:15:40","slug":"embed-pdf-using-do_shortcode","status":"closed","type":"topic","link":"https:\/\/wordpress.org\/support\/topic\/embed-pdf-using-do_shortcode\/","title":{"rendered":"Embed PDF using do_shortcode()"},"content":{"rendered":"<p>Hello: I have &#8220;Embed PDF&#8221; version 1.04.<\/p>\n<p>the <code><a href=\"http:\/\/...\">...<\/a><\/code> shortcode works fine on a page. But when I use <code>do_shortcode<\/code> within PHP code on a template page, the plugin doesn&#8217;t bring up the PDF viewer. Here&#8217;s how I&#8217;m using it:<\/p>\n<p><code><br \/>\n&lt;?php<br \/>\n   echo do_shortcode('<a href=\"\">&#039;.&#039;http:\/\/example.com\/example.pdf&#039;.&#039;<\/a>');<br \/>\n?&gt;<br \/>\n<\/code><\/p>\n<p>Thanks!<br \/>\nPaul<\/p>\n<p>https:\/\/wordpress.org\/extend\/plugins\/dirtysuds-embed-pdf\/<\/p>\n","protected":false},"template":"","class_list":["post-2943776","topic","type-topic","status-closed","hentry","topic-tag-embed","topic-tag-pdf","topic-tag-shortcode","topic-tag-viewer"],"jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/wordpress.org\/support\/wp-json\/wp\/v2\/topic\/2943776","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/wordpress.org\/support\/wp-json\/wp\/v2\/topic"}],"about":[{"href":"https:\/\/wordpress.org\/support\/wp-json\/wp\/v2\/types\/topic"}],"version-history":[{"count":0,"href":"https:\/\/wordpress.org\/support\/wp-json\/wp\/v2\/topic\/2943776\/revisions"}],"wp:attachment":[{"href":"https:\/\/wordpress.org\/support\/wp-json\/wp\/v2\/media?parent=2943776"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}