this.fluidbook = fluidbook;
if (this.isEnabled()) {
var $this = this;
- if (this.fluidbook.datas.phonegap != 'android') {
+ if (this.fluidbook.datas.phonegap !== 'android') {
$(document).on('click', '.share', function () {
var f = 'send' + ucfirst($(this).data('service'));
var url = $(this).data("url");
- if (url == undefined || url == null || url == 'undefined') {
+ if (url === undefined || url === null || url === 'undefined') {
url = '';
}
$this[f](url);
}
});
- if (this.fluidbook.datas.phonegap == 'android') {
+ if (this.fluidbook.datas.phonegap === 'android') {
$(document).on('click', '#shareLinks, #shareLinks a', function (e) {
e.stopPropagation();
e.stopImmediatePropagation();
getFluidbookURL: function () {
var l = window.location.toString();
+ if (this.fluidbook.datas.restrictPrintDownload !== "") {
+ l = l.replace('?' + this.fluidbook.datas.restrictPrintDownload, '');
+ l = l.replace(this.fluidbook.datas.restrictPrintDownload, '');
+ }
var e = l.split("#");
return e[0];
},
if (url == '') {
var res = false;
if (this.fluidbook.support.offline || this.fluidbook.datas.phonegap) {
- if (this.fluidbook.datas.offlineLink != '' && this.fluidbook.datas.offlineLink != 'http://') {
+ if (this.fluidbook.datas.offlineLink !== '' && this.fluidbook.datas.offlineLink !== 'http://') {
res = this.fluidbook.datas.offlineLink;
}
} else {
openShare: function (url, p2, callback) {
var view;
- if (url == undefined || url == null || url == 'undefined' || !url) {
+ if (url === undefined || url === null || url === 'undefined' || !url) {
url = '';
}