Beispiel #1
0
	public static function _(){
		$isSaved = MRequest::getCookie("profilesissaved",0, MREQUEST_INT);
		
		if($isSaved){
			MRequest::setCookie("profilesissaved", 0);
			$css = _FM_IS_DEMO ? "rejectedAdvice" : "savedAdvice";
			$text = _FM_IS_DEMO ? "notfordemo" : "datasaved";
			echo '
				<div id="mSavedAdvice" class="'.$css.'"><div>'.MText::_($text).'</div></div>
				<script type="text/javascript">
					dojo.addOnLoad(function(){
							var node = dojo.byId("mSavedAdvice");
							dojo.style(node,{opacity: 0});
							_fx.fadeOpacity(node,300,0,1,function(){
								setTimeout(function(){
									var node = dojo.byId("mSavedAdvice");
									dojo.style(node,{opacity: 1});
									_fx.fadeOpacity(node,400,1,0,function(){
										 _removeNode(dojo.byId("mSavedAdvice"));
									});
								},2000);
							});
					});
				</script>
			';
		}
		
		
	}
Beispiel #2
0
    if (isset($_COOKIE["mtoggleimageview"])) {
        $imageViewState = (int) $_COOKIE["mtoggleimageview"];
    } else {
        $imageViewState = 0;
        setcookie("mtoggleimageview", $imageViewState, _FM_COOKIE_EXPIRE);
    }
} else {
    setcookie("mtoggleimageview", $imageViewState, _FM_COOKIE_EXPIRE);
}
define('_M_IMAGE_VIEW_STATE', $imageViewState);
//Security processing
require_once 'includes' . DS . 'secure.php';
//Files View
$filesView = MRequest::int('filesview', null);
if ($filesView !== null) {
    MRequest::setCookie('filesView', $filesView);
    $GLOBALS['filesView'] = $filesView;
} else {
    $GLOBALS['filesView'] = MRequest::getCookie('filesView', 1, MREQUEST_INT);
}
// Processing the view
$viewName = $view . "view";
if (file_exists(_FM_HOME_DIR . DS . 'view' . DS . $viewName . '.php')) {
    require_once 'view' . DS . $viewName . '.php';
} else {
    $viewName = null;
}
// Processing controller
$controllerName = $view == 'default' ? 'defaulttask' : $view;
if (file_exists(_FM_HOME_DIR . DS . 'controller' . DS . $controllerName . '.php')) {
    require_once 'controller' . DS . $controllerName . '.php';