Version Description
Obtains PDF over same transport (https/http) as host page, regardless of that specified in the shortcode url parameter. This avoids conflicts and failure to display PDF if the two don't match.
Download this release
Release Info
Developer | danlester |
Plugin | PDF Embedder |
Version | 2.1.4 |
Comparing to | |
See all releases |
Code changes from version 2.1 to 2.1.4
- core/core_pdf_embedder.php +5 -1
- css/pdfemb-embed-pdf.css +1 -7
- js/all-pdfemb-basic.min.js +10 -10
- js/pdfemb-embed-pdf.js +4 -2
- pdf_embedder.php +2 -2
- readme.txt +5 -1
core/core_pdf_embedder.php
CHANGED
@@ -63,7 +63,7 @@ class core_pdf_embedder {
|
|
63 |
}
|
64 |
|
65 |
protected function modify_pdfurl($url) {
|
66 |
-
return $url;
|
67 |
}
|
68 |
|
69 |
/* public function pdfemb_wp_get_attachment_link( $link, $id, $size, $permalink, $icon, $text ) {
|
@@ -202,6 +202,8 @@ class core_pdf_embedder {
|
|
202 |
$this->pdfemb_securesection_text();
|
203 |
echo '</div>';
|
204 |
|
|
|
|
|
205 |
settings_fields($this->get_options_pagename());
|
206 |
|
207 |
?>
|
@@ -221,6 +223,8 @@ class core_pdf_embedder {
|
|
221 |
protected function draw_more_tabs() {
|
222 |
}
|
223 |
|
|
|
|
|
224 |
|
225 |
// Override elsewhere
|
226 |
protected function pdfemb_mainsection_text() {
|
63 |
}
|
64 |
|
65 |
protected function modify_pdfurl($url) {
|
66 |
+
return set_url_scheme($url);
|
67 |
}
|
68 |
|
69 |
/* public function pdfemb_wp_get_attachment_link( $link, $id, $size, $permalink, $icon, $text ) {
|
202 |
$this->pdfemb_securesection_text();
|
203 |
echo '</div>';
|
204 |
|
205 |
+
$this->draw_extra_sections();
|
206 |
+
|
207 |
settings_fields($this->get_options_pagename());
|
208 |
|
209 |
?>
|
223 |
protected function draw_more_tabs() {
|
224 |
}
|
225 |
|
226 |
+
protected function draw_extra_sections() {
|
227 |
+
}
|
228 |
|
229 |
// Override elsewhere
|
230 |
protected function pdfemb_mainsection_text() {
|
css/pdfemb-embed-pdf.css
CHANGED
@@ -75,12 +75,6 @@ div.pdfemb-wantmobile-fsarea {
|
|
75 |
cursor: grab !important;
|
76 |
}
|
77 |
|
78 |
-
.grab-to-pan-grab {
|
79 |
-
cursor: move !important;
|
80 |
-
cursor: -webkit-grab !important;
|
81 |
-
cursor: -moz-grab !important;
|
82 |
-
cursor: grab !important;
|
83 |
-
}
|
84 |
.grab-to-pan-grab *:not(input):not(textarea):not(button):not(select):not(:link) {
|
85 |
cursor: inherit !important;
|
86 |
}
|
@@ -196,7 +190,7 @@ div.pdfemb-errormsg {
|
|
196 |
left: 0;
|
197 |
right: 0;
|
198 |
bottom: 0;
|
199 |
-
z-index:
|
200 |
overflow-y: auto;
|
201 |
overflow-x: hidden;
|
202 |
display: none;
|
75 |
cursor: grab !important;
|
76 |
}
|
77 |
|
|
|
|
|
|
|
|
|
|
|
|
|
78 |
.grab-to-pan-grab *:not(input):not(textarea):not(button):not(select):not(:link) {
|
79 |
cursor: inherit !important;
|
80 |
}
|
190 |
left: 0;
|
191 |
right: 0;
|
192 |
bottom: 0;
|
193 |
+
z-index: 4000;
|
194 |
overflow-y: auto;
|
195 |
overflow-x: hidden;
|
196 |
display: none;
|
js/all-pdfemb-basic.min.js
CHANGED
@@ -1,14 +1,14 @@
|
|
1 |
function pdfembGetPDF(c,a){a(c,!1)}function pdfembWantMobile(c,a,g,d){return!1}function pdfembMakeMobile(c,a,g){}function pdfembAddMoreToolbar(c,a,g){};jQuery(document).ready(function(c){c.fn.pdfEmbedder=function(){this.each(function(a,g){var d=c(g);d.append(c("<div></div>",{"class":"pdfemb-loadingmsg"}).append(document.createTextNode("Loading...")));var h=function(a,b){d.empty().append(c("<div></div>",{"class":"pdfemb-inner-div"}).append(c("<canvas></canvas>",{"class":"pdfemb-the-canvas"})));d.data("pdfDoc",a);var e=d.data("toolbar");"bottom"!=e&&c.fn.pdfEmbedder.addToolbar(d,!0,"on"==d.data("toolbar-fixed"),b);"top"!=e&&c.fn.pdfEmbedder.addToolbar(d,
|
2 |
-
!1,"on"==d.data("toolbar-fixed"),b);d.data("pageCount",a.numPages);d.data("pageNum")||d.data("pageNum",1);d.data("showIsSecure",b);d.data("pageNumPending",null);d.data("zoom",100);c.fn.pdfEmbedder.renderPage(d,d.data("pageNum"));d.find("span.pdfemb-page-count").text(a.numPages);e=new pdfembGrabToPan({element:d.find("div.pdfemb-inner-div")[0]});d.data("grabtopan",e);c(window).resize(function(){c.fn.pdfEmbedder.queueRenderPage(d,d.data("pageNum"))})},e=function(a,b){PDFJS.getDocument(a).then(function(a){h(a,
|
3 |
-
b)},function(a){d.empty().append(c("<div></div>",{"class":"pdfemb-errormsg"}).append(document.createTextNode(a.message)))})};if(d.data("pdfDoc"))h(d.data("pdfDoc"),d.data("showIsSecure"));else{var b=d.attr("data-pdf-url");pdfembGetPDF(b,e)}});return this};c.fn.pdfEmbedder.renderPage=function(a,g){a.data("pageRendering",!0);a.data("pdfDoc").getPage(g).then(function(d){var h=a.find(".pdfemb-the-canvas"),e,b=d.getViewport(1),m=b.width,
|
4 |
-
else{e=a.parent().width();var b=m,l=f;if("max"==a.data("width"))b=e;else if("auto"==a.data("width"))b=m;else if(b=parseInt(a.data("width"),10),isNaN(b)||0>=b)b=e;0>=b&&(b=m);b>e&&0<e&&(b=e);e=b/m;var l=f*e,n=a.find("div.pdfemb-toolbar-fixed"),r=(m=pdfembWantMobile(c,a,b,k))?0:n.length,k=parseInt(a.data("height"),10);if(isNaN(k)||0>=k||k>l)k="max"==a.data("height")?a.parent().height()-r*n.height():
|
5 |
-
q<b&&(t=(b-q)/2),p<k&&(u=(k-p)/2));e=d.getViewport(e*f/100);b!=a.width()&&a.width(b);a.height()!=k&&a.height(k+r*n.height());f=a.find("div.pdfemb-inner-div");f.width(b);f.height(k);n=n.filter(".pdfemb-toolbar-top");0<r&&f.css("top",n.height());h[0].width=q;h[0].height=p;h.css("width",q);h.css("height",p);h.css("left",t).css("top",u);(q>b||p>l||p>k)&&!m?(a.data("grabtopan").activate(),k=a.data("fromZoom"),
|
6 |
-
2),f.scrollTop(p*r/k-l/2))):(a.data("grabtopan").deactivate(),a.find("div.pdfemb-inner-div").scrollLeft(0).scrollTop(0));a.data("fromZoom",0).data("toZoom",0);pdfembMakeMobile(c,m,a);h={canvasContext:h[0].getContext("2d"),viewport:e};d.render(h).promise.then(function(){a.data("pageNum",g);a.data("pageRendering",!1);a.find("span.pdfemb-page-num").text(g);g<a.data("pageCount")?a.find(".pdfemb-next").removeAttr("disabled").removeClass("pdfemb-btndisabled"):
|
7 |
-
1<g?a.find(".pdfemb-prev").removeAttr("disabled").removeClass("pdfemb-btndisabled"):a.find(".pdfemb-prev").attr("disabled","disabled").addClass("pdfemb-btndisabled");null!==a.data("pageNumPending")&&(c.fn.pdfEmbedder.renderPage(a,a.data("pageNumPending")),a.data("pageNumPending",null))})}})};c.fn.pdfEmbedder.queueRenderPage=function(a,g){a.data("pageRendering")?a.data("pageNumPending",g):c.fn.pdfEmbedder.renderPage(a,
|
8 |
-
c(document.body).append(a)};c.fn.pdfEmbedder.addToolbar=function(a,g,d,h){var e=c("<div></div>",{"class":"pdfemb-toolbar pdfemb-toolbar"+(d?"-fixed":"-hover")+" "+(g?" pdfemb-toolbar-top":"pdfemb-toolbar-bottom")}),b=c('<button class="pdfemb-prev">Prev</button>');e.append(b);var m=c('<button class="pdfemb-next">Next</button>');e.append(m);e.append(c('<div>Page <span class="pdfemb-page-num">0</span> / <span class="pdfemb-page-count"></span></div>'));
|
9 |
-
e.append(f);var l=c('<button class="pdfemb-zoomin">+</button>');e.append(l);e.append(c('<div>Zoom <span class="pdfemb-zoom">100%</span></div>'));h&&e.append(c("<div>Secure</div>"));g?a.prepend(e):a.append(e);b.on("click",function(b){1>=a.data("pageNum")||(a.data("pageNum",a.data("pageNum")-1),c.fn.pdfEmbedder.queueRenderPage(a,a.data("pageNum")))});m.on("click",function(b){a.data("pageNum")>=a.data("pdfDoc").numPages||(a.data("pageNum",a.data("pageNum")+
|
10 |
-
var n=function(b){var d=a.data("zoom");b=d+b;a.data("zoom",b);a.find("span.pdfemb-zoom").text(b+"%");c.fn.pdfEmbedder.queueRenderPage(a,a.data("pageNum"));a.data("fromZoom",d).data("toZoom",b)};l.on("click",function(b){500<=a.data("zoom")||n(10)});f.on("click",function(b){20>=a.data("zoom")||n(-10)});pdfembAddMoreToolbar(c,e,a);d||(a.on("mouseenter",function(b){b=a.find("div.pdfemb-toolbar-hover");!0!==b.data("no-hover")&&b.show()}),a.on("mouseleave",
|
11 |
-
PDFJS.workerSrc=pdfemb_trans.worker_src;PDFJS.cMapUrl=pdfemb_trans.cmap_url;PDFJS.cMapPacked=!0;c(".pdfemb-viewer").pdfEmbedder()});var pdfembGrabToPan=function(){function c(a){this.element=a.element;this.document=a.element.ownerDocument;"function"===typeof a.ignoreTarget&&(this.ignoreTarget=a.ignoreTarget);this.onActiveChanged=a.onActiveChanged;this.activate=this.activate.bind(this);this.deactivate=this.deactivate.bind(this);this.toggle=this.toggle.bind(this);this._onmousedown=this._onmousedown.bind(this);this._onmousemove=this._onmousemove.bind(this);this._onmousewheel=this._onmousewheel.bind(this);this._endPan=this._endPan.bind(this);
|
12 |
(this.overlay=document.createElement("div")).className="grab-to-pan-grabbing"}c.prototype={CSS_CLASS_GRAB:"grab-to-pan-grab",activate:function(){if(!this.active&&(this.active=!0,this.element.addEventListener("mousedown",this._onmousedown,!0),this.element.addEventListener("DOMMouseScroll",this._onmousewheel),this.element.addEventListener("mousewheel",this._onmousewheel),this.element.classList.add(this.CSS_CLASS_GRAB),this.onActiveChanged))this.onActiveChanged(!0)},deactivate:function(){if(this.active&&
|
13 |
(this.active=!1,this.element.removeEventListener("mousedown",this._onmousedown,!0),this._endPan(),this.element.classList.remove(this.CSS_CLASS_GRAB),this.onActiveChanged))this.onActiveChanged(!1)},toggle:function(){this.active?this.deactivate():this.activate()},ignoreTarget:function(b){return b[a]("a[href], a[href] *, input, textarea, button, button *, select, option")},_onmousedown:function(a){if(0===a.button&&!this.ignoreTarget(a.target)){this.scrollLeftStart=this.element.scrollLeft;this.scrollTopStart=
|
14 |
this.element.scrollTop;this.clientXStart=a.clientX;this.clientYStart=a.clientY;this.document.addEventListener("mousemove",this._onmousemove,!0);this.document.addEventListener("mouseup",this._endPan,!0);this.element.addEventListener("scroll",this._endPan,!0);a.preventDefault();a.stopPropagation();this.document.documentElement.classList.add(this.CSS_CLASS_GRABBING);var c=document.activeElement;c&&!c.contains(a.target)&&c.blur()}},_onmousemove:function(a){this.element.removeEventListener("scroll",this._endPan,
|
1 |
function pdfembGetPDF(c,a){a(c,!1)}function pdfembWantMobile(c,a,g,d){return!1}function pdfembMakeMobile(c,a,g){}function pdfembAddMoreToolbar(c,a,g){};jQuery(document).ready(function(c){c.fn.pdfEmbedder=function(){this.each(function(a,g){var d=c(g);d.append(c("<div></div>",{"class":"pdfemb-loadingmsg"}).append(document.createTextNode("Loading...")));var h=function(a,b){d.empty().append(c("<div></div>",{"class":"pdfemb-inner-div"}).append(c("<canvas></canvas>",{"class":"pdfemb-the-canvas"})));d.data("pdfDoc",a);var e=d.data("toolbar");"bottom"!=e&&c.fn.pdfEmbedder.addToolbar(d,!0,"on"==d.data("toolbar-fixed"),b);"top"!=e&&c.fn.pdfEmbedder.addToolbar(d,
|
2 |
+
!1,"on"==d.data("toolbar-fixed"),b);d.data("pageCount",a.numPages);d.data("pageNum")||d.data("pageNum",1);d.data("showIsSecure",b);d.data("pageNumPending",null);d.data("zoom",100);c.fn.pdfEmbedder.renderPage(d,d.data("pageNum"));d.find("span.pdfemb-page-count").text(a.numPages);e=new pdfembGrabToPan({element:d.find("div.pdfemb-inner-div")[0]});d.data("grabtopan",e);c(window).resize(function(){setTimeout(function(){c.fn.pdfEmbedder.queueRenderPage(d,d.data("pageNum"))},100)})},e=function(a,b){PDFJS.getDocument(a).then(function(a){h(a,
|
3 |
+
b)},function(a){d.empty().append(c("<div></div>",{"class":"pdfemb-errormsg"}).append(document.createTextNode(a.message)))})};if(d.data("pdfDoc"))h(d.data("pdfDoc"),d.data("showIsSecure"));else{var b=d.attr("data-pdf-url");pdfembGetPDF(b,e)}});return this};c.fn.pdfEmbedder.renderPage=function(a,g){a.data("pageRendering",!0);a.data("pdfDoc").getPage(g).then(function(d){var h=c("<canvas></canvas>",{"class":"pdfemb-the-canvas"}).replaceAll(a.find(".pdfemb-the-canvas")),e,b=d.getViewport(1),m=b.width,
|
4 |
+
f=b.height;if(0>=m||0>=f)a.empty().append(document.createTextNode("PDF page width or height are invalid"));else{e=a.parent().width();var b=m,l=f;if("max"==a.data("width"))b=e;else if("auto"==a.data("width"))b=m;else if(b=parseInt(a.data("width"),10),isNaN(b)||0>=b)b=e;0>=b&&(b=m);b>e&&0<e&&(b=e);e=b/m;var l=f*e,n=a.find("div.pdfemb-toolbar-fixed"),r=(m=pdfembWantMobile(c,a,b,k))?0:n.length,k=parseInt(a.data("height"),10);if(isNaN(k)||0>=k||k>l)k="max"==a.data("height")?a.parent().height()-r*n.height():
|
5 |
+
l;var b=Math.floor(b),l=Math.floor(l),f=100,q=b,p=l,t=0,u=0;m||(f=a.data("zoom"),q=b*f/100,p=l*f/100,q<b&&(t=(b-q)/2),p<k&&(u=(k-p)/2));e=d.getViewport(e*f/100);b!=a.width()&&a.width(b);a.height()!=k&&a.height(k+r*n.height());f=a.find("div.pdfemb-inner-div");f.width(b);f.height(k);n=n.filter(".pdfemb-toolbar-top");0<r&&f.css("top",n.height());h[0].width=q;h[0].height=p;h.css("width",q);h.css("height",p);h.css("left",t).css("top",u);(q>b||p>l||p>k)&&!m?(a.data("grabtopan").activate(),k=a.data("fromZoom"),
|
6 |
+
r=a.data("toZoom"),0<k&&0<r&&(q=f.scrollLeft(),p=f.scrollTop()+l/2,f.scrollLeft((q+b/2)*r/k-b/2),f.scrollTop(p*r/k-l/2))):(a.data("grabtopan").deactivate(),a.find("div.pdfemb-inner-div").scrollLeft(0).scrollTop(0));a.data("fromZoom",0).data("toZoom",0);pdfembMakeMobile(c,m,a);h={canvasContext:h[0].getContext("2d"),viewport:e};d.render(h).promise.then(function(){a.data("pageNum",g);a.data("pageRendering",!1);a.find("span.pdfemb-page-num").text(g);g<a.data("pageCount")?a.find(".pdfemb-next").removeAttr("disabled").removeClass("pdfemb-btndisabled"):
|
7 |
+
a.find(".pdfemb-next").attr("disabled","disabled").addClass("pdfemb-btndisabled");1<g?a.find(".pdfemb-prev").removeAttr("disabled").removeClass("pdfemb-btndisabled"):a.find(".pdfemb-prev").attr("disabled","disabled").addClass("pdfemb-btndisabled");null!==a.data("pageNumPending")&&(c.fn.pdfEmbedder.renderPage(a,a.data("pageNumPending")),a.data("pageNumPending",null))})}})};c.fn.pdfEmbedder.queueRenderPage=function(a,g){a.data("pageRendering")?a.data("pageNumPending",g):c.fn.pdfEmbedder.renderPage(a,
|
8 |
+
g)};c.fn.pdfEmbedder.goFullScreen=function(a){a=c('<div class="pdfemb-fs-window"></div>');c(document.body).append(a)};c.fn.pdfEmbedder.addToolbar=function(a,g,d,h){var e=c("<div></div>",{"class":"pdfemb-toolbar pdfemb-toolbar"+(d?"-fixed":"-hover")+" "+(g?" pdfemb-toolbar-top":"pdfemb-toolbar-bottom")}),b=c('<button class="pdfemb-prev">Prev</button>');e.append(b);var m=c('<button class="pdfemb-next">Next</button>');e.append(m);e.append(c('<div>Page <span class="pdfemb-page-num">0</span> / <span class="pdfemb-page-count"></span></div>'));
|
9 |
+
var f=c('<button class="pdfemb-zoomout">-</button>');e.append(f);var l=c('<button class="pdfemb-zoomin">+</button>');e.append(l);e.append(c('<div>Zoom <span class="pdfemb-zoom">100%</span></div>'));h&&e.append(c("<div>Secure</div>"));g?a.prepend(e):a.append(e);b.on("click",function(b){1>=a.data("pageNum")||(a.data("pageNum",a.data("pageNum")-1),c.fn.pdfEmbedder.queueRenderPage(a,a.data("pageNum")))});m.on("click",function(b){a.data("pageNum")>=a.data("pdfDoc").numPages||(a.data("pageNum",a.data("pageNum")+
|
10 |
+
1),c.fn.pdfEmbedder.queueRenderPage(a,a.data("pageNum")))});var n=function(b){var d=a.data("zoom");b=d+b;a.data("zoom",b);a.find("span.pdfemb-zoom").text(b+"%");c.fn.pdfEmbedder.queueRenderPage(a,a.data("pageNum"));a.data("fromZoom",d).data("toZoom",b)};l.on("click",function(b){500<=a.data("zoom")||n(10)});f.on("click",function(b){20>=a.data("zoom")||n(-10)});pdfembAddMoreToolbar(c,e,a);d||(a.on("mouseenter",function(b){b=a.find("div.pdfemb-toolbar-hover");!0!==b.data("no-hover")&&b.show()}),a.on("mouseleave",
|
11 |
+
function(b){a.find("div.pdfemb-toolbar-hover").hide()}))};PDFJS.workerSrc=pdfemb_trans.worker_src;PDFJS.cMapUrl=pdfemb_trans.cmap_url;PDFJS.cMapPacked=!0;c(".pdfemb-viewer").pdfEmbedder()});var pdfembGrabToPan=function(){function c(a){this.element=a.element;this.document=a.element.ownerDocument;"function"===typeof a.ignoreTarget&&(this.ignoreTarget=a.ignoreTarget);this.onActiveChanged=a.onActiveChanged;this.activate=this.activate.bind(this);this.deactivate=this.deactivate.bind(this);this.toggle=this.toggle.bind(this);this._onmousedown=this._onmousedown.bind(this);this._onmousemove=this._onmousemove.bind(this);this._onmousewheel=this._onmousewheel.bind(this);this._endPan=this._endPan.bind(this);
|
12 |
(this.overlay=document.createElement("div")).className="grab-to-pan-grabbing"}c.prototype={CSS_CLASS_GRAB:"grab-to-pan-grab",activate:function(){if(!this.active&&(this.active=!0,this.element.addEventListener("mousedown",this._onmousedown,!0),this.element.addEventListener("DOMMouseScroll",this._onmousewheel),this.element.addEventListener("mousewheel",this._onmousewheel),this.element.classList.add(this.CSS_CLASS_GRAB),this.onActiveChanged))this.onActiveChanged(!0)},deactivate:function(){if(this.active&&
|
13 |
(this.active=!1,this.element.removeEventListener("mousedown",this._onmousedown,!0),this._endPan(),this.element.classList.remove(this.CSS_CLASS_GRAB),this.onActiveChanged))this.onActiveChanged(!1)},toggle:function(){this.active?this.deactivate():this.activate()},ignoreTarget:function(b){return b[a]("a[href], a[href] *, input, textarea, button, button *, select, option")},_onmousedown:function(a){if(0===a.button&&!this.ignoreTarget(a.target)){this.scrollLeftStart=this.element.scrollLeft;this.scrollTopStart=
|
14 |
this.element.scrollTop;this.clientXStart=a.clientX;this.clientYStart=a.clientY;this.document.addEventListener("mousemove",this._onmousemove,!0);this.document.addEventListener("mouseup",this._endPan,!0);this.element.addEventListener("scroll",this._endPan,!0);a.preventDefault();a.stopPropagation();this.document.documentElement.classList.add(this.CSS_CLASS_GRABBING);var c=document.activeElement;c&&!c.contains(a.target)&&c.blur()}},_onmousemove:function(a){this.element.removeEventListener("scroll",this._endPan,
|
js/pdfemb-embed-pdf.js
CHANGED
@@ -48,7 +48,9 @@ jQuery(document).ready(function ($) {
|
|
48 |
divContainer.data('grabtopan', grabtopan);
|
49 |
|
50 |
$(window).resize(function() {
|
51 |
-
|
|
|
|
|
52 |
});
|
53 |
};
|
54 |
|
@@ -91,7 +93,7 @@ jQuery(document).ready(function ($) {
|
|
91 |
|
92 |
pdfDoc.getPage(pageNum).then(function(page) {
|
93 |
|
94 |
-
var canvas = divContainer.find('.pdfemb-the-canvas');
|
95 |
var scale = 1.0;
|
96 |
|
97 |
var vp = page.getViewport(scale);
|
48 |
divContainer.data('grabtopan', grabtopan);
|
49 |
|
50 |
$(window).resize(function() {
|
51 |
+
setTimeout(function() {
|
52 |
+
$.fn.pdfEmbedder.queueRenderPage(divContainer, divContainer.data('pageNum'));
|
53 |
+
}, 100);
|
54 |
});
|
55 |
};
|
56 |
|
93 |
|
94 |
pdfDoc.getPage(pageNum).then(function(page) {
|
95 |
|
96 |
+
var canvas = $('<canvas></canvas>', {'class': 'pdfemb-the-canvas'}).replaceAll(divContainer.find('.pdfemb-the-canvas'));
|
97 |
var scale = 1.0;
|
98 |
|
99 |
var vp = page.getViewport(scale);
|
pdf_embedder.php
CHANGED
@@ -4,7 +4,7 @@
|
|
4 |
* Plugin Name: PDF Embedder
|
5 |
* Plugin URI: http://wp-pdf.com/
|
6 |
* Description: Embed PDFs straight into your posts and pages, with flexible width and height. No third-party services required.
|
7 |
-
* Version: 2.1
|
8 |
* Author: Dan Lester
|
9 |
* Author URI: http://wp-pdf.com/
|
10 |
* License: GPL3
|
@@ -14,7 +14,7 @@ require_once( plugin_dir_path(__FILE__).'/core/core_pdf_embedder.php' );
|
|
14 |
|
15 |
class pdfemb_basic_pdf_embedder extends core_pdf_embedder {
|
16 |
|
17 |
-
protected $PLUGIN_VERSION = '2.1';
|
18 |
|
19 |
protected function useminified() {
|
20 |
/* using-minified */ return true;
|
4 |
* Plugin Name: PDF Embedder
|
5 |
* Plugin URI: http://wp-pdf.com/
|
6 |
* Description: Embed PDFs straight into your posts and pages, with flexible width and height. No third-party services required.
|
7 |
+
* Version: 2.1.4
|
8 |
* Author: Dan Lester
|
9 |
* Author URI: http://wp-pdf.com/
|
10 |
* License: GPL3
|
14 |
|
15 |
class pdfemb_basic_pdf_embedder extends core_pdf_embedder {
|
16 |
|
17 |
+
protected $PLUGIN_VERSION = '2.1.4';
|
18 |
|
19 |
protected function useminified() {
|
20 |
/* using-minified */ return true;
|
readme.txt
CHANGED
@@ -3,7 +3,7 @@ Contributors: danlester
|
|
3 |
Tags: doc, docx, pdf, office, powerpoint, google, document, embed, intranet
|
4 |
Requires at least: 3.3
|
5 |
Tested up to: 4.2
|
6 |
-
Stable tag: 2.1
|
7 |
License: GPLv3
|
8 |
License URI: http://www.gnu.org/licenses/gpl-3.0.html
|
9 |
|
@@ -119,6 +119,10 @@ the Plugins section of your Wordpress admin
|
|
119 |
|
120 |
== Changelog ==
|
121 |
|
|
|
|
|
|
|
|
|
122 |
= 2.1 =
|
123 |
|
124 |
Settings -> PDF Embedder page so you can now set site-wide defaults for width, height, and toolbar location/appearance.
|
3 |
Tags: doc, docx, pdf, office, powerpoint, google, document, embed, intranet
|
4 |
Requires at least: 3.3
|
5 |
Tested up to: 4.2
|
6 |
+
Stable tag: 2.1.4
|
7 |
License: GPLv3
|
8 |
License URI: http://www.gnu.org/licenses/gpl-3.0.html
|
9 |
|
119 |
|
120 |
== Changelog ==
|
121 |
|
122 |
+
= 2.1.4 =
|
123 |
+
|
124 |
+
Obtains PDF over same transport (https/http) as host page, regardless of that specified in the shortcode url parameter. This avoids conflicts and failure to display PDF if the two don't match.
|
125 |
+
|
126 |
= 2.1 =
|
127 |
|
128 |
Settings -> PDF Embedder page so you can now set site-wide defaults for width, height, and toolbar location/appearance.
|