Index: trunk/admin/browse.php
===================================================================
diff -u -r767 -r2536
--- trunk/admin/browse.php (.../browse.php) (revision 767)
+++ trunk/admin/browse.php (.../browse.php) (revision 2536)
@@ -14,10 +14,35 @@
##############################################################
//$pathtoroot="";
+
+//KERNEL4 STARTUP - FOR ACTIONS HANDLING
+
+function k4getmicrotime()
+{
+ list($usec, $sec) = explode(" ", microtime());
+ return ((float)$usec + (float)$sec);
+}
+
+$start = k4getmicrotime();
+
+define('ADMIN', 1);
+define('FULL_PATH', realpath(dirname(__FILE__).'/..'));
+define('APPLICATION_CLASS', 'MyApplication');
+define('ADMINS_LIST','/in-portal/users/users.php');
+include_once(FULL_PATH."/kernel/kernel4/startup.php");
+
+$application =& kApplication::Instance();
+$application->Init();
+$application->ProcessRequest();
+if($application->GetVar('Action') == 'm_paste') define('REDIRECT_REQUIRED',1); // this script can issue redirect header
+
+//KERNEL4 END
+
+define('REQUIRE_LAYER_HEADER', 1);
$b_topmargin = "0";
//$b_header_addon = "


";
-if(!strlen($pathtoroot))
+if( !(isset($pathtoroot) && $pathtoroot) )
{
$path=dirname(realpath(__FILE__));
if(strlen($path))
@@ -60,7 +85,7 @@
$p = "";
}
}
- if(!strlen($pathtoroot))
+ if( !(isset($pathtoroot) && $pathtoroot) )
$pathtoroot = ".".$pathchar;
}
else
@@ -83,7 +108,7 @@
if(!headers_sent())
setcookie("sid"," ",time()-3600);
$objSession->Logout();
- header("Location: ".$adminURL."/login.php");
+ header("Location: ".$adminURL."/index.php?logout=1");
die();
//require_once($pathtoroot."admin/login.php");
}
@@ -133,6 +158,20 @@
@include_once($path);
}
}
+
+
+$application->InitParser();
+
+$cat_templates = $objModules->ExecuteFunction('GetModuleInfo', 'catalog_template');
+foreach ($cat_templates as $a_mod => $a_template) {
+ if (!$a_template) continue;
+ $a_var = $a_mod.'_TAB_HTML';
+ $$a_var = $application->ParseBlock(Array('name'=>$a_template), 0, true);
+}
+
+//$application->SetVar('t', 'in-commerce/products/products_catalog');
+
+
if(!defined('IS_INSTALL'))define('IS_INSTALL',0);
if(!IS_INSTALL)
{
@@ -141,7 +180,7 @@
if(!headers_sent())
setcookie("sid"," ",time()-3600);
$objSession->Logout();
- header("Location: ".$adminURL."/login.php");
+ header("Location: ".$adminURL."/index.php?logout=1");
die();
//require_once($pathtoroot."admin/login.php");
}
@@ -173,16 +212,20 @@
if( GetVar('SearchWord') !== false ) $objSession->SetVariable('admin_seach_words', GetVar('SearchWord') );
$SearchWord = $objSession->GetVariable('admin_seach_words');
-$objSession->SetVariable("HasChanges", 0);
-
// where should all edit popups submit changes
$objSession->SetVariable("ReturnScript", basename($_SERVER['PHP_SELF']) );
+$charset = GetRegionalOption('Charset');
+
+$m_tag_processor =& $application->recallObject('m_TagProcessor');
+$base_href = $m_tag_processor->Base_Ref();
+
/* page header */
print <<
In-portal
-
+ $base_href
+
-
\ No newline at end of file
+ SetVariable("HasChanges", 0);
+ int_footer();
+
+ $application->Done();
+
+ ?>
\ No newline at end of file