Skip to content
Snippets Groups Projects
Commit 540104c9 authored by Sofiane Lasri's avatar Sofiane Lasri
Browse files

2.0.2021-05-12-2

parent 712f4965
No related branches found
No related tags found
No related merge requests found
<?php
if(!isset($vbcmsRootPath)){
$vbcmsRootPath = getcwd();
if(strpos($vbcmsRootPath, "/vbcms-admin") !== false){
$vbcmsRootPath = substr($vbcmsRootPath, 0, strpos($vbcmsRootPath, "/vbcms-admin"));
}
}
require 'dbConnect.php'; // Primordiale pour l'usage de la base de donnée
// Vérifie le type de connexion
......@@ -114,6 +117,7 @@ if ($folders[1]=="vbcms-admin") {// Ne s'éxecute que si l'on n'est sur le panne
}
} else { // Ne s'éxecute que si l'on n'est PAS sur le panneau admin (donc la partie publique)
if ($folders[1]!="vbcms-content") { // Permet aux scripts de communiquer tout en utilisant header
if($folders[1]=="backTasks"){
include $GLOBALS['vbcmsRootPath']."/backTasks.php";
......
......@@ -136,13 +136,13 @@ if (isset($_POST["submit"])) {
function openGallery(){
$('#galleryModal').modal('toggle');
if ($('#includeGallery').html()=="")
$('#includeGallery').load('<?=$http?>://<?=$_SERVER['HTTP_HOST']?>/vbcms-content/modules/vbcms-filemanager/admin/gallery-include.php');
$('#includeGallery').load('<?=$websiteUrl?>vbcms-content/modules/vbcms-filemanager/admin/gallery-include.php');
}
// Contournement pour ne sélectionner que les images
function openViewer(path){
$("#websiteLogoPreview").css("background", "url(\"<?=$http?>://<?=$_SERVER['HTTP_HOST']?>/vbcms-content/uploads"+path+"\"),linear-gradient(180deg, rgba(65,65,65,1) 0%, rgba(1,1,1,1) 100%)");
$("#websiteLogo").val("<?=$http?>://<?=$_SERVER['HTTP_HOST']?>/vbcms-content/uploads"+path);
$("#websiteLogoPreview").css("background", "url(\"<?=$websiteUrl?>vbcms-content/uploads"+path+"\"),linear-gradient(180deg, rgba(65,65,65,1) 0%, rgba(1,1,1,1) 100%)");
$("#websiteLogo").val("<?=$websiteUrl?>vbcms-content/uploads"+path);
$('#galleryModal').modal('hide');
}
function openVideo(path){
......
......@@ -77,7 +77,7 @@ if ($isUpToDate == 1) {
<h5>Détail de la mise à jour</h5>
<p><span class="text-muted">Installée: </span><span class="text-<?=$textColor?>"><?=$vbcmsVer?></span>
<?php
if ($isUpToDate == 0) echo '<br><span class="text-muted">Disponible: </span><span class="text-success"><?=$updateInfosData["version"]?></span>';
if ($isUpToDate == 0) echo '<br><span class="text-muted">Disponible: </span><span class="text-success">'.$updateInfosData["version"].'</span>';
?>
<br><span class="text-muted">Canal de mise à jour: </span>
<?php
......
<?php
// Ce fichier permet d'inclure la gallerie dans différentes pages
require $GLOBALS['vbcmsRootPath']."/vbcms-admin/includes/header.php";
// Inclu header car le fichier peut être appelé séparément du panel
// Dans ce cas on doit recréer le root path
$vbcmsRootPath = getcwd();
if(strpos($vbcmsRootPath, "/vbcms-content") !== false){
$vbcmsRootPath = substr($vbcmsRootPath, 0, strpos($vbcmsRootPath, "/vbcms-content"));
}
require_once $GLOBALS['vbcmsRootPath']."/vbcms-admin/includes/header.php";
require $GLOBALS['vbcmsRootPath']."/vbcms-content/modules/vbcms-filemanager/admin/gallery-htmlOnly.php";
require $GLOBALS['vbcmsRootPath']."/vbcms-content/modules/vbcms-filemanager/admin/gallery-scriptOnly.php";
\ No newline at end of file
?>
\ No newline at end of file
<?php
// Je le remet car l'inclusion de header.php va causer plus de problèmes qu'autre chose
if(isset($_SERVER['HTTPS'])) $http = "https"; else $http = "http";
//if(isset($_SERVER['HTTPS'])) $http = "https"; else $http = "http";
?>
<script src="<?=$websiteUrl?>vbcms-admin/js/md5.js"></script>
<script type="text/javascript">
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment