[eGroupWare-svn] r55989 - in /trunk: egroupware/ egroupware/api/src/ egroupware/api/src/Accounts/ egroupware/api/src/Egw/ egroupware/api/temp...

[email protected] Mon, 02 May 2016 22:26:43 -0000
Newsgroups gmane.comp.web.egroupware.cvs
Message-ID <[email protected]>
Author: ralfbecker
Date: Tue May  3 00:26:40 2016
New Revision: 55989

URL: http://svn.stylite.de/viewvc/egroupware?rev=55989&view=rev
Log:
WIP egw installs now without phpgwapi and allows to login

Added:
    trunk/egroupware/api/templates/default/idots.css
      - copied, changed from r55978, trunk/phpgwapi/templates/idots/css/idots.css
    trunk/egroupware/api/templates/default/images/appbox-header-background.png
      - copied unchanged from r55978, trunk/phpgwapi/templates/idots/images/appbox-header-background.png
    trunk/egroupware/api/templates/default/images/background-icon-bar.png
      - copied unchanged from r55978, trunk/phpgwapi/templates/idots/images/background-icon-bar.png
    trunk/egroupware/api/templates/default/images/bgtopmenu2.png
      - copied unchanged from r55978, trunk/phpgwapi/templates/idots/images/bgtopmenu2.png
    trunk/egroupware/api/templates/default/images/body-background.png
      - copied unchanged from r55978, trunk/phpgwapi/templates/idots/images/body-background.png
    trunk/egroupware/api/templates/default/images/favicon.ico
      - copied unchanged from r55978, trunk/phpgwapi/templates/default/images/favicon.ico
    trunk/egroupware/api/templates/default/images/gradient22.png
      - copied unchanged from r55978, trunk/phpgwapi/templates/idots/images/gradient22.png
    trunk/egroupware/api/templates/default/images/logo.png
      - copied unchanged from r55976, trunk/phpgwapi/templates/default/images/logo.png
    trunk/egroupware/api/templates/default/images/logo.svg
      - copied unchanged from r55976, trunk/phpgwapi/templates/default/images/logo.svg
    trunk/egroupware/api/templates/default/images/resize-transparent.png
      - copied unchanged from r55978, trunk/phpgwapi/templates/idots/images/resize-transparent.png
    trunk/egroupware/api/templates/default/images/resize.png
      - copied unchanged from r55978, trunk/phpgwapi/templates/idots/images/resize.png
    trunk/setup/templates/default/images/spacer.gif
      - copied unchanged from r55976, trunk/phpgwapi/templates/idots/images/spacer.gif
Removed:
    trunk/phpgwapi/templates/default/images/favicon.ico
    trunk/phpgwapi/templates/default/images/logo.png
    trunk/phpgwapi/templates/default/images/logo.svg
    trunk/phpgwapi/templates/idots/css/idots.css
    trunk/phpgwapi/templates/idots/images/appbox-header-background.png
    trunk/phpgwapi/templates/idots/images/background-icon-bar.png
    trunk/phpgwapi/templates/idots/images/bgtopmenu2.png
    trunk/phpgwapi/templates/idots/images/resize-transparent.png
    trunk/phpgwapi/templates/idots/images/resize.png
Modified:
    trunk/egroupware/api/src/Accounts/Sql.php
    trunk/egroupware/api/src/Egw.php
    trunk/egroupware/api/src/Egw/Base.php
    trunk/egroupware/api/src/Framework.php
    trunk/egroupware/api/templates/default/default.css
    trunk/egroupware/login.php
    trunk/egroupware/logout.php
    trunk/setup/admin_account.php
    trunk/setup/applications.php
    trunk/setup/check_install.php
    trunk/setup/config.php
    trunk/setup/inc/class.setup.inc.php
    trunk/setup/inc/class.setup_cmd_config.inc.php
    trunk/setup/inc/class.setup_detection.inc.php
    trunk/setup/inc/class.setup_html.inc.php
    trunk/setup/inc/class.setup_process.inc.php
    trunk/setup/index.php
    trunk/setup/manageheader.php
    trunk/setup/schematoy.php
    trunk/setup/sqltoarray.php
    trunk/setup/templates/default/head.tpl
    trunk/setup/templates/default/manageheader.tpl

Modified: trunk/egroupware/api/src/Accounts/Sql.php
URL: http://svn.stylite.de/viewvc/egroupware/trunk/egroupware/api/src/Accounts/Sql.php?rev=55989&r1=55988&r2=55989&view=diff
==============================================================================
--- trunk/egroupware/api/src/Accounts/Sql.php (original)
+++ trunk/egroupware/api/src/Accounts/Sql.php Tue May  3 00:26:40 2016
@@ -323,7 +323,7 @@
 	{
 		if (!(int)$account_id) return;
 
-		$acl =& CreateObject('phpgwapi.acl',$account_id);
+		$acl = new Api\Acl($account_id);
 		$acl->read_repository();
 		$acl->delete('phpgw_group',false);
 

Modified: trunk/egroupware/api/src/Egw.php
URL: http://svn.stylite.de/viewvc/egroupware/trunk/egroupware/api/src/Egw.php?rev=55989&r1=55988&r2=55989&view=diff
==============================================================================
--- trunk/egroupware/api/src/Egw.php (original)
+++ trunk/egroupware/api/src/Egw.php Tue May  3 00:26:40 2016
@@ -407,23 +407,26 @@
 		define('PHPGW_ACL_CUSTOM_2',128);
 		define('PHPGW_ACL_CUSTOM_3',256);
 		// A few hacker resistant constants that will be used throught the program
-		define('EGW_TEMPLATE_DIR', $this->common->get_tpl_dir('phpgwapi'));
-		define('EGW_IMAGES_DIR', $this->common->get_image_path('phpgwapi'));
-		define('EGW_IMAGES_FILEDIR', $this->common->get_image_dir('phpgwapi'));
-		define('EGW_APP_ROOT', $this->common->get_app_dir());
-		define('EGW_APP_INC', $this->common->get_inc_dir());
-		define('EGW_APP_TPL', $this->common->get_tpl_dir());
-		define('EGW_IMAGES', $this->common->get_image_path());
-		define('EGW_APP_IMAGES_DIR', $this->common->get_image_dir());
-		// and the old ones
-		define('PHPGW_TEMPLATE_DIR',EGW_TEMPLATE_DIR);
-		define('PHPGW_IMAGES_DIR',EGW_IMAGES_DIR);
-		define('PHPGW_IMAGES_FILEDIR',EGW_IMAGES_FILEDIR);
-		define('PHPGW_APP_ROOT',EGW_APP_ROOT);
-		define('PHPGW_APP_INC',EGW_APP_INC);
-		define('PHPGW_APP_TPL',EGW_APP_TPL);
-		define('PHPGW_IMAGES',EGW_IMAGES);
-		define('PHPGW_APP_IMAGES_DIR',EGW_APP_IMAGES_DIR);
+		if (file_exists(EGW_SERVER_ROOT.'/phpgwapi'))
+		{
+			define('EGW_TEMPLATE_DIR', $this->common->get_tpl_dir('phpgwapi'));
+			define('EGW_IMAGES_DIR', $this->common->get_image_path('phpgwapi'));
+			define('EGW_IMAGES_FILEDIR', $this->common->get_image_dir('phpgwapi'));
+			define('EGW_APP_ROOT', $this->common->get_app_dir());
+			define('EGW_APP_INC', $this->common->get_inc_dir());
+			define('EGW_APP_TPL', $this->common->get_tpl_dir());
+			define('EGW_IMAGES', $this->common->get_image_path());
+			define('EGW_APP_IMAGES_DIR', $this->common->get_image_dir());
+			// and the old ones
+			define('PHPGW_TEMPLATE_DIR',EGW_TEMPLATE_DIR);
+			define('PHPGW_IMAGES_DIR',EGW_IMAGES_DIR);
+			define('PHPGW_IMAGES_FILEDIR',EGW_IMAGES_FILEDIR);
+			define('PHPGW_APP_ROOT',EGW_APP_ROOT);
+			define('PHPGW_APP_INC',EGW_APP_INC);
+			define('PHPGW_APP_TPL',EGW_APP_TPL);
+			define('PHPGW_IMAGES',EGW_IMAGES);
+			define('PHPGW_APP_IMAGES_DIR',EGW_APP_IMAGES_DIR);
+		}
 	}
 
 	/**
@@ -593,7 +596,7 @@
 			if (!$GLOBALS['egw_info']['server']['asyncservice'])	// is default
 			{
 				$async = new Asyncservice();
-				$async->fallback();
+				$async->check_run('fallback');
 			}
 			$this->db->disconnect();
 		}

Modified: trunk/egroupware/api/src/Egw/Base.php
URL: http://svn.stylite.de/viewvc/egroupware/trunk/egroupware/api/src/Egw/Base.php?rev=55989&r1=55988&r2=55989&view=diff
==============================================================================
--- trunk/egroupware/api/src/Egw/Base.php (original)
+++ trunk/egroupware/api/src/Egw/Base.php Tue May  3 00:26:40 2016
@@ -18,7 +18,9 @@
 use EGroupware\Api;
 
 // explicitly list old, non-namespaced classes
-use common;	// get_tpl_dir
+// they are only used, if phpgwapi is installed
+use accounts as egw_accounts;
+use egw_session;
 
 /**
  * Egw\Base object used in setup, does not instanciate anything by default
@@ -53,6 +55,8 @@
 	 */
 	var $ADOdb;
 
+	var $system_charset = 'utf-8';
+
 	/**
 	 * Classes which get instanciated in a different name
 	 *
@@ -62,12 +66,11 @@
 		'log' => 'errorlog',
 		'link' => 'bolink',		// depricated use static egw_link methods
 		'datetime' => 'egw_datetime',
-		'template' => 'Template',
-		'session' => 'egw_session',	// otherwise $GLOBALS['egw']->session->appsession() fails
 		// classes moved to new api dir
+		'template' => true,
+		'applications' => 'EGroupware\\Api\\Egw\\Applications',
 		'framework' => true,	// special handling in __get()
 		'ldap' => true,
-		'auth' => 'EGroupware\\Api\\Auth',
 	);
 
 	/**
@@ -99,7 +102,7 @@
 			return $this->$name;
 		}
 
-		if (!isset(self::$sub_objects[$name]) && !class_exists($name))
+		if (!isset(self::$sub_objects[$name]) && !class_exists('EGroupware\\Api\\'.ucfirst($name)) && !class_exists($name))
 		{
 			if ($name != 'ADOdb') error_log(__METHOD__.": There's NO $name object! ".function_backtrace());
 			return null;
@@ -117,7 +120,8 @@
 			case 'ldap':
 				return $this->ldap = Api\Ldap::factory(false);
 			default:
-				$class = isset(self::$sub_objects[$name]) ? self::$sub_objects[$name] : $name;
+				$class = isset(self::$sub_objects[$name]) ? self::$sub_objects[$name] : 'EGroupware\\Api\\'.ucfirst($name);
+				if (!class_exists($class)) $class = $name;
 				break;
 		}
 		return $this->$name = new $class();

Modified: trunk/egroupware/api/src/Framework.php
URL: http://svn.stylite.de/viewvc/egroupware/trunk/egroupware/api/src/Framework.php?rev=55989&r1=55988&r2=55989&view=diff
==============================================================================
--- trunk/egroupware/api/src/Framework.php (original)
+++ trunk/egroupware/api/src/Framework.php Tue May  3 00:26:40 2016
@@ -100,29 +100,44 @@
 	 */
 	public static function factory()
 	{
-		if ((Header\UserAgent::mobile() || $GLOBALS['egw_info']['user']['preferences']['common']['theme'] == 'mobile') &&
-			file_exists(EGW_SERVER_ROOT.'/pixelegg'))
+		// we prefer Pixelegg template, if it is available
+		if (file_exists(EGW_SERVER_ROOT.'/pixelegg') &&
+			(Header\UserAgent::mobile() || $GLOBALS['egw_info']['user']['preferences']['common']['theme'] == 'mobile' ||
+			empty($GLOBALS['egw_info']['server']['template_set'])))
 		{
 			$GLOBALS['egw_info']['server']['template_set'] = 'pixelegg';
 		}
-		// default to idots, if no template_set set, to eg. not stall installations if settings use self::link
-		if (empty($GLOBALS['egw_info']['server']['template_set'])) $GLOBALS['egw_info']['server']['template_set'] = 'idots';
-		// setup the new eGW framework (template sets)
-		$class = $GLOBALS['egw_info']['server']['template_set'].'_framework';
-		if (!class_exists($class))	// first try to autoload the class
-		{
-			require_once($file=EGW_INCLUDE_ROOT.'/phpgwapi/templates/'.$GLOBALS['egw_info']['server']['template_set'].'/class.'.$class.'.inc.php');
-			if (!in_array($file,(array)$_SESSION['egw_required_files']))
-			{
-				$_SESSION['egw_required_files'][] = $file;	// automatic load the used framework class, when the object get's restored
-			}
-		}
-		// fall back to idots if a template does NOT support current user-agent
-		if ($class != 'idots_framework' && method_exists($class,'is_supported_user_agent') &&
-			!call_user_func(array($class,'is_supported_user_agent')))
-		{
-			$GLOBALS['egw_info']['server']['template_set'] = 'idots';
-			return self::factory();
+		// then jdots aka Stylite template
+		if (file_exists(EGW_SERVER_ROOT.'/jdots') && empty($GLOBALS['egw_info']['server']['template_set']))
+		{
+			$GLOBALS['egw_info']['server']['template_set'] = 'jdots';
+		}
+		// and last, if installed old phpgwapi idots etc.
+		if (file_exists(EGW_SERVER_ROOT.'/phpgwapi'))
+		{
+			// default to idots, if no template_set set, to eg. not stall installations if settings use self::link
+			if (empty($GLOBALS['egw_info']['server']['template_set'])) $GLOBALS['egw_info']['server']['template_set'] = 'idots';
+			// setup the new eGW framework (template sets)
+			$class = $GLOBALS['egw_info']['server']['template_set'].'_framework';
+			if (!class_exists($class))	// first try to autoload the class
+			{
+				require_once($file=EGW_INCLUDE_ROOT.'/phpgwapi/templates/'.$GLOBALS['egw_info']['server']['template_set'].'/class.'.$class.'.inc.php');
+				if (!in_array($file,(array)$_SESSION['egw_required_files']))
+				{
+					$_SESSION['egw_required_files'][] = $file;	// automatic load the used framework class, when the object get's restored
+				}
+			}
+			// fall back to idots if a template does NOT support current user-agent
+			if ($class != 'idots_framework' && method_exists($class,'is_supported_user_agent') &&
+				!call_user_func(array($class,'is_supported_user_agent')))
+			{
+				$GLOBALS['egw_info']['server']['template_set'] = 'idots';
+				return self::factory();
+			}
+		}
+		else
+		{
+			$class = $GLOBALS['egw_info']['server']['template_set'].'_framework';
 		}
 		return new $class($GLOBALS['egw_info']['server']['template_set']);
 	}
@@ -982,28 +997,30 @@
 	static function list_templates($full_data=false)
 	{
 		$list = array('pixelegg'=>null,'jdots'=>null,'idots'=>null);
-		// templates packaged in the api
-		$d = dir(EGW_SERVER_ROOT . '/phpgwapi/templates');
-		while (($entry=$d->read()))
-		{
-			if ($entry != '..' && file_exists(EGW_SERVER_ROOT . '/phpgwapi/templates/' . $entry .'/class.'.$entry.'_framework.inc.php'))
-			{
-				if (file_exists ($f = EGW_SERVER_ROOT . '/phpgwapi/templates/' . $entry . '/setup/setup.inc.php'))
+		// templates packaged in old phpgwapi
+		if (file_exists(EGW_SERVER_ROOT . '/phpgwapi') && ($d = dir(EGW_SERVER_ROOT . '/phpgwapi/templates')))
+		{
+			while (($entry=$d->read()))
+			{
+				if ($entry != '..' && file_exists(EGW_SERVER_ROOT . '/phpgwapi/templates/' . $entry .'/class.'.$entry.'_framework.inc.php'))
 				{
-					include($f);
-					$list[$entry] = $full_data ? $GLOBALS['egw_info']['template'][$entry] :
-						$GLOBALS['egw_info']['template'][$entry]['title'];
+					if (file_exists ($f = EGW_SERVER_ROOT . '/phpgwapi/templates/' . $entry . '/setup/setup.inc.php'))
+					{
+						include($f);
+						$list[$entry] = $full_data ? $GLOBALS['egw_info']['template'][$entry] :
+							$GLOBALS['egw_info']['template'][$entry]['title'];
+					}
+					else
+					{
+						$list[$entry] = $full_data ? array(
+							'name'  => $entry,
+							'title' => $entry,
+						) : $entry;
+					}
 				}
-				else
-				{
-					$list[$entry] = $full_data ? array(
-						'name'  => $entry,
-						'title' => $entry,
-					) : $entry;
-				}
-			}
-		}
-		$d->close();
+			}
+			$d->close();
+		}
 		// templates packaged like apps in own directories (containing as setup/setup.inc.php file!)
 		$dr = dir(EGW_SERVER_ROOT);
 		while (($entry=$dr->read()))

Modified: trunk/egroupware/api/templates/default/default.css
URL: http://svn.stylite.de/viewvc/egroupware/trunk/egroupware/api/templates/default/default.css?rev=55989&r1=55988&r2=55989&view=diff
==============================================================================
--- trunk/egroupware/api/templates/default/default.css (original)
+++ trunk/egroupware/api/templates/default/default.css Tue May  3 00:26:40 2016
@@ -108,7 +108,7 @@
 
 body
 {
-	background-image:url(../images/body-background.png);
+	background-image:url(images/body-background.png);
 }
 
 form
@@ -191,7 +191,7 @@
 
 #sideresize
 {
-	background-image:url(../images/resize.png);
+	background-image:url(images/resize.png);
 	width:13px;
 	height:13px;
 	right:1px;
@@ -306,7 +306,7 @@
 #topmenu
 {
 	background-color: #0081c1;
-	background-image: url(../images/bgtopmenu2.png);
+	background-image: url(images/bgtopmenu2.png);
 	color:#006699;
 	/*border-top: solid 1px #7e7e7e;*/
 	border-bottom: solid #5793ff 1px;
@@ -373,7 +373,7 @@
 {
 	background-color:silver;
 	border:solid 1px #9c9c9c;
-	background-image: url(../images/background-icon-bar.png);
+	background-image: url(images/background-icon-bar.png);
 	background-repeat: repeat-x;
 	overflow:visible;
 	height: 45px; /* prevents text line to show in IE7+8(Compatibilitymode) */
@@ -412,7 +412,7 @@
 
 #divAppboxHeader
 {
-	background-image:url(../images/appbox-header-background.png);
+	background-image:url(images/appbox-header-background.png);
 	background-repeat: repeat-x;
 	height: 25px;
 	border-bottom:solid 1px #c0c0c0;
@@ -515,7 +515,7 @@
 }
 
 #egwpopup_header {
-	background-image: url(../images/gradient22.png);
+	background-image: url(images/gradient22.png);
 	height: 18px;
 	line-height: 18px;
 	margin: 0;
@@ -834,7 +834,7 @@
 }
 td.lettersearch {
 	border-color: #E0E0E0;
-	background-image: url(../images/gradient22.png);
+	background-image: url(images/gradient22.png);
 }
 
 .nextmatch_header tr {
@@ -900,11 +900,11 @@
 }
 
 .egwGridView_outer span.sort.asc {
-	background-image: url(../images/up.png);
+	background-image: url(images/up.png);
 }
 
 .egwGridView_outer span.sort.desc {
-	background-image: url(../images/down.png);
+	background-image: url(images/down.png);
 }
 
 .egwGridView_grid input[type=checkbox],

Copied: trunk/egroupware/api/templates/default/idots.css (from r55978, trunk/phpgwapi/templates/idots/css/idots.css)
URL: http://svn.stylite.de/viewvc/egroupware/trunk/egroupware/api/templates/default/idots.css?p2=trunk/egroupware/api/templates/default/idots.css&p1=trunk/phpgwapi/templates/idots/css/idots.css&r1=55978&r2=55989&rev=55989&view=diff
==============================================================================
--- trunk/phpgwapi/templates/idots/css/idots.css (original)
+++ trunk/egroupware/api/templates/default/idots.css Tue May  3 00:26:40 2016
@@ -8,7 +8,7 @@
 	border: none;
 	background-position: 0px 30px;
 	background-color: white;
-	background-image: url(../images/gradient22.png);
+	background-image: url(images/gradient22.png);
 }
 
 #divStatusBar {
@@ -16,7 +16,7 @@
 }
 
 #divAppboxHeader {
-	background-image: url(../images/gradient22.png);
+	background-image: url(images/gradient22.png);
 	border: none;
 	height: 18px;
 	line-height: 18px;
@@ -48,7 +48,7 @@
 	width:auto;
 }
 .divSideboxHeader {
-	background-image: url(../images/gradient22.png);
+	background-image: url(images/gradient22.png);
 	border: none;
 	height: 18px;
 	line-height: 18px;
@@ -83,7 +83,7 @@
 }
 
 #topmenu {
-	background-image: url(../images/gradient22.png);
+	background-image: url(images/gradient22.png);
 	border: none;
 	x-background-color: #e0e0e0;
 	x-background-image: none;
@@ -99,7 +99,7 @@
 }
 
 #sideresize {
-	background-image:url(../images/resize-transparent.png);
+	background-image:url(images/resize-transparent.png);
 }
 
 .th {
@@ -140,7 +140,7 @@
 	padding-left: 8px;
 }
 .divLoginboxHeader {
-	background-image: url(../images/gradient22.png);
+	background-image: url(images/gradient22.png);
 }
 #menu1Container{
 	position: absolute;

Modified: trunk/egroupware/login.php
URL: http://svn.stylite.de/viewvc/egroupware/trunk/egroupware/login.php?rev=55989&r1=55988&r2=55989&view=diff
==============================================================================
--- trunk/egroupware/login.php (original)
+++ trunk/egroupware/login.php Tue May  3 00:26:40 2016
@@ -1,6 +1,6 @@
 <?php
 /**
- * eGroupWare - Login
+ * EGroupware - Login
  *
  * @link http://www.egroupware.org
  * @author Dan Kuykendall <[email protected]>
@@ -11,6 +11,10 @@
  * @version $Id$
  */
 
+use EGroupware\Api;
+use EGroupware\Api\Framework;
+use EGroupware\Api\Egw;
+
 $submit = False;			// set to some initial value
 
 $GLOBALS['egw_info'] = array('flags' => array(
@@ -42,7 +46,7 @@
 {
 	if($GLOBALS['egw']->session->verify())
 	{
-		$GLOBALS['egw']->hooks->process('logout');
+		Api\Hooks::process('logout');
 		$GLOBALS['egw']->session->destroy($GLOBALS['sessionid'],$GLOBALS['kp3']);
 	}
 }
@@ -101,8 +105,8 @@
 else
 {
 	// allow template to overide login-template (without modifying header.inc.php) by setting default or forced pref
-	$prefs = new preferences();
-	$prefs->account_id = preferences::DEFAULT_ID;
+	$prefs = new Api\Preferences();
+	$prefs->account_id = Api\Preferences::DEFAULT_ID;
 	$prefs->read_repository();
 
 	$class = $prefs->data['common']['template_set'].'_framework';
@@ -113,7 +117,7 @@
 	}
 	unset($prefs); unset($class);
 
-	$GLOBALS['egw']->framework = egw_framework::factory();
+	$GLOBALS['egw']->framework = Framework::factory();
 
 	// This is used for system downtime, to prevent new logins.
 	if($GLOBALS['egw_info']['server']['deny_all_logins'])
@@ -132,13 +136,13 @@
 				return lang('Sorry, your login has expired');
 			case 4:
 				return lang('Cookies are required to login to this site');
-			case egw_session::CD_BAD_LOGIN_OR_PASSWORD:
+			case Api\Session::CD_BAD_LOGIN_OR_PASSWORD:
 				return lang('Bad login or password');
-			case egw_session::CD_FORCE_PASSWORD_CHANGE:
+			case Api\Session::CD_FORCE_PASSWORD_CHANGE:
 				return lang('You must change your password!');
-			case egw_session::CD_ACCOUNT_EXPIRED:
+			case Api\Session::CD_ACCOUNT_EXPIRED:
 				return lang('Account is expired');
-			case egw_session::CD_BLOCKED:
+			case Api\Session::CD_BLOCKED:
 				return lang('Blocked, too many attempts');
 			case 10:
 				$GLOBALS['egw']->session->egw_setcookie('sessionid');
@@ -233,12 +237,12 @@
 			!isset($_SERVER['PHP_AUTH_USER']) && !isset($_SERVER['SSL_CLIENT_S_DN']))
 		{
 			$GLOBALS['egw']->session->egw_setcookie('eGW_remember','',0,'/');
-			egw::redirect_link('/login.php','cd=5');
+			Egw::redirect_link('/login.php','cd=5');
 		}
 		/* cookie enabled check comment out, as it seems to cause a redirect loop under certain conditions and browsers :-(
 		if ($_COOKIE['eGW_cookie_test'] !== 'enabled')
 		{
-			egw::redirect_link('/login.php','cd=4');
+			Egw::redirect_link('/login.php','cd=4');
 		}*/
 
 		// don't get login data again when $submit is true
@@ -277,7 +281,7 @@
 		$GLOBALS['sessionid'] = $GLOBALS['egw']->session->create($login, $passwd,
 			$passwd_type, false, true, true);	// true = let session fail on forced password change
 
-		if (!$GLOBALS['sessionid'] && $GLOBALS['egw']->session->cd_reason == egw_session::CD_FORCE_PASSWORD_CHANGE)
+		if (!$GLOBALS['sessionid'] && $GLOBALS['egw']->session->cd_reason == Api\Session::CD_FORCE_PASSWORD_CHANGE)
 		{
 			if (isset($_POST['new_passwd']))
 			{
@@ -301,8 +305,8 @@
 		}
 		elseif (!isset($GLOBALS['sessionid']) || ! $GLOBALS['sessionid'])
 		{
-			$GLOBALS['egw']->session->egw_setcookie('eGW_remember','',0,'/');
-			egw::redirect_link('/login.php?cd=' . $GLOBALS['egw']->session->cd_reason);
+			Api\Session::egw_setcookie('eGW_remember','',0,'/');
+			Egw::redirect_link('/login.php?cd=' . $GLOBALS['egw']->session->cd_reason);
 		}
 		else
 		{
@@ -342,7 +346,7 @@
 			}
 
 			// check if new translations are available
-			translation::check_invalidate_cache();
+			Api\Translation::check_invalidate_cache();
 
 			$forward = isset($_GET['phpgw_forward']) ? urldecode($_GET['phpgw_forward']) : @$_POST['phpgw_forward'];
 			if (!$forward)
@@ -359,7 +363,7 @@
 			if(strpos($_SERVER['HTTP_REFERER'], $_SERVER['REQUEST_URI']) === false) {
 				// login requuest does not come from login.php
 				// redirect to referer on logout
-				$GLOBALS['egw']->session->appsession('referer', 'login', $_SERVER['HTTP_REFERER']);
+				Api\Cache::setSession('login', 'referer', $_SERVER['HTTP_REFERER']);
 			}
 			$strength = ($GLOBALS['egw_info']['server']['force_pwd_strength']?$GLOBALS['egw_info']['server']['force_pwd_strength']:false);
 			if ($strength && $strength>5) $strength =5;
@@ -370,7 +374,7 @@
 			{
 				error_log('login::'.__LINE__.' User '. $login. ' authenticated with an unsave password'.' '.$unsave_msg);
 				$message = lang('eGroupWare checked your password for safetyness. You have to change your password for the following reason:')."\n";
-				egw::redirect_link('/index.php', array(
+				Egw::redirect_link('/index.php', array(
 					'menuaction' => 'preferences.uipassword.change',
 					'message' => $message . $unsave_msg,
 					'cd' => 'yes',
@@ -380,14 +384,14 @@
 			{
 				// commiting the session, before redirecting might fix racecondition in session creation
 				$GLOBALS['egw']->session->commit_session();
-				egw::redirect_link($forward,$extra_vars);
+				Egw::redirect_link($forward,$extra_vars);
 			}
 		}
 	}
 	// show login screen
 	if(isset($_COOKIE['last_loginid']))
 	{
-		$prefs = new preferences($GLOBALS['egw']->accounts->name2id($_COOKIE['last_loginid']));
+		$prefs = new Api\Preferences($GLOBALS['egw']->accounts->name2id($_COOKIE['last_loginid']));
 
 		if($prefs->account_id)
 		{
@@ -411,17 +415,17 @@
 	}
 	if ($_COOKIE['eGW_cookie_test'] !== 'enabled')
 	{
-		egw_session::egw_setcookie('eGW_cookie_test','enabled',0);
+		Api\Session::egw_setcookie('eGW_cookie_test','enabled',0);
 	}
 	#print 'LANG:' . $GLOBALS['egw_info']['user']['preferences']['common']['lang'] . '<br>';
-	translation::init();	// this will set the language according to the (new) set prefs
-	translation::add_app('login');
-	translation::add_app('loginscreen');
-	$GLOBALS['loginscreenmessage'] = translation::translate('loginscreen_message',false,'');
+	Api\Translation::init();	// this will set the language according to the (new) set prefs
+	Api\Translation::add_app('login');
+	Api\Translation::add_app('loginscreen');
+	$GLOBALS['loginscreenmessage'] = Api\Translation::translate('loginscreen_message',false,'');
 	if($GLOBALS['loginscreenmessage'] == 'loginscreen_message' || empty($GLOBALS['loginscreenmessage']))
 	{
-		translation::add_app('loginscreen','en');	// trying the en one
-		$GLOBALS['loginscreenmessage'] = translation::translate('loginscreen_message',false,'');
+		Api\Translation::add_app('loginscreen','en');	// trying the en one
+		$GLOBALS['loginscreenmessage'] = Api\Translation::translate('loginscreen_message',false,'');
 	}
 	if($GLOBALS['loginscreenmessage'] == 'loginscreen_message' || empty($GLOBALS['loginscreenmessage']))
 	{

Modified: trunk/egroupware/logout.php
URL: http://svn.stylite.de/viewvc/egroupware/trunk/egroupware/logout.php?rev=55989&r1=55988&r2=55989&view=diff
==============================================================================
--- trunk/egroupware/logout.php (original)
+++ trunk/egroupware/logout.php Tue May  3 00:26:40 2016
@@ -1,6 +1,6 @@
 <?php
 /**
- * eGroupWare - Logout
+ * EGroupware - Logout
  *
  * @link http://www.egroupware.org
  * @author Joseph Engo <[email protected]>
@@ -9,6 +9,8 @@
  * @subpackage authentication
  * @version $Id$
  */
+
+use EGroupware\Api;
 
 $GLOBALS['egw_info'] = array(
 	'flags' => array(
@@ -21,12 +23,12 @@
 );
 include('./header.inc.php');
 
-$GLOBALS['sessionid'] = egw_session::get_sessionid();
-$GLOBALS['kp3']       = egw_session::get_request('kp3');
+$GLOBALS['sessionid'] = Api\Session::get_sessionid();
+$GLOBALS['kp3']       = Api\Session::get_request('kp3');
 
 $verified = $GLOBALS['egw']->session->verify();
 
-if(!($redirectTarget = $GLOBALS['egw']->session->appsession('referer', 'login')))
+if(!($redirectTarget = Api\Cache::getSession('login', 'referer')))
 {
 	$redirectTarget = $GLOBALS['egw_info']['server']['webserver_url'].'/login.php?cd=1&domain='.$GLOBALS['egw_info']['user']['domain'];
 }
@@ -37,14 +39,14 @@
 
 if($verified)
 {
-	$GLOBALS['egw']->hooks->process('logout');
+	Api\Hooks::process('logout');
 	$GLOBALS['egw']->session->destroy($GLOBALS['sessionid'],$GLOBALS['kp3']);
 }
 
-$GLOBALS['egw']->session->egw_setcookie('eGW_remember','',0,'/');
-$GLOBALS['egw']->session->egw_setcookie('sessionid');
-$GLOBALS['egw']->session->egw_setcookie('kp3');
-$GLOBALS['egw']->session->egw_setcookie('domain');
+Api\Session::egw_setcookie('eGW_remember','',0,'/');
+Api\Session::egw_setcookie('sessionid');
+Api\Session::egw_setcookie('kp3');
+Api\Session::egw_setcookie('domain');
 
 if($GLOBALS['egw_info']['server']['auth_type'] == 'cas')
 {

Modified: trunk/setup/admin_account.php
URL: http://svn.stylite.de/viewvc/egroupware/trunk/setup/admin_account.php?rev=55989&r1=55988&r2=55989&view=diff
==============================================================================
--- trunk/setup/admin_account.php (original)
+++ trunk/setup/admin_account.php Tue May  3 00:26:40 2016
@@ -19,7 +19,7 @@
 
 	// Authorize the user to use setup app and load the database
 	// Does not return unless user is authorized
-	if(!$GLOBALS['egw_setup']->auth('Config') || get_var('cancel',Array('POST')))
+	if(!$GLOBALS['egw_setup']->auth('Config') || $_POST['cancel'])
 	{
 		Header('Location: index.php');
 		exit;
@@ -36,12 +36,12 @@
 	}
 
 	/* Posted admin data */
-	$passwd   = get_var('passwd',Array('POST'));
-	$passwd2  = get_var('passwd2',Array('POST'));
-	$username = get_var('username',Array('POST'));
-	$fname    = get_var('fname',Array('POST'));
-	$lname    = get_var('lname',Array('POST'));
-	$email    = get_var('email',Array('POST'));
+	$passwd   = $_POST['passwd'];
+	$passwd2  = $_POST['passwd2'];
+	$username = $_POST['username'];
+	$fname    = $_POST['fname'];
+	$lname    = $_POST['lname'];
+	$email    = $_POST['email'];
 
 	if($passwd != $passwd2 || !$username)
 	{
@@ -153,7 +153,7 @@
 	$GLOBALS['egw_setup']->add_acl($apps,'run',$admingroupid);
 
 	/* Creation of the demo accounts is optional - the checkbox is on by default. */
-	if(get_var('create_demo',Array('POST')))
+	if($_POST['create_demo'])
 	{
 		// Create 3 demo accounts
 		$GLOBALS['egw_setup']->add_account('demo','Demo','Account','guest');

Modified: trunk/setup/applications.php
URL: http://svn.stylite.de/viewvc/egroupware/trunk/setup/applications.php?rev=55989&r1=55988&r2=55989&view=diff
==============================================================================
--- trunk/setup/applications.php (original)
+++ trunk/setup/applications.php Tue May  3 00:26:40 2016
@@ -106,22 +106,22 @@
 
 @ksort($setup_info);
 
-if(@get_var('cancel',Array('POST')))
+if(@$_POST['cancel'])
 {
 	Header("Location: index.php");
 	exit;
 }
 
-if(@get_var('submit',Array('POST')))
+if(@$_POST['submit'])
 {
 	$GLOBALS['egw_setup']->html->show_header(lang('Application Management'),False,'config',$GLOBALS['egw_setup']->ConfigDomain . '(' . $GLOBALS['egw_domain'][$GLOBALS['egw_setup']->ConfigDomain]['db_type'] . ')');
 	$setup_tpl->set_var('description',lang('App install/remove/upgrade') . ':');
 	$setup_tpl->pparse('out','header');
 
-	$appname = get_var('appname',Array('POST'));
-	$remove  = get_var('remove',Array('POST'));
-	$install = get_var('install',Array('POST'));
-	$upgrade = get_var('upgrade',Array('POST'));
+	$appname = $_POST['appname'];
+	$remove  = $_POST['remove'];
+	$install = $_POST['install'];
+	$upgrade = $_POST['upgrade'];
 
 	$register_hooks = false;
 
@@ -235,14 +235,14 @@
 	$GLOBALS['egw_setup']->html->show_header(lang('Application Management'),False,'config',$GLOBALS['egw_setup']->ConfigDomain . '(' . $GLOBALS['egw_domain'][$GLOBALS['egw_setup']->ConfigDomain]['db_type'] . ')');
 }
 
-if(@get_var('hooks', Array('GET')))
+if(@$_GET['hooks'])
 {
 	Api\Cache::flush(Api\Cache::INSTANCE);
 
 	echo lang('Cached cleared') . '<br />';
 }
-$detail = get_var('detail',Array('GET'));
-$resolve = get_var('resolve',Array('GET'));
+$detail = $_GET['detail'];
+$resolve = $_GET['resolve'];
 if(@$detail)
 {
 	@ksort($setup_info[$detail]);
@@ -300,13 +300,13 @@
 }
 elseif (@$resolve)
 {
-	$version  = get_var('version',Array('GET'));
-	$notables = get_var('notables',Array('GET'));
+	$version  = $_GET['version'];
+	$notables = $_GET['notables'];
 	$setup_tpl->set_var('description',lang('Problem resolution'). ':');
 	$setup_tpl->pparse('out','header');
 	$app_title = $setup_info[$resolve]['title'] ? $setup_info[$resolve]['title'] : $setup_info[$resolve]['name'];
 
-	if(get_var('post',Array('GET')))
+	if($_GET['post'])
 	{
 		echo '"' . $app_title . '" ' . lang('may be broken') . ' ';
 		echo lang('because an application it depends upon was upgraded');
@@ -315,7 +315,7 @@
 		echo '<br />';
 		echo lang('However, the application may still work') . '.';
 	}
-	elseif(get_var('badinstall',Array('GET')))
+	elseif($_GET['badinstall'])
 	{
 		echo '"' . $app_title . '" ' . lang('is broken') . ' ';
 		echo lang('because of a failed upgrade or install') . '.';
@@ -324,7 +324,7 @@
 		echo '<br />';
 		echo lang('You should either uninstall and then reinstall it, or attempt manual repairs') . '.';
 	}
-	elseif(get_var('deleted',Array('GET')))
+	elseif($_GET['deleted'])
 	{
 		echo '"' . $app_title . '" ' . lang('is broken') . ' ';
 		echo lang('because its sources are missing') . '!';

Modified: trunk/setup/check_install.php
URL: http://svn.stylite.de/viewvc/egroupware/trunk/setup/check_install.php?rev=55989&r1=55988&r2=55989&view=diff
==============================================================================
--- trunk/setup/check_install.php (original)
+++ trunk/setup/check_install.php Tue May  3 00:26:40 2016
@@ -9,6 +9,9 @@
  * @license http://opensource.org/licenses/gpl-license.php GPL - GNU General Public License
  * @version $Id$
  */
+
+use EGroupware\Api;
+
 $run_by_webserver = !!$_SERVER['PHP_SELF'];
 $is_windows = strtoupper(substr(PHP_OS,0,3)) == 'WIN';
 
@@ -839,12 +842,12 @@
 if ($run_by_webserver)
 {
 	$tpl_root = $GLOBALS['egw_setup']->html->setup_tpl_dir('setup');
-	$setup_tpl = CreateObject('phpgwapi.Template',$tpl_root);
+	$setup_tpl = new Api\Framework\Template($tpl_root);
 	$setup_tpl->set_file(array(
 		'T_head' => 'head.tpl',
 		'T_footer' => 'footer.tpl',
 	));
-	$ConfigDomain = get_var('ConfigDomain',Array('POST','COOKIE'));
+	$ConfigDomain = $_REQUEST['ConfigDomain'];
 	if (@$_GET['intro']) {
 		if(($ConfigLang = setup::get_lang()))
 		{

Modified: trunk/setup/config.php
URL: http://svn.stylite.de/viewvc/egroupware/trunk/setup/config.php?rev=55989&r1=55988&r2=55989&view=diff
==============================================================================
--- trunk/setup/config.php (original)
+++ trunk/setup/config.php Tue May  3 00:26:40 2016
@@ -55,13 +55,12 @@
 
 $newsettings = $_POST['newsettings'];
 
-if(@get_var('submit',Array('POST')) && @$newsettings)
+if(@$_POST['submit'] && @$newsettings)
 {
 	/* Load hook file with functions to validate each config (one/none/all) */
 	$GLOBALS['egw_setup']->hook('config_validate','setup');
 
 	$newsettings['tz_offset'] = date('Z')/3600;
-	print_debug('TZ_OFFSET',$newsettings['tz_offset']);
 
 	$GLOBALS['egw_setup']->db->transaction_begin();
 	foreach($newsettings as $setting => $value)

Modified: trunk/setup/inc/class.setup.inc.php
URL: http://svn.stylite.de/viewvc/egroupware/trunk/setup/inc/class.setup.inc.php?rev=55989&r1=55988&r2=55989&view=diff
==============================================================================
--- trunk/setup/inc/class.setup.inc.php (original)
+++ trunk/setup/inc/class.setup.inc.php Tue May  3 00:26:40 2016
@@ -99,7 +99,7 @@
 	{
 		if(!isset($this->ConfigDomain) || empty($this->ConfigDomain))
 		{
-			$this->ConfigDomain = get_var('ConfigDomain',array('COOKIE','POST'),$_POST['FormDomain']);
+			$this->ConfigDomain = isset($_REQUEST['ConfigDomain']) ? $_REQUEST['ConfigDomain'] : $_POST['FormDomain'];
 		}
 		$GLOBALS['egw_info']['server']['db_type'] = $GLOBALS['egw_domain'][$this->ConfigDomain]['db_type'];
 
@@ -668,9 +668,10 @@
 			return false;	// app not found or no hook
 		}
 		$GLOBALS['settings'] = array();
+		$hook_data = array('location' => 'settings','setup' => true);
 		if (isset($setup_info['hooks']['settings']))
 		{
-			$settings = ExecMethod($setup_info['hooks']['settings'],array('location' => 'settings','setup' => true));
+			$settings = ExecMethod($setup_info['hooks']['settings'],$hook_data);
 		}
 		elseif(in_array('settings',$setup_info['hooks']) && file_exists($file = EGW_INCLUDE_ROOT.'/'.$appname.'/inc/hook_settings.inc.php'))
 		{
@@ -685,7 +686,9 @@
 			return false;
 		}
 		// include idots template prefs for (common) preferences
-		if ($appname == 'preferences' && file_exists($file = EGW_INCLUDE_ROOT.'/phpgwapi/templates/idots/hook_settings.inc.php'))
+		if ($appname == 'preferences' && (file_exists($file = EGW_INCLUDE_ROOT.'/pixelegg/hook_settings.inc.php') ||
+			file_exists($file = EGW_INCLUDE_ROOT.'/jdots/hook_settings.inc.php') ||
+			file_exists($file = EGW_INCLUDE_ROOT.'/phpgwapi/templates/idots/hook_settings.inc.php')))
 		{
 			$GLOBALS['settings'] = array();
 			include_once($file);
@@ -1073,10 +1076,24 @@
 		$this->accounts->search(array(
 			'type'   => 'accounts',
 			'start'  => 0,
-			'offset' => 2	// we only need to check 2 Api\Accounts, if we just check for not anonymous
+			'offset' => 2	// we only need to check 2 accounts, if we just check for not anonymous
 		));
 
-		return $this->accounts->total > 1;
+		if ($this->accounts->total != 1)
+		{
+			return $this->accounts->total > 1;
+		}
+
+		// one account, need to check it's not the anonymous one
+		$this->accounts->search(array(
+			'type'   => 'accounts',
+			'start'  => 0,
+			'offset' => 0,
+			'query_type' => 'lid',
+			'query'  => 'anonymous',
+		));
+
+		return !$this->accounts->total;
 	}
 
 	/**

Modified: trunk/setup/inc/class.setup_cmd_config.inc.php
URL: http://svn.stylite.de/viewvc/egroupware/trunk/setup/inc/class.setup_cmd_config.inc.php?rev=55989&r1=55988&r2=55989&view=diff
==============================================================================
--- trunk/setup/inc/class.setup_cmd_config.inc.php (original)
+++ trunk/setup/inc/class.setup_cmd_config.inc.php Tue May  3 00:26:40 2016
@@ -451,13 +451,13 @@
 		if (!$scan_done++)
 		{
 			// now add auth backends found in filesystem
-			foreach(scandir(EGW_INCLUDE_ROOT.'/phpgwapi/inc') as $class)
+			foreach(scandir(EGW_INCLUDE_ROOT.'/api/src/Auth') as $file)
 			{
 				$matches = null;
-				if (preg_match('/^class\.auth_([a-z]+)\.inc\.php$/', $class, $matches) &&
-					!isset($auth_types[$matches[1]]))
-				{
-					$auth_types[$matches[1]] = ucfirst($matches[1]);
+				if (preg_match('/^([a-z0-9]+)\.php$/', $file, $matches) &&
+					!isset($auth_types[strtolower($matches[1])]) && $matches[1] != 'Backend')
+				{
+					$auth_types[strtolower($matches[1])] = $matches[1];
 				}
 			}
 			foreach(self::$options['--account-auth'] as &$param)
@@ -489,15 +489,15 @@
 		if (!$scan_done++)
 		{
 			// now add auth backends found in filesystem
-			foreach(scandir(EGW_INCLUDE_ROOT.'/phpgwapi/inc') as $file)
+			foreach(scandir(EGW_INCLUDE_ROOT.'/api/src/Accounts') as $file)
 			{
 				$matches = null;
-				if (preg_match('/^class\.accounts_([a-z]+)\.inc\.php$/', $file, $matches) &&
-					!isset($account_repositories[$matches[1]]) &&
-					class_exists($class='accounts_'.$matches[1]) &&
-					($matches[1] == $current || !is_callable($callable=$class.'::available') || call_user_func($callable)))
-				{
-					$account_repositories[$matches[1]] = ucfirst($matches[1]);
+				if (preg_match('/^([a-z0-9]+)\.php$/', $file, $matches) &&
+					!isset($account_repositories[strtolower($matches[1])]) &&
+					class_exists($class='EGroupware\\Api\\Accounts\\'.$matches[1]) &&
+					(strtolower($matches[1]) == $current || !is_callable($callable=$class.'::available') || call_user_func($callable)))
+				{
+					$account_repositories[strtolower($matches[1])] = $matches[1];
 				}
 			}
 		}

Modified: trunk/setup/inc/class.setup_detection.inc.php
URL: http://svn.stylite.de/viewvc/egroupware/trunk/setup/inc/class.setup_detection.inc.php?rev=55989&r1=55988&r2=55989&view=diff
==============================================================================
--- trunk/setup/inc/class.setup_detection.inc.php (original)
+++ trunk/setup/inc/class.setup_detection.inc.php Tue May  3 00:26:40 2016
@@ -78,7 +78,11 @@
 					}
 					/* This is to catch old setup installs that did not have phpgwapi listed as an app */
 					$tmp = @$setup_info['phpgwapi']['version']; /* save the file version */
-					if(!@$setup_info['phpgwapi']['currentver'])
+					if (isset($setup_info['api']['version']))
+					{
+						// new api, dont care about old pre egroupware stuff
+					}
+					elseif(!@$setup_info['phpgwapi']['currentver'])
 					{
 						$setup_info['phpgwapi']['currentver'] = $setup_info['admin']['currentver'];
 						$setup_info['phpgwapi']['version'] = $setup_info['admin']['currentver'];

Modified: trunk/setup/inc/class.setup_html.inc.php
URL: http://svn.stylite.de/viewvc/egroupware/trunk/setup/inc/class.setup_html.inc.php?rev=55989&r1=55988&r2=55989&view=diff
==============================================================================
--- trunk/setup/inc/class.setup_html.inc.php (original)
+++ trunk/setup/inc/class.setup_html.inc.php Tue May  3 00:26:40 2016
@@ -31,8 +31,8 @@
 		$GLOBALS['header_template']->set_block('header','domain','domain');
 		$var = Array();
 
-		$deletedomain = get_var('deletedomain',Array('POST'));
-		$domains = get_var('domains',Array('POST'));
+		$deletedomain = $_POST['deletedomain'];
+		$domains = $_POST['domains'];
 
 		foreach($domains as $k => $v)
 		{
@@ -41,7 +41,7 @@
 				continue;
 			}
 			$variableName = str_replace('.','_',$k);
-			$dom = get_var('setting_'.$variableName,Array('POST'));
+			$dom = $_POST['setting_'.$variableName];
 			$GLOBALS['header_template']->set_var('DB_DOMAIN',$v);
 			foreach($dom as $x => $y)
 			{
@@ -72,7 +72,7 @@
 
 		$GLOBALS['header_template']->set_var('domain','');
 
-		$setting = get_var('setting',Array('POST'));
+		$setting = $_POST['setting'];
 		while($setting && list($k,$v) = @each($setting))
 		{
 			if(strtoupper($k) == 'HEADER_ADMIN_PASSWORD')
@@ -101,14 +101,14 @@
 		/* hack to get tpl dir */
 		if (is_dir(EGW_SERVER_ROOT))
 		{
-			$srv_root = EGW_SERVER_ROOT . SEP . "$app_name" . SEP;
+			$srv_root = EGW_SERVER_ROOT . '/' . $app_name . '/';
 		}
 		else
 		{
 			$srv_root = '';
 		}
 
-		$tpl_typical = 'templates' . SEP . 'default';
+		$tpl_typical = 'templates/default';
 		$tpl_root = "$srv_root" ."$tpl_typical";
 		return $tpl_root;
 	}
@@ -154,7 +154,7 @@
 		if(basename($_SERVER['SCRIPT_FILENAME']) != 'index.php')
 		{
 			$index_btn = '<a href="index.php" class="link">' . lang('Setup Main Menu') . '</a>';
-			$index_img = '<img src="../phpgwapi/templates/default/images/bullet.png" />';
+			$index_img = '<img src="../api/templates/default/images/bullet.png" />';
 		}
 
 		$GLOBALS['setup_tpl']->set_var('lang_version',lang('version'));

Modified: trunk/setup/inc/class.setup_process.inc.php
URL: http://svn.stylite.de/viewvc/egroupware/trunk/setup/inc/class.setup_process.inc.php?rev=55989&r1=55988&r2=55989&view=diff
==============================================================================
--- trunk/setup/inc/class.setup_process.inc.php (original)
+++ trunk/setup/inc/class.setup_process.inc.php Tue May  3 00:26:40 2016
@@ -87,12 +87,17 @@
 		else
 		{
 			$pass['api'] = $setup_info['api'];
-			$pass['phpgwapi'] = $setup_info['phpgwapi'];
+			if (file_exists(EGW_SERVER_ROOT.'/phpgwapi') && is_readable(EGW_SERVER_ROOT.'/phpgwapi'))
+			{
+				$pass['phpgwapi'] = $setup_info['phpgwapi'];
+			}
 		}
 		$pass['admin']    = $setup_info['admin'];
 		$pass['preferences'] = $setup_info['preferences'];
-		$pass['etemplate'] = $setup_info['etemplate'];	// helps to minimize passes, as many apps depend on it
-
+		if (file_exists(EGW_SERVER_ROOT.'/etemplate'))
+		{
+			$pass['etemplate'] = $setup_info['etemplate'];	// helps to minimize passes, as many apps depend on it
+		}
 		$this->api_version_target = $setup_info['api']['version'];
 
 		$i = 1;
@@ -132,9 +137,13 @@
 			switch($method)
 			{
 				case 'new':
+					if (empty($GLOBALS['egw_info']['server']['temp_dir']))
+					{
+						$GLOBALS['egw_info']['server']['temp_dir'] = sys_get_temp_dir();
+					}
 					/* Create tables and insert new records for each app in this list */
 					$passing_c = $this->current($pass,$DEBUG);
-					if (isset($pass['phpgwapi'])) $this->save_minimal_config($preset_config);
+					if (isset($pass['api'])) $this->save_minimal_config($preset_config);
 					$passing = $this->default_records($passing_c,$DEBUG);
 					break;
 				case 'upgrade':
@@ -292,7 +301,7 @@
 		}
 		$current_config['install_id'] = md5($_SERVER['HTTP_HOST'].microtime(true).$GLOBALS['egw_setup']->ConfigDomain);
 
-		$current_config['postpone_statistics_submit'] = time() + 2 * 30 * 3600;	// ask user in 2 month from now, when he has something to report
+		$current_config['postpone_statistics_submit'] = time() + 2 * 30 * 86400;	// ask user in 2 month from now, when he has something to report
 
 		// use securest password hash by default
 		require_once EGW_SERVER_ROOT.'/setup/inc/hook_config.inc.php';	// for sql_passwdhashes, to get securest available password hash
@@ -401,7 +410,7 @@
 
 			if($DEBUG) { echo '<br>process->current(): Incoming status: ' . $appname . ',status: '. $appdata['status']; }
 
-			$appdir  = EGW_SERVER_ROOT . SEP . $appname . SEP . 'setup' . SEP;
+			$appdir  = EGW_SERVER_ROOT . '/' . $appname . '/setup/';
 
 			if($appdata['tables'] && file_exists($appdir.'tables_current.inc.php'))
 			{
@@ -479,7 +488,7 @@
 		}
 		foreach($setup_info as $appname => &$appdata)
 		{
-			$appdir  = EGW_SERVER_ROOT . SEP . $appname . SEP . 'setup' . SEP;
+			$appdir  = EGW_SERVER_ROOT . '/' . $appname . '/setup/';
 
 			if(file_exists($appdir.'default_records.inc.php'))
 			{
@@ -520,7 +529,7 @@
 		}
 		foreach($setup_info as $appname => &$appdata)
 		{
-			$appdir  = EGW_SERVER_ROOT . SEP . $appname . SEP . 'setup' . SEP;
+			$appdir  = EGW_SERVER_ROOT . '/' . $appname . '/setup/';
 
 			if(file_exists($appdir.'test_data.inc.php'))
 			{
@@ -554,7 +563,7 @@
 		}
 		foreach($setup_info as $appname => &$appdata)
 		{
-			$appdir  = EGW_SERVER_ROOT . SEP . $appname . SEP . 'setup' . SEP;
+			$appdir  = EGW_SERVER_ROOT . '/' . $appname . '/setup/';
 
 			if(file_exists($appdir.'tables_baseline.inc.php'))
 			{
@@ -633,7 +642,7 @@
 			{
 				$currentver = $appdata['currentver'];
 				$targetver  = $appdata['version'];	// The version we need to match when done
-				$appdir     = EGW_SERVER_ROOT . SEP . $appname . SEP . 'setup' . SEP;
+				$appdir     = EGW_SERVER_ROOT . '/' . $appname . '/setup/';
 
 				if(file_exists($appdir . 'tables_update.inc.php'))
 				{

Modified: trunk/setup/index.php
URL: http://svn.stylite.de/viewvc/egroupware/trunk/setup/index.php?rev=55989&r1=55988&r2=55989&view=diff
==============================================================================
--- trunk/setup/index.php (original)
+++ trunk/setup/index.php Tue May  3 00:26:40 2016
@@ -490,7 +490,7 @@
 			}
 		}
 		// warn if essential apps are not installed
-		foreach(array('api','phpgwapi','etemplate','home','admin','preferences') as $app)
+		foreach(array('api','admin','preferences') as $app)
 		{
 			if (!isset($setup_info[$app]) || empty($setup_info[$app]['currentver']))
 			{

Modified: trunk/setup/manageheader.php
URL: http://svn.stylite.de/viewvc/egroupware/trunk/setup/manageheader.php?rev=55989&r1=55988&r2=55989&view=diff
==============================================================================
--- trunk/setup/manageheader.php (original)
+++ trunk/setup/manageheader.php Tue May  3 00:26:40 2016
@@ -218,7 +218,7 @@
 
 	$GLOBALS['egw_setup']->html->show_header($GLOBALS['egw_info']['setup']['HeaderFormMSG'], False, 'header');
 
-	if(!get_var('ConfigLang',array('POST','COOKIE')))
+	if(empty($_REQUEST['ConfigLang']))
 	{
 		$setup_tpl->set_var('lang_select','<tr><td colspan="2"><form action="manageheader.php" method="post">Please Select your language '.setup_html::lang_select(True,'en')."</form></td></tr>");
 	}

Modified: trunk/setup/schematoy.php
URL: http://svn.stylite.de/viewvc/egroupware/trunk/setup/schematoy.php?rev=55989&r1=55988&r2=55989&view=diff
==============================================================================
--- trunk/setup/schematoy.php (original)
+++ trunk/setup/schematoy.php Tue May  3 00:26:40 2016
@@ -99,7 +99,7 @@
 	//var_dump($GLOBALS['setup_info']);exit;
 	@ksort($GLOBALS['setup_info']);
 
-	if(get_var('cancel',Array('POST')))
+	if($_POST['cancel'])
 	{
 		Header('Location: index.php');
 		exit;
@@ -107,14 +107,14 @@
 
 	$GLOBALS['egw_setup']->html->show_header(lang("Developers' Table Schema Toy"),False,'config',$GLOBALS['egw_setup']->ConfigDomain);
 
-	if(get_var('submit',Array('POST')))
+	if($_POST['submit'])
 	{
 		$GLOBALS['setup_tpl']->set_var('description',lang('App process') . ':');
 		$GLOBALS['setup_tpl']->pparse('out','header');
 
-		$appname = get_var('appname','POST');
-		$install = get_var('install','POST');
-		$version = get_var('version','POST');
+		$appname = $_POST['appname'];
+		$install = $_POST['install'];
+		$version = $_POST['version'];
 
 		foreach($install as $appname => $key)
 		{
@@ -123,7 +123,7 @@
 			$terror[$appname]['version'] = $version[$appname];
 			$terror[$appname]['status'] = 'U';
 
-			$appdir  = EGW_SERVER_ROOT . SEP . $appname . SEP . 'setup' . SEP;
+			$appdir  = EGW_SERVER_ROOT . '/' . $appname . '/setup/';
 
 			// Drop newest tables
 			$terror[$appname]['tables'] = $GLOBALS['setup_info'][$appname]['tables'];
@@ -170,7 +170,7 @@
 		$GLOBALS['setup_tpl']->pparse('out','footer');
 		exit;
 	}
-	$detail = get_var('detail',Array('GET','POST'));
+	$detail = $_REQUEST['detail'];
 	if($detail)
 	{
 		@ksort($GLOBALS['setup_info'][$detail]);

Modified: trunk/setup/sqltoarray.php
URL: http://svn.stylite.de/viewvc/egroupware/trunk/setup/sqltoarray.php?rev=55989&r1=55988&r2=55989&view=diff
==============================================================================
--- trunk/setup/sqltoarray.php (original)
+++ trunk/setup/sqltoarray.php Tue May  3 00:26:40 2016
@@ -31,17 +31,17 @@
 $tpl_root = $GLOBALS['egw_setup']->html->setup_tpl_dir('setup');
 $setup_tpl = CreateObject('phpgwapi.Template',$tpl_root);
 
-$cancel   = get_var('cancel',Array('GET','POST'));
+$cancel   = $_REQUEST['cancel'];
 if($cancel)
 {
 	Header('Location: applications.php');
 	exit;
 }
-$apps     = get_var('apps',Array('GET','POST'));
-$download = get_var('download',Array('GET','POST'));
-$submit   = get_var('submit',Array('GET','POST'));
-$showall  = get_var('showall',Array('GET','POST'));
-$appname  = get_var('appname',Array('GET','POST'));
+$apps     = $_REQUEST['apps'];
+$download = $_REQUEST['download'];
+$submit   = $_REQUEST['submit'];
+$showall  = $_REQUEST['showall'];
+$appname  = $_REQUEST['appname'];
 if($download)
 {
 	$setup_tpl->set_file(array(
@@ -114,9 +114,9 @@
 
 function printout($template)
 {
-	$download = get_var('download',array('POST','GET'));
-	$appname  = get_var('appname',array('POST','GET'));
-	$showall  = get_var('showall',array('POST','GET'));
+	$download = $_REQUEST['download'];
+	$appname  = $_REQUEST['appname'];
+	$showall  = $_REQUEST['showall'];
 	$apps     = $GLOBALS['apps'] ? $GLOBALS['apps'] : '';
 
 	if($download)

Modified: trunk/setup/templates/default/head.tpl
URL: http://svn.stylite.de/viewvc/egroupware/trunk/setup/templates/default/head.tpl?rev=55989&r1=55988&r2=55989&view=diff
==============================================================================
--- trunk/setup/templates/default/head.tpl (original)
+++ trunk/setup/templates/default/head.tpl Tue May  3 00:26:40 2016
@@ -10,23 +10,16 @@
 		<meta name="language" content="{lang_code}" />
 		<meta name="author" content="egroupware http://www.egroupware.org" />
 		<meta name="robots" content="none" />
-		<link rel="icon" href="../phpgwapi/templates/default/images/favicon.ico" type="image/x-ico" />
-		<link rel="shortcut icon" href="../phpgwapi/templates/default/images/favicon.ico" />
-		<link href="../phpgwapi/templates/idots/css/traditional.css" type="text/css" rel="stylesheet" />
-		<link href="../phpgwapi/templates/idots/css/idots.css" type="text/css" rel="stylesheet" />
+		<link rel="icon" href="../api/templates/default/images/favicon.ico" type="image/x-ico" />
+		<link rel="shortcut icon" href="../api/templates/default/images/favicon.ico" />
+		<link href="../api/templates/default/default.css" type="text/css" rel="stylesheet" />
+		<link href="../api/templates/default/idots.css" type="text/css" rel="stylesheet" />
 
 		<!--{java_script}-->
-
-		<!-- this solves the internet explorer png-transparency bug, but only for ie 5.5 and 6.0 -->
-		<!--[if lt IE 7.0]>
-		<script src="../phpgwapi/templates/idots/js/pngfix.js" type=text/javascript>
-		</script>
-		<![endif]-->
-
 	</head>
 	<body>
 
-<div id="divLogo"><a href="http://www.egroupware.org" target="_blank"><img src="../phpgwapi/templates/default/images/logo.png" border="0" alt="egroupware" /></a></div>
+<div id="divLogo"><a href="http://www.egroupware.org" target="_blank"><img src="../api/templates/default/images/logo.png" border="0" alt="egroupware" /></a></div>
 
 <div id="divMain">
 	<div id="divAppIconBar">
@@ -36,7 +29,7 @@
 				<td>
 					<table width="100%" border="0" cellspacing="0" cellpadding="0">
 						<tr>
-							<td width="100%"><img src="../phpgwapi/templates/idots/images/spacer.gif" width="1" height="68" alt="spacer" /></td>
+							<td width="100%"><img src="templates/default/images/spacer.gif" width="1" height="68" alt="spacer" /></td>
 						</tr>
 						<tr>
 							<td width="100%">&nbsp;</td>
@@ -62,11 +55,11 @@
 							<table width="100%" cellspacing="0" cellpadding="0">
 
 								<tr class="divSideboxEntry">
-									<td width="20" align="center" valign="middle" class="textSidebox"><img src="../phpgwapi/templates/default/images/bullet.png" alt="ball" /></td><td class="textSidebox"><a class="textsidebox" href="../index.php">{user_login}</a></td>
+									<td width="20" align="center" valign="middle" class="textSidebox"><img src="../api/templates/default/images/bullet.png" alt="ball" /></td><td class="textSidebox"><a class="textsidebox" href="../index.php">{user_login}</a></td>
 								</tr>
 <!-- BEGIN loged_in -->
 								<tr class="divSideboxEntry">
-									<td width="20" align="center" valign="middle" class="textSidebox"><img src="../phpgwapi/templates/default/images/bullet.png" alt="ball" /></td><td class="textSidebox">{check_install}</td>
+									<td width="20" align="center" valign="middle" class="textSidebox"><img src="../api/templates/default/images/bullet.png" alt="ball" /></td><td class="textSidebox">{check_install}</td>
 								</tr>
 
 								<tr class="divSideboxEntry">
@@ -74,17 +67,17 @@
 								</tr>
 
 								<tr class="divSideboxEntry">
-									<td width="20" align="center" valign="middle" class="textSidebox"><img src="../phpgwapi/templates/default/images/bullet.png" alt="ball" /></td><td class="textSidebox">{register_hooks}</td>
+									<td width="20" align="center" valign="middle" class="textSidebox"><img src="../api/templates/default/images/bullet.png" alt="ball" /></td><td class="textSidebox">{register_hooks}</td>
 								</tr>
 								<tr class="divSideboxEntry">
-									<td width="20" align="center" valign="middle" class="textSidebox"><img src="../phpgwapi/templates/default/images/bullet.png" alt="ball" /></td><td class="textSidebox">{logoutbutton}</td>
+									<td width="20" align="center" valign="middle" class="textSidebox"><img src="../api/templates/default/images/bullet.png" alt="ball" /></td><td class="textSidebox">{logoutbutton}</td>
 								</tr>
 <!-- END loged_in -->
 								<tr class="divSideboxEntry">
 									<td colspan="2" class="textSidebox">&nbsp;</td>
 								</tr>
 								<tr class="divSideboxEntry">
-									<td width="20" align="center" valign="middle" class="textSidebox"><img src="../phpgwapi/templates/default/images/bullet.png" alt="ball" /></td><td class="textSidebox">{manual}</td>
+									<td width="20" align="center" valign="middle" class="textSidebox"><img src="../api/templates/default/images/bullet.png" alt="ball" /></td><td class="textSidebox">{manual}</td>
 								</tr>
 							</table>
 						</div>

Modified: trunk/setup/templates/default/manageheader.tpl
URL: http://svn.stylite.de/viewvc/egroupware/trunk/setup/templates/default/manageheader.tpl?rev=55989&r1=55988&r2=55989&view=diff
==============================================================================
--- trunk/setup/templates/default/manageheader.tpl (original)
+++ trunk/setup/templates/default/manageheader.tpl Tue May  3 00:26:40 2016
@@ -60,14 +60,6 @@
 				<td>{lang_persistdescr}</td>
 			</tr>
 			<tr class="row_off">
-				<td><strong>{lang_session}</strong><br />
-					<select name="setting[session_handler]">
-						{session_options}
-					</select>
-				</td>
-				<td>{lang_session_descr}</td>
-			</tr>
-			<tr class="row_on">
 				<td><strong>{lang_enablemcrypt}</strong><br />
 					<select name="setting[mcrypt_enabled]">
 						<option value="True"{mcrypt_enabled_yes}>{lang_Yes}</option>
@@ -76,11 +68,11 @@
 				</td>
 				<td>{lang_mcrypt_warning}</td>
 			</tr>
-			<tr class="row_off">
+			<tr class="row_on">
 				<td><strong>{lang_mcryptiv}</strong><br /><input type="text" name="setting[mcrypt_iv]" value="{mcrypt_iv}" size="35" /></td>
 				<td>{lang_mcryptivdescr}</td>
 			</tr>
-			<tr class="row_on">
+			<tr class="row_off">
 				<td><strong>{lang_domselect}</strong><br />
 					<select name="setting[show_domain_selectbox]">
 						<option value="True"{show_domain_selectbox_yes}>{lang_Yes}</option>


------------------------------------------------------------------------------
Find and fix application performance issues faster with Applications Manager
Applications Manager provides deep performance insights into multiple tiers of
your business applications. It resolves application problems quickly and
reduces your MTTR. Get your free trial!
https://ad.doubleclick.net/ddm/clk/302982198;130105516;z