first commit
This commit is contained in:
17
administrator/modules/mod_frontend/mod_frontend.php
Normal file
17
administrator/modules/mod_frontend/mod_frontend.php
Normal file
@ -0,0 +1,17 @@
|
||||
<?php
|
||||
|
||||
/**
|
||||
* @package Joomla.Administrator
|
||||
* @subpackage mod_frontend
|
||||
*
|
||||
* @copyright (C) 2019 Open Source Matters, Inc. <https://www.joomla.org>
|
||||
* @license GNU General Public License version 2 or later; see LICENSE.txt
|
||||
*/
|
||||
|
||||
\defined('_JEXEC') or die;
|
||||
|
||||
use Joomla\CMS\Helper\ModuleHelper;
|
||||
|
||||
$sitename = htmlspecialchars($app->get('sitename', ''), ENT_QUOTES, 'UTF-8');
|
||||
|
||||
require ModuleHelper::getLayoutPath('mod_frontend', $params->get('layout', 'default'));
|
||||
41
administrator/modules/mod_frontend/mod_frontend.xml
Normal file
41
administrator/modules/mod_frontend/mod_frontend.xml
Normal file
@ -0,0 +1,41 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<extension type="module" client="administrator" method="upgrade">
|
||||
<name>mod_frontend</name>
|
||||
<author>Joomla! Project</author>
|
||||
<creationDate>2019-07</creationDate>
|
||||
<copyright>(C) 2019 Open Source Matters, Inc.</copyright>
|
||||
<license>GNU General Public License version 2 or later; see LICENSE.txt</license>
|
||||
<authorEmail>admin@joomla.org</authorEmail>
|
||||
<authorUrl>www.joomla.org</authorUrl>
|
||||
<version>4.0.0</version>
|
||||
<description>MOD_FRONTEND_XML_DESCRIPTION</description>
|
||||
<files>
|
||||
<filename module="mod_frontend">mod_frontend.php</filename>
|
||||
<folder>tmpl</folder>
|
||||
</files>
|
||||
<languages>
|
||||
<language tag="en-GB">language/en-GB/mod_frontend.ini</language>
|
||||
<language tag="en-GB">language/en-GB/mod_frontend.sys.ini</language>
|
||||
</languages>
|
||||
<help key="Admin_Modules:_Frontend_Link" />
|
||||
<config>
|
||||
<fields name="params">
|
||||
<fieldset name="advanced">
|
||||
<field
|
||||
name="layout"
|
||||
type="modulelayout"
|
||||
label="JFIELD_ALT_LAYOUT_LABEL"
|
||||
class="form-select"
|
||||
/>
|
||||
|
||||
<field
|
||||
name="moduleclass_sfx"
|
||||
type="textarea"
|
||||
label="COM_MODULES_FIELD_MODULECLASS_SFX_LABEL"
|
||||
rows="3"
|
||||
validate="CssIdentifier"
|
||||
/>
|
||||
</fieldset>
|
||||
</fields>
|
||||
</config>
|
||||
</extension>
|
||||
27
administrator/modules/mod_frontend/tmpl/default.php
Normal file
27
administrator/modules/mod_frontend/tmpl/default.php
Normal file
@ -0,0 +1,27 @@
|
||||
<?php
|
||||
|
||||
/**
|
||||
* @package Joomla.Administrator
|
||||
* @subpackage mod_frontend
|
||||
*
|
||||
* @copyright (C) 2019 Open Source Matters, Inc. <https://www.joomla.org>
|
||||
* @license GNU General Public License version 2 or later; see LICENSE.txt
|
||||
*/
|
||||
|
||||
defined('_JEXEC') or die;
|
||||
|
||||
use Joomla\CMS\HTML\HTMLHelper;
|
||||
use Joomla\CMS\Language\Text;
|
||||
use Joomla\CMS\Uri\Uri;
|
||||
|
||||
?>
|
||||
<a href="<?php echo Uri::root(); ?>" class="header-item-content"
|
||||
title="<?php echo Text::sprintf('MOD_FRONTEND_PREVIEW', $sitename); ?>"
|
||||
target="_blank">
|
||||
<div class="header-item-icon">
|
||||
<span class="icon-external-link-alt" aria-hidden="true"></span>
|
||||
</div>
|
||||
<div class="header-item-text">
|
||||
<?php echo HTMLHelper::_('string.truncate', $sitename, 28, false, false); ?>
|
||||
</div>
|
||||
</a>
|
||||
Reference in New Issue
Block a user