本文整理汇总了PHP中G::SendTemporalMessage方法的典型用法代码示例。如果您正苦于以下问题:PHP G::SendTemporalMessage方法的具体用法?PHP G::SendTemporalMessage怎么用?PHP G::SendTemporalMessage使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类G
的用法示例。
在下文中一共展示了G::SendTemporalMessage方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: saveAuthSources
function saveAuthSources($params)
{
global $RBAC;
if ($RBAC->userCanAccess('PM_SETUP_ADVANCE') != 1) {
G::SendTemporalMessage('ID_USER_HAVENT_RIGHTS_PAGE', 'error', 'labels');
G::header('location: ../login/login');
die;
}
$aCommonFields = array('AUTH_SOURCE_UID', 'AUTH_SOURCE_NAME', 'AUTH_SOURCE_PROVIDER', 'AUTH_SOURCE_SERVER_NAME', 'AUTH_SOURCE_PORT', 'AUTH_SOURCE_ENABLED_TLS', 'AUTH_ANONYMOUS', 'AUTH_SOURCE_SEARCH_USER', 'AUTH_SOURCE_PASSWORD', 'AUTH_SOURCE_VERSION', 'AUTH_SOURCE_BASE_DN', 'AUTH_SOURCE_OBJECT_CLASSES', 'AUTH_SOURCE_ATTRIBUTES');
$aFields = $aData = array();
unset($params->PHPSESSID);
foreach ($params as $sField => $sValue) {
if (in_array($sField, $aCommonFields)) {
$aFields[$sField] = $sField == 'AUTH_SOURCE_ENABLED_TLS' || $sField == 'AUTH_ANONYMOUS' ? $sValue == 'yes' ? 1 : 0 : $sValue;
} else {
$aData[$sField] = $sValue;
}
}
$aFields['AUTH_SOURCE_DATA'] = $aData;
if ($aFields['AUTH_SOURCE_UID'] == '') {
$RBAC->createAuthSource($aFields);
} else {
$RBAC->updateAuthSource($aFields);
}
$data = array();
$data['success'] = true;
return $data;
}
示例2: __construct
public function __construct()
{
$licensedFeatures =& PMLicensedFeatures::getSingleton();
if (!$licensedFeatures->verifyfeature('7qhYmF1eDJWcEdwcUZpT0k4S0xTRStvdz09')) {
G::SendTemporalMessage('ID_USER_HAVENT_RIGHTS_PAGE', 'error', 'labels');
G::header('location: ../login/login');
die;
}
$this->loadSettings();
}
示例3: __construct
public function __construct()
{
global $RBAC;
if ($RBAC->userCanAccess('PM_DASHBOARD') != 1) {
G::SendTemporalMessage('ID_USER_HAVENT_RIGHTS_PAGE', 'error', 'labels');
G::header('location: login/login');
exit(0);
}
G::LoadClass('pmDashlet');
$this->pmDashlet = new PMDashlet();
}
示例4: dbConnections
* Description: this was added for the additional database connections */
G::LoadClass('dbConnections');
$oDbConnections = new dbConnections($_SESSION['PROCESS']);
$oDbConnections->loadAdditionalConnections();
$stepFilename = "{$sNamespace}/{$sStepName}";
G::evalJScript("\n if (parent.setCurrent) {\n parent.setCurrent('" . $_GET['UID'] . "');\n }");
$G_PUBLISH->AddContent('content', $stepFilename);
} else {
$aMessage['MESSAGE'] = G::loadTranslation('ID_EXTERNAL_STEP_MISSING', SYS_LANG, array("plugin" => $sNamespace));
$G_PUBLISH->AddContent('xmlform', 'xmlform', 'login/showMessage', '', $aMessage);
}
break;
}
//Add content content step - End
} catch (Exception $e) {
G::SendTemporalMessage(G::LoadTranslation('ID_PROCESS_DEF_PROBLEM'), 'error', 'string', 3, 100);
$aMessage = array();
$aMessage['MESSAGE'] = $e->getMessage();
$G_PUBLISH = new Publisher();
$G_PUBLISH->AddContent('xmlform', 'xmlform', 'login/showMessage', '', $aMessage);
G::RenderPage('publish', 'blank');
die;
}
$oHeadPublisher =& headPublisher::getSingleton();
$oHeadPublisher->addScriptFile("/jscore/cases/core/cases_Step.js");
$oHeadPublisher->addScriptCode("\n if (typeof parent != 'undefined') {\n if (parent.showCaseNavigatorPanel) {\n parent.showCaseNavigatorPanel('{$sStatus}');\n }\n\n if (parent.setCurrent) {\n parent.setCurrent('" . $_GET['UID'] . "');\n }\n }");
G::RenderPage('publish', 'blank');
if ($_SESSION['TRIGGER_DEBUG']['ISSET']) {
G::evalJScript('
if (typeof showdebug != \'undefined\') {
showdebug();
示例5: header
$controllerAction = SYS_TARGET != '' ? SYS_TARGET : 'index';
//if the method exists
if (is_callable(array($controllerClass, $controllerAction))) {
$isControllerCall = true;
}
}
if (!$isControllerCall && !file_exists($phpFile)) {
$_SESSION['phpFileNotFound'] = $_SERVER['REQUEST_URI'];
header("location: /errors/error404.php?url=" . urlencode($_SERVER['REQUEST_URI']));
die;
}
}
//redirect to login, if user changed the workspace in the URL
if (!$avoidChangedWorkspaceValidation && isset($_SESSION['WORKSPACE']) && $_SESSION['WORKSPACE'] != SYS_SYS) {
$_SESSION['WORKSPACE'] = SYS_SYS;
G::SendTemporalMessage('ID_USER_HAVENT_RIGHTS_SYSTEM', "error");
// verify if the current skin is a 'ux' variant
$urlPart = substr(SYS_SKIN, 0, 2) == 'ux' && SYS_SKIN != 'uxs' ? '/main/login' : '/login/login';
header('Location: /sys' . SYS_SYS . '/' . SYS_LANG . '/' . SYS_SKIN . $urlPart);
die;
}
// enable rbac
$RBAC =& RBAC::getSingleton(PATH_DATA, session_id());
$RBAC->sSystem = 'PROCESSMAKER';
// define and send Headers for all pages
if (!defined('EXECUTE_BY_CRON')) {
header("Expires: " . gmdate("D, d M Y H:i:s", mktime(0, 0, 0, date('m'), date('d') - 1, date('Y'))) . " GMT");
header("Last-Modified: " . gmdate("D, d M Y H:i:s") . " GMT");
header("Cache-Control: no-store, no-cache, must-revalidate");
header("Cache-Control: post-check=0, pre-check=0", false);
header("Pragma: no-cache");
示例6: evaluate
//.........这里部分代码省略.........
}
} else {
if (!isset($aMatch[5][$i][0])) {
$sScript .= "\$this->aFields['" . $aMatch[2][$i][0] . "']";
} else {
$sScript .= "\$this->aFields" . (isset($aMatch[2][$i][0]) ? "['" . $aMatch[2][$i][0] . "']" : '') . $aMatch[5][$i][0];
}
}
break;
case '%':
if ($bEqual) {
if (!isset($aMatch[5][$i][0])) {
$sScript .= "pmToInteger(\$this->aFields['" . $aMatch[2][$i][0] . "'])";
} else {
$sScript .= "pmToInteger(\$this->aFields" . (isset($aMatch[2][$i][0]) ? "['" . $aMatch[2][$i][0] . "']" : '') . $aMatch[5][$i][0] . ")";
}
} else {
if (!isset($aMatch[5][$i][0])) {
$sScript .= "\$this->aFields['" . $aMatch[2][$i][0] . "']";
} else {
$sScript .= "\$this->aFields" . (isset($aMatch[2][$i][0]) ? "['" . $aMatch[2][$i][0] . "']" : '') . $aMatch[5][$i][0];
}
}
break;
case '#':
if ($bEqual) {
if (!isset($aMatch[5][$i][0])) {
$sScript .= "pmToFloat(\$this->aFields['" . $aMatch[2][$i][0] . "'])";
} else {
$sScript .= "pmToFloat(\$this->aFields" . (isset($aMatch[2][$i][0]) ? "['" . $aMatch[2][$i][0] . "']" : '') . $aMatch[5][$i][0] . ")";
}
} else {
if (!isset($aMatch[5][$i][0])) {
$sScript .= "\$this->aFields['" . $aMatch[2][$i][0] . "']";
} else {
$sScript .= "\$this->aFields" . (isset($aMatch[2][$i][0]) ? "['" . $aMatch[2][$i][0] . "']" : '') . $aMatch[5][$i][0];
}
}
break;
case '?':
if ($bEqual) {
if (!isset($aMatch[5][$i][0])) {
$sScript .= "pmToUrl(\$this->aFields['" . $aMatch[2][$i][0] . "'])";
} else {
$sScript .= "pmToUrl(\$this->aFields" . (isset($aMatch[2][$i][0]) ? "['" . $aMatch[2][$i][0] . "']" : '') . $aMatch[5][$i][0] . ")";
}
} else {
if (!isset($aMatch[5][$i][0])) {
$sScript .= "\$this->aFields['" . $aMatch[2][$i][0] . "']";
} else {
$sScript .= "\$this->aFields" . (isset($aMatch[2][$i][0]) ? "['" . $aMatch[2][$i][0] . "']" : '') . $aMatch[5][$i][0];
}
}
break;
case '$':
if ($bEqual) {
if (!isset($aMatch[5][$i][0])) {
$sScript .= "pmSqlEscape(\$this->aFields['" . $aMatch[2][$i][0] . "'])";
} else {
$sScript .= "pmSqlEscape(\$this->aFields" . (isset($aMatch[2][$i][0]) ? "['" . $aMatch[2][$i][0] . "']" : '') . $aMatch[5][$i][0] . ")";
}
} else {
if (!isset($aMatch[5][$i][0])) {
$sScript .= "\$this->aFields['" . $aMatch[2][$i][0] . "']";
} else {
$sScript .= "\$this->aFields" . (isset($aMatch[2][$i][0]) ? "['" . $aMatch[2][$i][0] . "']" : '') . $aMatch[5][$i][0];
}
}
break;
case '=':
if ($bEqual) {
if (!isset($aMatch[5][$i][0])) {
$sScript .= "\$this->aFields['" . $aMatch[2][$i][0] . "']";
} else {
$sScript .= "\$this->aFields" . (isset($aMatch[2][$i][0]) ? "['" . $aMatch[2][$i][0] . "']" : '') . $aMatch[5][$i][0];
}
} else {
if (!isset($aMatch[5][$i][0])) {
$sScript .= "\$this->aFields['" . $aMatch[2][$i][0] . "']";
} else {
$sScript .= "\$this->aFields" . (isset($aMatch[2][$i][0]) ? "['" . $aMatch[2][$i][0] . "']" : '') . $aMatch[5][$i][0];
}
}
break;
}
}
}
$sScript .= substr($this->sScript, $iAux);
$sScript = '$bResult = ' . $sScript . ';';
// checks if the syntax is valid or if the variables in that condition has been previously defined
if ($this->validSyntax($sScript) && $variableIsDefined) {
$this->bError = false;
eval($sScript);
} else {
// echo "<script> alert('".G::loadTranslation('MSG_CONDITION_NOT_DEFINED')."'); </script>";
G::SendTemporalMessage('MSG_CONDITION_NOT_DEFINED', 'error', 'labels');
$this->bError = true;
}
return $bResult;
}
示例7: downloadFile
/**
* download a File
*
* @param $file file to download
* @param $local_path path of the file
* @param $newfilename
* @return $errorMsg process list.
*/
public function downloadFile ($file, $local_path, $newfilename)
{
$err_msg = '';
$out = fopen( $local_path . $newfilename, 'wb' );
if ($out == false) {
throw (new Exception( "File $newfilename not opened" ));
}
if (! function_exists( 'curl_init' )) {
G::SendTemporalMessage( 'ID_CURLFUN_ISUNDEFINED', "warning", 'LABEL', '', '100%', '' );
G::header( 'location: ../processes/processes_Library' );
die();
}
$ch = curl_init();
curl_setopt( $ch, CURLOPT_FILE, $out );
curl_setopt( $ch, CURLOPT_HEADER, 0 );
curl_setopt( $ch, CURLOPT_URL, $file );
curl_exec( $ch );
$errorMsg = curl_error( $ch );
fclose( $out );
curl_close( $ch );
return $errorMsg;
} //end function
示例8: die
* License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Affero General Public License for more details.
*
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*
* For more information, contact Colosa Inc, 2566 Le Jeune Rd.,
* Coral Gables, FL, 33134, USA, or email info@colosa.com.
*/
//validate the data post
if (!isset($_SESSION['USER_LOGGED'])) {
G::SendTemporalMessage('ID_LOGIN_AGAIN', 'warning', 'labels');
die('<script type="text/javascript">
parent.location = "../cases/casesStartPage?action=startCase";
</script>');
}
try {
if ($_GET['APP_UID'] !== $_SESSION['APPLICATION']) {
throw new Exception(G::LoadTranslation('ID_INVALID_APPLICATION_ID_MSG', array('<a href=\'' . $_SERVER['HTTP_REFERER'] . '\'>{1}</a>', G::LoadTranslation('ID_REOPEN'))));
}
$oForm = new Form($_SESSION["PROCESS"] . "/" . $_GET["UID"], PATH_DYNAFORM);
$oForm->validatePost();
//Includes
G::LoadClass("case");
//Load the variables
$oCase = new Cases();
$oCase->thisIsTheCurrentUser($_SESSION["APPLICATION"], $_SESSION["INDEX"], $_SESSION["USER_LOGGED"], "REDIRECT", "casesListExtJs");
示例9: explode
}
if ($_FILES['form']['error']['USR_PHOTO'] != 1) {
if ($_FILES['form']['tmp_name']['USR_PHOTO'] != '') {
$aAux = explode('.', $_FILES['form']['name']['USR_PHOTO']);
G::uploadFile($_FILES['form']['tmp_name']['USR_PHOTO'], PATH_IMAGES_ENVIRONMENT_USERS, $aData['USR_UID'] . '.' . $aAux[1]);
G::resizeImage(PATH_IMAGES_ENVIRONMENT_USERS . $aData['USR_UID'] . '.' . $aAux[1], 96, 96, PATH_IMAGES_ENVIRONMENT_USERS . $aData['USR_UID'] . '.gif');
}
} else {
G::SendTemporalMessage('ID_FILE_TOO_BIG', 'error');
}
if ($_FILES['form']['error']['USR_RESUME'] != 1) {
if ($_FILES['form']['tmp_name']['USR_RESUME'] != '') {
G::uploadFile($_FILES['form']['tmp_name']['USR_RESUME'], PATH_IMAGES_ENVIRONMENT_FILES . $aData['USR_UID'] . '/', $_FILES['form']['name']['USR_RESUME']);
}
} else {
G::SendTemporalMessage('ID_FILE_TOO_BIG', 'error');
}
}
if ($_SESSION['USER_LOGGED'] == $form['USR_UID']) {
/*UPDATING SESSION VARIABLES*/
$aUser = $RBAC->userObj->load($_SESSION['USER_LOGGED']);
$_SESSION['USR_FULLNAME'] = $aUser['USR_FIRSTNAME'] . ' ' . $aUser['USR_LASTNAME'];
}
//Save Calendar assigment
if (isset($form['USR_CALENDAR'])) {
//Save Calendar ID for this user
G::LoadClass("calendar");
$calendarObj = new Calendar();
$calendarObj->assignCalendarTo($aData['USR_UID'], $form['USR_CALENDAR'], 'USER');
}
G::header('location: users_List');
示例10: Users
if ($_POST['form']['USR_RESUME'] != '') {
$aData['USR_RESUME'] = $_POST['form']['USR_RESUME'];
}
require_once 'classes/model/Users.php';
$oUser = new Users();
$oUser->update($aData);
if ($_FILES['form']['tmp_name']['USR_PHOTO'] != '') {
$aAux = explode('.', $_FILES['form']['name']['USR_PHOTO']);
G::uploadFile($_FILES['form']['tmp_name']['USR_PHOTO'], PATH_IMAGES_ENVIRONMENT_USERS, $aData['USR_UID'] . '.' . $aAux[1]);
G::resizeImage(PATH_IMAGES_ENVIRONMENT_USERS . $aData['USR_UID'] . '.' . $aAux[1], 96, 96, PATH_IMAGES_ENVIRONMENT_USERS . $aData['USR_UID'] . '.gif');
}
if ($_FILES['form']['tmp_name']['USR_RESUME'] != '') {
G::uploadFile($_FILES['form']['tmp_name']['USR_RESUME'], PATH_IMAGES_ENVIRONMENT_FILES . $aData['USR_UID'] . '/', $_FILES['form']['name']['USR_RESUME']);
}
/* Saving preferences */
$def_lang = $_POST['form']['PREF_DEFAULT_LANG'];
$def_menu = $_POST['form']['PREF_DEFAULT_MENUSELECTED'];
$def_cases_menu = $_POST['form']['PREF_DEFAULT_CASES_MENUSELECTED'];
G::loadClass('configuration');
$oConf = new Configurations();
$aConf = array('DEFAULT_LANG' => $def_lang, 'DEFAULT_MENU' => $def_menu, 'DEFAULT_CASES_MENU' => $def_cases_menu);
/*UPDATING SESSION VARIABLES*/
$aUser = $RBAC->userObj->load($_SESSION['USER_LOGGED']);
$_SESSION['USR_FULLNAME'] = $aUser['USR_FIRSTNAME'] . ' ' . $aUser['USR_LASTNAME'];
$oConf->aConfig = $aConf;
$oConf->saveConfig('USER_PREFERENCES', '', '', $_SESSION['USER_LOGGED']);
G::SendTemporalMessage('ID_CHANGES_SAVED', 'info', 'labels');
G::header('location: myInfo');
} catch (Exception $oException) {
die($oException->getMessage());
}
示例11: saveCalendarBusinessHours
function saveCalendarBusinessHours($aData)
{
$CalendarUid = $aData['CALENDAR_UID'];
$CalendarBusinessDay = $aData['CALENDAR_BUSINESS_DAY'];
$CalendarBusinessStart = $aData['CALENDAR_BUSINESS_START'];
$CalendarBusinessEnd = $aData['CALENDAR_BUSINESS_END'];
//if exists the row in the database propel will update it, otherwise will insert.
$tr = CalendarBusinessHoursPeer::retrieveByPK($CalendarUid, $CalendarBusinessDay, $CalendarBusinessStart, $CalendarBusinessEnd);
if (!(is_object($tr) && get_class($tr) == 'CalendarBusinessHours')) {
$tr = new CalendarBusinessHours();
}
$tr->setCalendarUid($CalendarUid);
$tr->setCalendarBusinessDay($CalendarBusinessDay);
$tr->setCalendarBusinessStart($CalendarBusinessStart);
$tr->setCalendarBusinessEnd($CalendarBusinessEnd);
if ($tr->validate()) {
// we save it, since we get no validation errors, or do whatever else you like.
$res = $tr->save();
} else {
// Something went wrong. We can now get the validationFailures and handle them.
$msg = $CalendarBusinessDay . '<hr/>';
$validationFailuresArray = $tr->getValidationFailures();
foreach ($validationFailuresArray as $objValidationFailure) {
$msg .= $objValidationFailure->getMessage() . "<br/>";
}
//return array ( 'codError' => -100, 'rowsAffected' => 0, 'message' => $msg );
G::SendTemporalMessage($msg);
}
//return array ( 'codError' => 0, 'rowsAffected' => $res, 'message' => '');
//to do: uniform coderror structures for all classes
//if ( $res['codError'] < 0 ) {
// G::SendMessageText ( $res['message'] , 'error' );
//}
}
示例12: jumping
/**
*
* @method
*
* Routes (derivates) a case and then displays the case list.
*
* @name jumping
* @label jumping
* @link http://wiki.processmaker.com/index.php/ProcessMaker_Functions#jumping.28.29
*
* @param string(32) | $caseId | Case ID | The unique ID for the case to be routed (derivated).
* @param int | $delIndex | delegation Index of case | The delegation index of the task to be routed (derivated). Counting starts from 1.
* @return none | $none | None | None
*
*/
function jumping($caseId, $delIndex)
{
try {
$x = PMFDerivateCase($caseId, $delIndex);
if ($x == 0) {
G::SendTemporalMessage('ID_NOT_DERIVATED', 'error', 'labels');
}
} catch (Exception $oException) {
G::SendTemporalMessage('ID_NOT_DERIVATED', 'error', 'labels');
}
G::header('Location: casesListExtJs');
}
示例13: str_replace
$snameLogo = str_replace("[Ñ]", "N", $snameLogo);
return $snameLogo;
}
$sfunction = $_GET['function'];
switch ($sfunction) {
case 'replacementLogo':
$snameLogo = urldecode($_GET['NAMELOGO']);
$snameLogo = trim($snameLogo);
$snameLogo = changeNamelogo($snameLogo);
G::loadClass('configuration');
$oConf = new Configurations();
$aConf = array('WORKSPACE_LOGO_NAME' => SYS_SYS, 'DEFAULT_LOGO_NAME' => $snameLogo);
$oConf->aConfig = $aConf;
$oConf->saveConfig('USER_LOGO_REPLACEMENT', '', '', '');
G::SendTemporalMessage('ID_REPLACED_LOGO', 'tmp-info', 'labels');
//header('location: uplogo.php');
//G::header('location: uplogo');
break;
case 'restoreLogo':
$snameLogo = $_GET['NAMELOGO'];
G::loadClass('configuration');
$oConf = new Configurations();
$aConf = array('WORKSPACE_LOGO_NAME' => '', 'DEFAULT_LOGO_NAME' => '');
$oConf->aConfig = $aConf;
$oConf->saveConfig('USER_LOGO_REPLACEMENT', '', '', '');
G::SendTemporalMessage('ID_REPLACED_LOGO', 'tmp-info', 'labels');
break;
}
} catch (Exception $oException) {
die($oException->getMessage());
}
示例14: catch
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Affero General Public License for more details.
*
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*
* For more information, contact Colosa Inc, 2566 Le Jeune Rd.,
* Coral Gables, FL, 33134, USA, or email info@colosa.com.
*/
$pluginFile = $_GET['id'];
G::LoadClass('plugin');
$oPluginRegistry =& PMPluginRegistry::getSingleton();
$details = $oPluginRegistry->getPluginDetails($pluginFile);
try {
$Fields = $oPluginRegistry->updateFieldsForPageSetup($details->sNamespace, $_POST);
$str = "{$Fields} fields saved successfully!";
G::SendTemporalMessage($str, 'info', 'string', 3, 100);
G::Header("location: pluginsSetup?id={$pluginFile}");
} catch (Exception $e) {
$G_MAIN_MENU = 'processmaker';
$G_ID_MENU_SELECTED = 'SETUP';
$G_SUB_MENU = 'setup';
$G_ID_SUB_MENU_SELECTED = 'PLUGINS';
$G_PUBLISH = new Publisher();
$aMessage['MESSAGE'] = $e->getMessage();
$G_PUBLISH->AddContent('xmlform', 'xmlform', 'login/showMessage', '', $aMessage);
G::RenderPage('publish');
}
示例15: replacementLogo
/**
* Replacement Logo
* @global type $_REQUEST
* @global type $RBAC
*/
public function replacementLogo()
{
global $_REQUEST;
$sfunction = $_REQUEST['nameFunction'];
$_GET['NAMELOGO'] = $_REQUEST['NAMELOGO'];
try {
global $RBAC;
switch ($RBAC->userCanAccess('PM_LOGIN')) {
case -2:
G::SendTemporalMessage('ID_USER_HAVENT_RIGHTS_SYSTEM', 'error', 'labels');
G::header('location: ../login/login');
die;
break;
case -1:
G::SendTemporalMessage('ID_USER_HAVENT_RIGHTS_PAGE', 'error', 'labels');
G::header('location: ../login/login');
die;
break;
}
switch ($sfunction) {
case 'replacementLogo':
$snameLogo = urldecode($_GET['NAMELOGO']);
$snameLogo = trim($snameLogo);
$snameLogo = self::changeNamelogo($snameLogo);
G::loadClass('configuration');
$oConf = new Configurations();
$aConf = array('WORKSPACE_LOGO_NAME' => SYS_SYS, 'DEFAULT_LOGO_NAME' => $snameLogo);
$oConf->aConfig = $aConf;
$oConf->saveConfig('USER_LOGO_REPLACEMENT', '', '', '');
G::SendTemporalMessage('ID_REPLACED_LOGO', 'tmp-info', 'labels');
break;
case 'restoreLogo':
$snameLogo = $_GET['NAMELOGO'];
G::loadClass('configuration');
$oConf = new Configurations();
$aConf = array('WORKSPACE_LOGO_NAME' => '', 'DEFAULT_LOGO_NAME' => '');
$oConf->aConfig = $aConf;
$oConf->saveConfig('USER_LOGO_REPLACEMENT', '', '', '');
G::SendTemporalMessage('ID_REPLACED_LOGO', 'tmp-info', 'labels');
break;
}
} catch (Exception $oException) {
die($oException->getMessage());
}
exit;
}