Page Menu
Home
In-Portal Phabricator
Search
Configure Global Search
Log In
Files
F1181885
in-portal
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Subscribers
None
File Metadata
Details
File Info
Storage
Attached
Created
Tue, Oct 14, 1:33 PM
Size
2 KB
Mime Type
text/x-diff
Expires
Thu, Oct 16, 1:33 PM (1 d, 3 h)
Engine
blob
Format
Raw Data
Handle
767363
Attached To
rINP In-Portal
in-portal
View Options
Index: branches/5.0.x/core/units/sections/site_config_tp.php
===================================================================
--- branches/5.0.x/core/units/sections/site_config_tp.php (revision 12265)
+++ branches/5.0.x/core/units/sections/site_config_tp.php (revision 12266)
@@ -1,48 +1,60 @@
<?php
+/**
+* @version $Id$
+* @package In-Portal
+* @copyright Copyright (C) 1997 - 2009 Intechnic. All rights reserved.
+* @license GNU/GPL
+* In-Portal is Open Source software.
+* This means that this software may have been modified pursuant
+* the GNU General Public License, and as distributed it includes
+* or is derivative of works licensed under the GNU General Public License
+* or other free or open source software licenses.
+* See http://www.in-portal.net/license/ for copyright notices and details.
+*/
class SiteConfigTagProcessor extends TagProcessor {
function PrintEditingModes($params)
{
$editing_modes = Array (
1 => Array ('image' => 'show_structure', 'title' => 'Browse Mode'),
4 => Array ('image' => 'content_mode', 'title' => 'Content Mode'),
2 => Array ('image' => 'show_all', 'title' => 'Layout Mode'),
3 => Array ('image' => 'show_all', 'title' => 'Design Mode'),
);
$preset_name = $this->Application->ConfigValue('AdminConsoleInterface');
$base_path = FULL_PATH . ADMIN_DIRECTORY . '/system_presets/' . $preset_name;
if (file_exists($base_path . DIRECTORY_SEPARATOR . 'settings.php')) {
include_once $base_path . DIRECTORY_SEPARATOR . 'settings.php'; // will get $visible_editing_modes
foreach ($editing_modes as $editing_mode => $data) {
if (!in_array($editing_mode, $visible_editing_modes)) {
unset($editing_modes[$editing_mode]);
}
}
if (count($editing_modes) == 1) {
// don't show buttons, when there only one left
return '';
}
}
$ret = '';
$i = 1;
$count = count($editing_modes);
$block_params = Array ('name' => $params['render_as']);
foreach ($editing_modes as $editing_mode => $data) {
$block_params = array_merge($block_params, $data);
$block_params['editing_mode'] = $editing_mode;
$block_params['is_last'] = $i == $count;
$ret .= $this->Application->ParseBlock($block_params);
$i++;
}
return $ret;
}
}
\ No newline at end of file
Property changes on: branches/5.0.x/core/units/sections/site_config_tp.php
___________________________________________________________________
Added: svn:keywords
## -0,0 +1 ##
+Id
\ No newline at end of property
Event Timeline
Log In to Comment