If no section
request parameter is present, the currently active section is simply the first one in the ordered list of system.xml sections.
This happens in Mage_Adminhtml_Block_System_Config_Tabs::initTabs()
.
(I have removed parts of the method for the sake of clarity!)
public function initTabs()
{
$current = $this->getRequest()->getParam('section');
$configFields = Mage::getSingleton('adminhtml/config');
$sections = $configFields->getSections($current);
$sections = (array)$sections;
usort($sections, array($this, '_sort'));
foreach ($sections as $section) {
if ((empty($current) && $sectionAllowed)) {
$current = $code;
$this->getRequest()->setParam('section', $current);
}
// ... leave out the rest of the method ...
The _sort()
callback method simply sorts the sections by <sort_order>
value.
So which section is sorted first?
As it happens, thats the <paypal>
section, which is configured in Mage/PaypalUk/etc/system.xml!
This section has no <sort_order>
node, so it is sorted to the top.
But, you may ask yourself, why isn't the section shown?
Well, the section configuration is not only missing the <sort_order>
declaration, it is also missing the <show_in_default>
, <show_in_website>
and <show_in_store>
settings.
And the default, if these are not set explicitly to be visible, is to hide the part of the user interface (code found in Mage_Adminhtml_Block_System_Config_Form::_canShowField()
).
If we where to add <show_in_default>1</show_in_default>
to the <paypal>
section, the default page would no longer be empty, it would show the Website Payments Pro (Payflow Edition) group.
If you want a different section to show up as the default, just give it a <sort_order>
that sorts before an empty string ;)
In previous versions of Magento the <paypal>
section had a sort order set, and - if no custom module messed it up - the default section would be the General section from the Mage/Core/etc/system.xml file.
I believe (but don't know) that the current behavior with the blank page is a bug.
Best Answer
Check the content of
code/core/Mage/Core/Model/Session/Abstract.php
and make sure the file is used. If the lifetime is wrong, check where it is set.