Skip to content
Snippets Groups Projects
Commit 64e33b70 authored by Laurent Destailleur's avatar Laurent Destailleur
Browse files

Fix: Corrections mineures

parent 4f344f0c
No related branches found
No related tags found
No related merge requests found
...@@ -86,14 +86,16 @@ elseif ($_POST["test"]) ...@@ -86,14 +86,16 @@ elseif ($_POST["test"])
if ($oscommercedb->connected == 1 && $oscommercedb->database_selected == 1) if ($oscommercedb->connected == 1 && $oscommercedb->database_selected == 1)
{ {
// Vrifie si bonne base par requete sur une table OSCommerce // Vrifie si bonne base par requete sur une table OSCommerce
$sql="SELECT xxx FROM zzz WHERE aaa='application_name'"; $sql ="SELECT configuration_value";
$sql.=" FROM configuration";
$sql.=" WHERE configuration_key='STORE_NAME'";
$resql=$oscommercedb->query($sql); $resql=$oscommercedb->query($sql);
if ($resql) { if ($resql) {
$mesg ="<div class=\"ok\">".$langs->trans("OSCommerceTestOk",$_POST["oscommerce_dbhost"],$_POST["oscommerce_dbname"],$_POST["oscommerce_dbuser"]); $mesg ="<div class=\"ok\">".$langs->trans("OSCommerceTestOk",$_POST["oscommerce_dbhost"],$_POST["oscommerce_dbname"],$_POST["oscommerce_dbuser"]);
$mesg.="</div>"; $mesg.="</div>";
} }
else { else {
$mesg ="<div class=\"error\">".$langs->trans("ErrorConnectOkButWrongDatabase"); $mesg ="<div class=\"error\">".$langs->trans("OSCommerceErrorConnectOkButWrongDatabase");
$mesg.="</div>"; $mesg.="</div>";
} }
......
...@@ -108,7 +108,7 @@ elseif ($actiontest) ...@@ -108,7 +108,7 @@ elseif ($actiontest)
$mesg.="</div>"; $mesg.="</div>";
} }
else { else {
$mesg ="<div class=\"error\">".$langs->trans("ErrorConnectOkButWrongDatabase"); $mesg ="<div class=\"error\">".$langs->trans("WebCalErrorConnectOkButWrongDatabase");
$mesg.="</div>"; $mesg.="</div>";
} }
......
...@@ -17,20 +17,19 @@ ...@@ -17,20 +17,19 @@
* *
* $Id$ * $Id$
* $Source$ * $Source$
*
*/ */
/* /*
\file htdocs/compta/prelevement/prelevement.class.php \file htdocs/compta/prelevement/rejet-prelevement.class.php
\ingroup prelevement \ingroup prelevement
\brief Fichier de la classe des prelevements \brief Fichier de la classe des prelevements
\version $Revision$ \version $Revision$
*/ */
/*! /**
\class Prelevement \class Prelevement
\brief Classe permettant la gestion des prelevements \brief Classe permettant la gestion des prelevements
*/ */
class RejetPrelevement class RejetPrelevement
......
...@@ -92,8 +92,11 @@ class Conf ...@@ -92,8 +92,11 @@ class Conf
$objp = $db->fetch_object($result); $objp = $db->fetch_object($result);
$key=$objp->name; $key=$objp->name;
$value=$objp->value; // Pas de stripslashes (ne s'applique pas sur lecture en base mais aprs POST quand get_magic_quotes_gpc()==1) $value=$objp->value; // Pas de stripslashes (ne s'applique pas sur lecture en base mais aprs POST quand get_magic_quotes_gpc()==1)
define ("$key", $value); if ($key)
$this->global->$key=$value; {
define ("$key", $value);
$this->global->$key=$value;
}
$i++; $i++;
} }
} }
...@@ -141,14 +144,14 @@ class Conf ...@@ -141,14 +144,14 @@ class Conf
// Module mailing // Module mailing
$this->mailing->enabled=defined("MAIN_MODULE_MAILING")?MAIN_MODULE_MAILING:0; $this->mailing->enabled=defined("MAIN_MODULE_MAILING")?MAIN_MODULE_MAILING:0;
// Module notification // Module notification
$this->notification->enabled=defined("MAIN_MODULE_NOTIFICATION")?MAIN_MODULE_NOTIFICATION:0; $this->notification->enabled=defined("MAIN_MODULE_NOTIFICATION")?MAIN_MODULE_NOTIFICATION:0;
// Module externalrss // Module externalrss
$this->externalrss->enabled=defined("MAIN_MODULE_EXTERNALRSS")?MAIN_MODULE_EXTERNALRSS:0; $this->externalrss->enabled=defined("MAIN_MODULE_EXTERNALRSS")?MAIN_MODULE_EXTERNALRSS:0;
$this->externalrss->dir_temp=DOL_DATA_ROOT."/rss/temp"; $this->externalrss->dir_temp=DOL_DATA_ROOT."/rss/temp";
// Module commande client // Module commande client
$this->commande->enabled=defined("MAIN_MODULE_COMMANDE")?MAIN_MODULE_COMMANDE:0; $this->commande->enabled=defined("MAIN_MODULE_COMMANDE")?MAIN_MODULE_COMMANDE:0;
$this->commande->dir_output=DOL_DATA_ROOT."/commande"; $this->commande->dir_output=DOL_DATA_ROOT."/commande";
...@@ -293,7 +296,7 @@ class Conf ...@@ -293,7 +296,7 @@ class Conf
// outils systemes // outils systemes
if (! $this->global->SYSTEMTOOLS_MYSQLDUMP) $this->global->SYSTEMTOOLS_MYSQLDUMP="mysqldump"; if (! $this->global->SYSTEMTOOLS_MYSQLDUMP) $this->global->SYSTEMTOOLS_MYSQLDUMP="mysqldump";
// societe // societe
if (! $this->global->SOCIETE_CODECLIENT_ADDON) $this->global->SOCIETE_CODECLIENT_ADDON="mod_codeclient_leopard"; if (! $this->global->SOCIETE_CODECLIENT_ADDON) $this->global->SOCIETE_CODECLIENT_ADDON="mod_codeclient_leopard";
if (! $this->global->SOCIETE_CODEFOURNISSEUR_ADDON) $this->global->SOCIETE_CODEFOURNISSEUR_ADDON="mod_codeclient_leopard"; if (! $this->global->SOCIETE_CODEFOURNISSEUR_ADDON) $this->global->SOCIETE_CODEFOURNISSEUR_ADDON="mod_codeclient_leopard";
......
...@@ -320,6 +320,12 @@ function dolibarr_set_const($db, $name, $value, $type='chaine', $visible=0, $not ...@@ -320,6 +320,12 @@ function dolibarr_set_const($db, $name, $value, $type='chaine', $visible=0, $not
$db->begin(); $db->begin();
if (! $name)
{
dolibarr_print_error("Error: Call to function dolibarr_set_const with wrong parameters");
exit;
}
//dolibarr_syslog("dolibarr_set_const name=$name, value=$value"); //dolibarr_syslog("dolibarr_set_const name=$name, value=$value");
$sql = "DELETE FROM llx_const WHERE name = '$name';"; $sql = "DELETE FROM llx_const WHERE name = '$name';";
$resql=$db->query($sql); $resql=$db->query($sql);
......
...@@ -21,13 +21,13 @@ ...@@ -21,13 +21,13 @@
* $Source$ * $Source$
*/ */
/** \file htdocs/viewimage.php /**
\file htdocs/viewimage.php
\brief Wrapper permettant l'affichage de fichiers images Dolibarr \brief Wrapper permettant l'affichage de fichiers images Dolibarr
\remarks L'appel est viewimage.php?file=pathrelatifdufichier&modulepart=repfichierconcerne \remarks L'appel est viewimage.php?file=pathrelatifdufichier&modulepart=repfichierconcerne
\version $Revision$ \version $Revision$
*/ */
require_once("master.inc.php");
require_once("main.inc.php"); require_once("main.inc.php");
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment