26 $sItem = $sItem ? basename( $sItem ) :
false;
28 $sItem =
"nav_frame.tpl";
30 if ( is_array( $aFavorites ) ) {
31 $myUtilsServer->setOxCookie(
'oxidadminfavorites', implode(
'|', $aFavorites ) );
37 $this->_aViewData[
"menustructure"] = $oNavTree->getDomXml()->documentElement->childNodes;
40 $sVersion = str_replace( array (
"EE.",
"PE."),
"", $this->_sShopVersion);
41 $this->_aViewData[
"sVersion"] = trim($sVersion);
46 if (
'home.tpl' == $sItem) {
55 $aFavorites = explode(
'|', $myUtilsServer->getOxCookie(
'oxidadminfavorites' ) );
57 if ( is_array( $aFavorites ) && count( $aFavorites ) ) {
58 $this->_aViewData[
"menufavorites"] = $oNavTree->getListNodes( $aFavorites );
59 $this->_aViewData[
"aFavorites"] = $aFavorites;
63 $aHistory = explode(
'|', $myUtilsServer->getOxCookie(
'oxidadminhistory' ) );
64 if ( is_array( $aHistory ) && count( $aHistory ) ) {
65 $this->_aViewData[
"menuhistory"] = $oNavTree->getListNodes( $aHistory );
72 $oShoplist =
oxNew(
'oxshoplist' );
73 $oBaseShop = $oShoplist->getBaseObject();
77 if (!$blisMallAdmin) {
80 $sWhere =
"where ".$oBaseShop->getViewName().
".oxid = '$sShopID'";
83 $oShoplist->selectString(
"select ".$oBaseShop->getSelectFields().
" from ".$oBaseShop->getViewName().
" $sWhere");
84 $this->_aViewData[
'shoplist'] = $oShoplist;
99 $this->_aViewData[
'loadbasefrm'] =
true;
105 $this->_aViewData[
'listview'] = $sListView;
106 $this->_aViewData[
'editview'] = $sEditView;
107 $this->_aViewData[
'actedit'] = $iActEdit;
120 $oUser =
oxNew(
"oxuser");
124 $mySession->destroy();
127 if (
$myConfig->getConfigParam(
'blAdodbSessionHandler' ) ) {
129 $oDb->execute(
"delete from oxsessions where SessionID = ".$oDb->quote($mySession->getId()));
133 if (
$myConfig->getConfigParam(
'blClearCacheOnLogout' ) ) {
152 if (
$myConfig->getConfigParam(
'blLoadDynContents') && strpos( $sUrl, $this->_sAllowedHost ) === 0 ) {
154 $sPath =
$myConfig->getConfigParam(
'sCompileDir') .
"/" . md5( $sUrl ) .
'.html';
155 if ( $myUtils->getRemoteCachePath( $sUrl, $sPath ) ) {
160 $sCurYear = date(
"Y" );
163 $sOutput = file_get_contents( $sPath );
166 $sOutput = $oStr->preg_replace(
"/<\/head>/i",
"<base href=\"".dirname( $sUrl ).
'/'.
"\"></head>\n <!-- OXID eShop {$sEdition}, Version {$sVersion}, Shopping Cart System (c) OXID eSales AG 2003 - {$sCurYear} - http://www.oxid-esales.com -->", $sOutput );
169 $myUtils->showMessageAndExit( $oStr->preg_replace(
"/href=\"#\"/i",
'href="javascript::void();"', $sOutput ) );
173 $myUtils->redirect( $sUrl,
true, 302 );
177 $myUtils->showMessageAndExit(
"" );
188 $aMessage = array ();
192 if ( !$oSysReq->getSysReqStatus() ) {
193 $aMessage[
'warning'] =
oxRegistry::getLang()->translateString(
'NAVIGATION_SYSREQ_MESSAGE');
194 $aMessage[
'warning'] .=
'<a href="?cl=sysreq&stoken='.$this->getSession()->getSessionChallengeToken().
'" target="basefrm">';
195 $aMessage[
'warning'] .=
oxRegistry::getLang()->translateString(
'NAVIGATION_SYSREQ_MESSAGE2').
'</a>';
199 if ( $this->
getConfig()->getConfigParam(
'blCheckForUpdates' ) ) {
201 $aMessage[
'message'] .= $sVersionNotice;
207 if ( file_exists( $this->
getConfig()->getConfigParam(
'sShopDir').
'/setup/index.php' ) ) {
208 $aMessage[
'warning'] .= ((! empty($aMessage[
'warning']))?
"<br>":
'').oxRegistry::getLang()->translateString(
'SETUP_DIRNOTDELETED_WARNING');
212 $sUpdateDir = $this->
getConfig()->getConfigParam(
'sShopDir' ) .
'/updateApp/';
213 if ( file_exists( $sUpdateDir ) && !(count(glob(
"$sUpdateDir/*")) === 0) ) {
214 $aMessage[
'warning'] .= ((! empty($aMessage[
'warning']))?
"<br>":
'').oxRegistry::getLang()->translateString(
'UPDATEAPP_DIRNOTDELETED_WARNING');
218 $sConfPath = $this->
getConfig()->getConfigParam(
'sShopDir' ) .
"/config.inc.php";
219 if ( !is_readable( $sConfPath ) || is_writable( $sConfPath ) ) {
220 $aMessage[
'warning'] .= ( ( ! empty($aMessage[
'warning'] ) )?
"<br>":
'' ).oxRegistry::getLang()->translateString(
'SETUP_CONFIGPERMISSIONS_WARNING' );
235 $sQuery =
'http://admin.oxid-esales.com/'.$sVersion.
'/onlinecheck.php?getlatestversion';
236 if ($sVersion =
oxRegistry::get(
"oxUtilsFile")->readRemoteFileAsString($sQuery)) {
238 if (version_compare($this->
getConfig()->getVersion(), $sVersion) ==
'-1') {
239 return sprintf(
oxRegistry::getLang()->translateString(
'NAVIGATION_NEWVERSIONAVAILABLE'), $sVersion);