From a406bd19e5186c32f7b660bbf5bc79577ffe7790 Mon Sep 17 00:00:00 2001 From: "vincent@cubedesigners.com" Date: Fri, 28 Jan 2011 13:10:25 +0000 Subject: [PATCH] --- inc/ws/Controlleur/_common.php | 8 +++++--- inc/ws/Controlleur/class.ws.secure.swf.php | 0 inc/ws/Controlleur/class.ws.url.php | 3 +++ inc/ws/Metier/class.ws.icone.php | 12 ++++++------ 4 files changed, 14 insertions(+), 9 deletions(-) create mode 100644 inc/ws/Controlleur/class.ws.secure.swf.php diff --git a/inc/ws/Controlleur/_common.php b/inc/ws/Controlleur/_common.php index b46e6c4da..898014015 100644 --- a/inc/ws/Controlleur/_common.php +++ b/inc/ws/Controlleur/_common.php @@ -5,7 +5,9 @@ $__autoload['wsAjax'] = dirname(__FILE__) . '/class.ws.ajax.php'; $__autoload['wsUrl'] = dirname(__FILE__) . '/class.ws.url.php'; $__autoload['wsDroits'] = dirname(__FILE__) . '/class.ws.droits.php'; $__autoload['wsConversionSession'] = dirname(__FILE__) . '/class.ws.conversion.session.php'; -$__autoload['wsStats']=dirname(__FILE__).'/class.ws.stats.php'; -$__autoload['wsServices']=dirname(__FILE__).'/class.ws.services.php'; -$__autoload['wsUsersTree']=dirname(__FILE__).'/class.ws.users.tree.php'; +$__autoload['wsStats'] = dirname(__FILE__) . '/class.ws.stats.php'; +$__autoload['wsServices'] = dirname(__FILE__) . '/class.ws.services.php'; +$__autoload['wsUsersTree'] = dirname(__FILE__) . '/class.ws.users.tree.php'; +$__autoload['wsSecureSWF'] = dirname(__FILE__) . '/class.ws.secure.swf.php'; + ?> \ No newline at end of file diff --git a/inc/ws/Controlleur/class.ws.secure.swf.php b/inc/ws/Controlleur/class.ws.secure.swf.php new file mode 100644 index 000000000..e69de29bb diff --git a/inc/ws/Controlleur/class.ws.url.php b/inc/ws/Controlleur/class.ws.url.php index 770ffe8d2..6805a0fcc 100644 --- a/inc/ws/Controlleur/class.ws.url.php +++ b/inc/ws/Controlleur/class.ws.url.php @@ -280,6 +280,7 @@ html{height:100%}' . "\n"; $book_id = $e[0]; self::checkDocumentVersionOfBook($book_id); + self::checkProtectedSWF(); $book = $dao->selectById($book_id); if ($book->hash != $e[1]) { @@ -371,6 +372,7 @@ html{height:100%}' . "\n"; $args[1] = 2964; } self::checkDocumentVersionOfBook($args[1]); + self::checkProtectedSWF(); // cubePHP::neverStop(); $dao = new wsDAOBook($core->con); header('Content-type: text/plain'); @@ -379,6 +381,7 @@ html{height:100%}' . "\n"; exit; } + protected static function checkDocumentVersionOfBook($book_id) { global $core; diff --git a/inc/ws/Metier/class.ws.icone.php b/inc/ws/Metier/class.ws.icone.php index 9eb184bfd..1e0e4453e 100644 --- a/inc/ws/Metier/class.ws.icone.php +++ b/inc/ws/Metier/class.ws.icone.php @@ -4,7 +4,8 @@ class wsIcone extends cubeMetier { public $nom; public $date; - public static $files = array('index', 'normal', 'sommaire', 'print', 'friend', 'bookmark', 'fullscreen', 'normalscreen', 'save', 'archives', 'help'); + public static $files = array('index', 'normal', 'sommaire', 'print', 'friend', 'bookmark', 'fullscreen', 'normalscreen', 'save', 'archives', 'help', '2d', '3d', 'soundon', 'soundoff'); + public static $display = array('index', 'sommaire', 'print', 'friend', 'bookmark', 'fullscreen', 'save', 'archives', '3d', 'soundon', 'help'); public function makeImage() { @@ -21,14 +22,13 @@ class wsIcone extends cubeMetier { $liste = self::$files; - foreach($liste as $file) { - $image =$root . 'nav-' . $file . '.png'; + foreach($liste as $display) { + $image = $root . 'nav-' . $file . '.png'; $dim = getimagesize($image); $mod = max(filemtime($image), $mod); $h = max($h, $dim[1]); $w += $dim[0]; - $w += 10; - + $w += 10; } $height = $h; @@ -40,7 +40,7 @@ class wsIcone extends cubeMetier { imagesavealpha($im, true); imagealphablending($im, true); $x = 5; - foreach($liste as $file) { + foreach($liste as $display) { $image = $root . 'nav-' . $file . '.png'; $s = imagecreatefrompng($image); $w = imagesx($s); -- 2.39.5