]> _ Git - cubeextranet.git/commitdiff
fix #3774 @0.25
authorvincent@cubedesigners.com <vincent@cubedesigners.com@f5622870-0f3c-0410-866d-9cb505b7a8ef>
Tue, 7 Jul 2020 13:16:30 +0000 (13:16 +0000)
committervincent@cubedesigners.com <vincent@cubedesigners.com@f5622870-0f3c-0410-866d-9cb505b7a8ef>
Tue, 7 Jul 2020 13:16:30 +0000 (13:16 +0000)
inc/ws/Metier/class.ws.book.parametres.php
inc/ws/Util/html5/master/class.ws.html5.compiler.php

index 7b35ccecce1f6f03fdccc7e6d5936ed8fbb88048..8b98607d7ceb9333041866c495ed6f3841d5e41f 100644 (file)
@@ -64,6 +64,9 @@ class wsBookParametres extends wsParametres
         $seoFilter->name = __('Fichier Excel') . ' (.xlsx)';
         $seoFilter->extensions = '*.xlsx';
 
+        $target = [__("Dans la fenĂȘtre courrante") => '_self',
+            __('Dans un nouvel onglet') => '_blank'];
+
         $cssFilter = new stdClass();
         $cssFilter->name = __('Feuille de style') . ' (.css)';
         $cssFilter->extensions = '*.css';
@@ -469,9 +472,10 @@ class wsBookParametres extends wsParametres
 
         $this->fields['splashImage'] = ['type' => 'freefile', 'default' => '', 'editable' => true, 'label' => __('Image'), 'grade' => 3, 'fileFilter' => $imageFilter];
         $this->fields['splashURL'] = ['type' => 'text', 'default' => '', 'editable' => true, 'label' => __('URL'), 'grade' => 3];
+        $this->fields['splashTarget'] = ['type' => 'combo', 'datas' => $target, 'default' => '_self', 'editable' => true, 'label' => __('Ouvrir le lien'), 'grade' => 3];
         $this->fields['splashMinimalTime'] = ['type' => 'float', 'default' => '1', 'editable' => true, 'label' => __('Temps minimal d\'affichage'), 'grade' => 3];
 
-        $this->forms['splash'] = ['label' => __('Ecran de chargement'), 'fieldsnames' => ['splashImage', 'splashURL', 'splashMinimalTime']];
+        $this->forms['splash'] = ['label' => __('Ecran de chargement'), 'fieldsnames' => ['splashImage', 'splashURL','splashTarget', 'splashMinimalTime']];
 
         // Articles
         $this->fields['articlesFile'] = ['type' => 'freefile', 'default' => '', 'editable' => true,
index 17b3945855c6e8e6fde8cb550c41dbb189c8f62e..2c4d52bc4abfe47df2a22e05ecaa39986ee2fb77 100644 (file)
@@ -963,7 +963,7 @@ class wsHTML5Compiler
                 $this->vdir->copy($this->wdir . '/' . $img, 'data/images/' . $img);
                 $splashstyles = 'background-image:url(' . 'data/images/' . $img . ');background-size:contain;background-position:50% 50%;';
                 if ($this->book->parametres->splashURL !== '') {
-                    $splash = '<a href="' . $this->book->parametres->splashURL . '" style="display:block;position:absolute;top:0;left;0;width:100%;height:100%"></a>';
+                    $splash = '<a href="' . $this->book->parametres->splashURL . '" target="'.$this->book->parametres->splashTarget.'" style="display:block;position:absolute;top:0;left;0;width:100%;height:100%"></a>';
                 }
             } else if ($this->theme->parametres->logoLoader && file_exists($this->themeRoot . $this->theme->parametres->logoLoader)) {
                 $dim = CubeIT_Image::getimagesize($this->themeRoot . $this->theme->parametres->logoLoader);