$res .= '</ul>';
- $contents=$collection->contents;
- $theme=$collection->theme;
+ $contents = $collection->contents;
+ $theme = $collection->theme;
foreach ($langs as $l) {
$e = explode('_', $l);
$versions['mac-exe'] = array('title' => __('Version offline') . ' - ' . __('Exécutable Mac OS X') . ' (Flash)', 'icon' => cubeMedia::image(IMG . '/macos.png'));
$versions['mac-exe-html'] = array('title' => __('Version offline') . ' - ' . __('Exécutable Mac OS X') . ' (HTML)', 'icon' => cubeMedia::image(IMG . '/macos.png'));
$versions['win-cd'] = array('title' => __('Version offline') . ' - ' . __('CD-ROM') . ' / ' . __('Clé USB') . ' (Flash)', 'icon' => cubeMedia::silk('cd.png'));
- //$versions['win-cd-html'] = array('title' => __('Version offline') . ' - ' . __('CD-ROM') . ' / ' . __('Clé USB') . ' (HTML)', 'icon' => cubeMedia::silk('cd.png'));
+ $versions['win-cd-html'] = array('title' => __('Version offline') . ' - ' . __('CD-ROM') . ' / ' . __('Clé USB') . ' (HTML)', 'icon' => cubeMedia::silk('cd.png'));
$versions['win-html'] = array('title' => __('Version offline') . ' - ' . __('HTML') . ' (' . __('Non adaptée à l\'installation sur un serveur web') . ')', 'icon' => cubeMedia::silk('cd.png'));
if ($droits->admin) {
<?php\r
\r
-class wsPackagerWinCDHTML extends wsPackagerWinEXEHTML {\r
+class wsPackagerWinCDHTML extends wsPackagerMacEXEHTML\r
+{\r
\r
- public function __construct($book_id) {\r
+ public function __construct($book_id)\r
+ {\r
parent::__construct($book_id);\r
$this->book->parametres->alwaysHTML5 = true;\r
$this->version = 'win-cd-html';\r
}\r
\r
- protected function preparePackage() {\r
+ protected function preparePackage()\r
+ {\r
parent::preparePackage();\r
$this->replaceAutorun();\r
\r
// Package mac app\r
- $mac = wsPackager::package($this->book_id, 'mac-exe-html', false) . '/' . $this->exeName . '.app';\r
- $dest = $this->getFinalPackageDir();\r
- `cp -r $mac $dest`;\r
+ $win = ROOT . wsPackager::package($this->book_id, 'win-inss-html', false, false);\r
+\r
+ $dest = $this->getFinalPackageDir() . "/" . $this->exeName . '.exe';\r
+ $cp = "cp $win $dest";\r
+ `$cp`;\r
}\r
\r
- public function replaceAutorun() {\r
- $inf = file_get_contents($this->vdir . 'autorun.inf');\r
+ public function replaceAutorun()\r
+ {\r
+ $inf = file_get_contents(WS_COMPILE_ASSETS . '/autorun-html.inf');\r
$toReplace = array('title' => $this->book->parametres->title, 'exe' => $this->exeName . '.exe', 'nwplatform' => $this->nwplatform);\r
$inf = $this->replaceContents($inf, $toReplace);\r
- file_put_contents($this->vdir . 'autorun.inf', utf8_decode($inf));\r
- $this->copy($this->vdir . 'autorun.inf', $this->getFinalPackageDir() . '/autorun.inf');\r
+ file_put_contents($this->getFinalPackageDir() . '/autorun.inf', utf8_decode($inf));\r
}\r
\r
\r
- protected function postPackage() {\r
+ protected function postPackage()\r
+ {\r
\r
}\r
\r