From: vincent@cubedesigners.com Date: Fri, 8 Feb 2013 16:17:31 +0000 (+0000) Subject: (no commit message) X-Git-Url: http://git.cubedesigners.com/?a=commitdiff_plain;h=8f48a5593278b4e945f84121948c9feacd8deb9a;p=cubeextranet.git --- diff --git a/.htaccess b/.htaccess index a950c2c96..cce222941 100644 --- a/.htaccess +++ b/.htaccess @@ -28,7 +28,7 @@ AddCharset UTF-8 log RewriteRule ^ajax/supprimeFichier/([0-9]+)/(.*)$ index.php/ajax/supprimeFichier/$1/$2 [L] RewriteRule ^telecharger/([0-9a-fA-F]+)/([0-9]+)/(.*)$ index.php/telecharger/$1/$2/$3 [L] RewriteRule ^telechargerr/([0-9a-fA-F]+)/([0-9]+)/(.*)$ index.php/telechargerr/$1/$2/$3 [L] - RewriteRule ^([-_a-zA-Z0-9/]+)$ index.php/$1 [L] + RewriteRule ^([-,_a-zA-Z0-9/]+)$ index.php/$1 [L] RewriteRule ^viewer/([0-9]+)_([0-9a-fA-F]+)_([0-9]+)/index.html$ viewer/$1_$2_$3/index [L] RewriteRule ^viewer/([0-9]+)_([0-9a-fA-F]+)_([0-9]+)/index.swf$ fluidbook/compile/index.swf [L] diff --git a/inc/commons/class.common.core.php b/inc/commons/class.common.core.php index b6d4eca48..cf0bcea6d 100644 --- a/inc/commons/class.common.core.php +++ b/inc/commons/class.common.core.php @@ -355,6 +355,7 @@ class commonCore extends cubeCore { $db->document_links_versions->index('idx_document_links_version_update', 'BTREE', 'update'); // Table Books $db->books->book_id('integer', 0, false); + $db->books->cid('varchar', 6, false); $db->books->nom('varchar', 256, false); $db->books->lang('varchar', 20, false); $db->books->theme('integer', 0, false); diff --git a/inc/ws/Controlleur/class.ws.services.php b/inc/ws/Controlleur/class.ws.services.php index 844cc6b51..6207dd2dd 100644 --- a/inc/ws/Controlleur/class.ws.services.php +++ b/inc/ws/Controlleur/class.ws.services.php @@ -325,6 +325,12 @@ class wsServices extends cubeFlashGateway { return array('url' => $destURL, 'file' => $destFile); } + public function e() { + $this->args['id'] = $this->callArgs[0]; + $this->args['range'] = $this->callArgs[1]; + return $this->exportpdf(); + } + public function exportpdf($print = false) { global $core; $dest = $this->getPDFComplex($this->args['id'], $this->args['range']); diff --git a/inc/ws/Util/html5/class.ws.html5.compiler.php b/inc/ws/Util/html5/class.ws.html5.compiler.php index 808365a57..e413ae3b3 100644 --- a/inc/ws/Util/html5/class.ws.html5.compiler.php +++ b/inc/ws/Util/html5/class.ws.html5.compiler.php @@ -11,13 +11,13 @@ class wsHTML5Compiler { } if ($version == 'stable') { - return new wsHTML5Compiler($book_id, $version, $phonegap, $dir, $standalone); + return new wsHTML5Compiler($book_id, 'stable', $phonegap, $dir, $standalone); } else { - return new wsHTML5CompilerDev($book_id, $version, $phonegap, $dir, $standalone); + return new wsHTML5CompilerDev($book_id, 'dev', $phonegap, $dir, $standalone); } } - protected static $resolutions = array(150); + protected static $resolutions = array(150,36); protected static $uaPrefixes = array('-moz-', '-webkit-', '-o-', '-ms-', ''); public $jsFiles = array( 'js/libs/fix/ios-orientation.js', @@ -60,6 +60,7 @@ class wsHTML5Compiler { public $testJsFiles = array( 'js/libs/cube/fb.js', 'js/libs/modernizr/modernizr.js', + 'js/libs/modernizr/tests.js', 'js/libs/jquery/jquery.js', 'js/libs/jquery/jquery.transform.js', 'js/libs/jquery/jquery.mousewheel.js', @@ -69,6 +70,7 @@ class wsHTML5Compiler { public $widgetJsFiles = array( 'js/libs/cube/fb.js', 'js/libs/modernizr/modernizr.js', + 'js/libs/modernizr/tests.js', 'js/libs/jquery/jquery.js', 'js/libs/jquery/jquery.transit.js', 'js/widget.js' @@ -670,6 +672,7 @@ class wsHTML5Compiler { $config = $this->writeConfig(); $finals = array('fluidbook' => $this->jsFiles, 'widget' => $this->widgetJsFiles); + foreach ($finals as $jsfinal => $files) { $mintime = 0; $minimized = $this->assets . '/js/' . $jsfinal . '-min.js'; @@ -684,6 +687,12 @@ class wsHTML5Compiler { } } + if (!$reminimize) { + if (filemtime(__FILE__) > $mintime) { + $reminimize = true; + } + } + if ($reminimize) { $js = ''; foreach ($files as $file) { @@ -696,9 +705,7 @@ class wsHTML5Compiler { $uglify = new cubeCommandLine('uglifyjs'); $uglify->setPath(CONVERTER_PATH); $uglify->setArg('o', $minimized); - $uglify->setArg('mangle-toplevel'); $uglify->setArg('no-copyright'); - $uglify->setArg('unsafe'); $uglify->setArg(null, $tmp); $uglify->execute(); } diff --git a/inc/ws/prepend.php b/inc/ws/prepend.php index c34e389b4..19d8a0c0d 100644 --- a/inc/ws/prepend.php +++ b/inc/ws/prepend.php @@ -2,6 +2,7 @@ $core->url->register('flash', 'flash', '^flash(.*)$', array('wsFlash', 'in')); $core->url->register('services', 'services', '^services(.*)$', array('wsServices', 'in')); +$core->url->register('s', 's', '^s/(.*)$', array('wsServices', 'in')); $core->url->register('maintenance', 'maintenance', '^maintenance(.*)$', array('wsMaintenance', 'in')); $core->url->register('editor', 'editor', '^editor/(.*)$', array('wsUrl', 'editor')); $core->url->register('restoreLinks', 'restoreLinks', '^restoreLinks/(.*)$', array('wsUrl', 'restoreLinks'));