Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
M
moodle-theme_boost_campus_child
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
elc
moodle-theme_boost_campus_child
Commits
f4327c23
Commit
f4327c23
authored
4 years ago
by
Kathrin Osswald
Browse files
Options
Downloads
Patches
Plain Diff
Fixed bug that theme Boost Campus Child did not show the favicon set in parent theme Boost Campus.
parent
47c4ee26
No related branches found
No related tags found
No related merge requests found
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
CHANGES.md
+1
-0
1 addition, 0 deletions
CHANGES.md
classes/output/core_renderer.php
+72
-0
72 additions, 0 deletions
classes/output/core_renderer.php
with
73 additions
and
0 deletions
CHANGES.md
+
1
−
0
View file @
f4327c23
...
@@ -6,6 +6,7 @@ Changes
...
@@ -6,6 +6,7 @@ Changes
### Unreleased
### Unreleased
*
2020-09-24 - Fixed bug that theme Boost Campus Child did not show the favicon set in parent theme Boost Campus.
*
2020-06-09 - Improved SCSS settings to be used with admin_setting_scsscode that validates the code before saving.
*
2020-06-09 - Improved SCSS settings to be used with admin_setting_scsscode that validates the code before saving.
### v3.8-r1
### v3.8-r1
...
...
This diff is collapsed.
Click to expand it.
classes/output/core_renderer.php
0 → 100644
+
72
−
0
View file @
f4327c23
<?php
// This file is part of Moodle - http://moodle.org/
//
// Moodle is free software: you can redistribute it and/or modify
// it under the terms of the GNU General Public License as published by
// the Free Software Foundation, either version 3 of the License, or
// (at your option) any later version.
//
// Moodle is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
//
// You should have received a copy of the GNU General Public License
// along with Moodle. If not, see <http://www.gnu.org/licenses/>.
/**
* Renderers to align Moodle's HTML with that expected by Bootstrap
*
* @package theme_boost_campus_child
* @copyright 2017 Kathrin Osswald, Ulm University kathrin.osswald@uni-ulm.de
* copyright based on code from theme_boost by Bas Brands
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
*/
namespace
theme_boost_campus_child\output
;
use
moodle_url
;
use
theme_config
;
defined
(
'MOODLE_INTERNAL'
)
||
die
;
/**
* Extending the core_renderer interface.
*
* @copyright 2020 Kathrin Osswald, Ulm University kathrin.osswald@uni-ulm.de
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
* @package theme_boost_campus_child
* @category output
*/
class
core_renderer
extends
\core_renderer
{
/**
* Override to be able to use uploaded images from admin_setting as well.
*
* Returns the moodle_url for the favicon.
*
* KIZ MODIFICATION: This renderer function is copied and modified from /lib/outputrenderers.php
*
* @since Moodle 2.5.1 2.6
* @return moodle_url The moodle_url for the favicon
*/
public
function
favicon
()
{
// MODIFICATION START.
// Get the theme Boost Campus config.
$bcconfig
=
theme_config
::
load
(
'boost_campus'
);
// Get the theme Boost Campus favicon setting.
$bcconffavicon
=
get_config
(
'theme_boost_campus'
,
'favicon'
);
if
(
!
empty
(
$bcconffavicon
))
{
// Return the image that was saved in the theme Boost Campus favicon setting.
return
$bcconfig
->
setting_file_url
(
'favicon'
,
'favicon'
);
}
else
{
// Return the icon stored in boost_campus/pix folder.
return
$bcconfig
->
image_url
(
'favicon'
,
'theme'
);
}
// MODIFICATION END.
/* ORIGINAL START.
return $this->image_url('favicon', 'theme');
ORIGINAL END. */
}
}
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment