Constant

From ClaroDevel

Content status : DRAFT


2 usages of constant

  • to set a config value
  • to give a nme to a value

give a name

DEFINE("CONF_VAL_STUDENT_STATUS"    ,5); 
DEFINE("CONF_VAL_TEACHER_STATUS"    ,1); 
DEFINE("CONF_VAL_CANNOTCREATECOURSE_STATUS"    ,5); 
DEFINE("CONF_VAL_COURSECREATOR_STATUS"    ,1);

Note 1 : The CONF_VAL_ prefix isn't relevant enough. Whe have to state that it comes from Claroline. Maybe CLARO_CONF_ would be more relevant.

Note 2 : The variable are a mix of concatenated name and other part separated by underscore (_) character. Maybe should we harmonize that.

Proposition :

CLARO_CONF_STUDENT_STATUS
CLARO_CONF_COURSE_MANAGER_STATUS (or CLARO_CONF_TEACHER_STATUS)
CLARO_CONF_COURSE_CREATION_PERMISION_STATUS
CLARO_CONF_COURSE_CREATOR_STATUS

config value

in index.php

define("CONFVAL_showNodeEmpty",TRUE);
define("CONFVAL_showNumberOfChild",TRUE); // actually  count are only for direct childs
define("CONFVAL_ShowLinkBackToTopOfTree",false);
define("CONFVAL_showCourseLangIfNotSameThatPlatform",TRUE);