From: vincent@cubedesigners.com Date: Tue, 13 Mar 2018 11:20:11 +0000 (+0000) Subject: done #1977 #1978 @2 X-Git-Url: http://git.cubedesigners.com/?a=commitdiff_plain;h=5587d11612600e76f4d397fcc58a2fc0939d49f1;p=cubeextranet.git done #1977 #1978 @2 --- diff --git a/inc/ws/Util/html5/master/class.ws.html5.compiler.php b/inc/ws/Util/html5/master/class.ws.html5.compiler.php index 9047081da..faa1dd462 100644 --- a/inc/ws/Util/html5/master/class.ws.html5.compiler.php +++ b/inc/ws/Util/html5/master/class.ws.html5.compiler.php @@ -536,6 +536,23 @@ class wsHTML5Compiler { $script .= $iscript; $description = ''; + $socialTitle = $this->book->parametres->facebook_title ? $this->book->parametres->facebook_title : $titre; + $socialDescription = $this->book->parametres->seoDescription ? $this->book->parametres->seoDescription : $this->book->parametres->seoDescription; + $socialImage = 'https://workshop.fluidbook.com/services/facebook_thumbnail?id=' . $this->book_id . '&j=' . time(); + $dim = getimagesize($socialImage); + $socialImageWidth = $dim[0]; + $socialImageHeight = $dim[1]; + + $twittercard = ' + + + + '; + $opengraph = ' + + + + '; $favicon = ''; $hasIos = false; @@ -596,7 +613,7 @@ class wsHTML5Compiler { if ($this->phonegap) { $csp = "securityPolicyWhitelist)) . "; img-src * data:\">"; } - $vars = array('titre', 'credits', 'statsfooter', 'ga', 'style', 'script', 'pagesContents', 'description', 'print', 'hiddenContents', 'splash', 'cache', 'bgcolor', 'message', 'favicon', 'svg', 'beginbody', 'csp'); + $vars = array('titre', 'credits', 'statsfooter', 'ga', 'style', 'script', 'pagesContents', 'description', 'print', 'hiddenContents', 'splash', 'cache', 'bgcolor', 'message', 'favicon', 'svg', 'beginbody', 'csp', 'opengraph', 'twittercard'); foreach ($vars as $v) { $html = str_replace('', $$v, $html); }