summaryrefslogtreecommitdiffstats
path: root/core/templates
diff options
context:
space:
mode:
authorJake Wilson <jakew@huebnerpetersen.com>2013-10-10 12:29:13 -0600
committerJake Wilson <jakew@huebnerpetersen.com>2013-10-10 12:29:13 -0600
commit5144def99bf084f1e415a8734909363725d2925d (patch)
tree3d50d94e5198a4a52515c98144ac6f71bf672d05 /core/templates
parent0641365a1033b3e6b926a5e280f3bd2559e2ea23 (diff)
downloadnextcloud-server-5144def99bf084f1e415a8734909363725d2925d.tar.gz
nextcloud-server-5144def99bf084f1e415a8734909363725d2925d.zip
Moved Core Theme Logos to CSS
In order to make it easier for a user/developer to replace logos in the core theme, I removed the hardcoded `logo.svg` and `logo-wide.svg` from the html, and replaced them with `div`s that use css background-image instead. This has multiple advantages: 1. The user can now use any filename they want for the logo. They are no longer forced to use logo.svg or logo-wide.svg. 2. The user can now easily use a JPG, PNG or GIF logo instead of SVG (SVG's are awesome, but used by an unfortunately small percentage of web developers at the current time. Most probably don't even know how to make an SVG…). 3. The user doesn't have to resort to hacking the core theme template files in order to use a different filename or file type. 4. Greatly simplifies documentation instructions for how to change the logos (http://owncloud.org/theming/). Signed-off-by: Jake Wilson <jakew@huebnerpetersen.com>
Diffstat (limited to 'core/templates')
-rw-r--r--core/templates/layout.guest.php2
-rw-r--r--core/templates/layout.user.php5
2 files changed, 4 insertions, 3 deletions
diff --git a/core/templates/layout.guest.php b/core/templates/layout.guest.php
index cecd97ace27..6f0f2cbd68e 100644
--- a/core/templates/layout.guest.php
+++ b/core/templates/layout.guest.php
@@ -36,7 +36,7 @@
<body id="body-login">
<div class="wrapper"><!-- for sticky footer -->
<header><div id="header">
- <img src="<?php print_unescaped(image_path('', 'logo.svg')); ?>" class="svg" alt="<?php p($theme->getName()); ?>" />
+ <div class='logo'></div>
<div id="logo-claim" style="display:none;"><?php p($theme->getLogoClaim()); ?></div>
</div></header>
diff --git a/core/templates/layout.user.php b/core/templates/layout.user.php
index 39cc43fc465..6c0b8766f80 100644
--- a/core/templates/layout.user.php
+++ b/core/templates/layout.user.php
@@ -43,8 +43,9 @@
<?php endif; ?>
</div>
<header><div id="header">
- <a href="<?php print_unescaped(link_to('', 'index.php')); ?>" title="" id="owncloud"><img class="svg"
- src="<?php print_unescaped(image_path('', 'logo-wide.svg')); ?>" alt="<?php p($theme->getName()); ?>" /></a>
+ <a href="<?php print_unescaped(link_to('', 'index.php')); ?>" title="" id="owncloud">
+ <div class='logo-wide'></div>
+ </a>
<div id="logo-claim" style="display:none;"><?php p($theme->getLogoClaim()); ?></div>
<ul id="settings" class="svg">
<span id="expand" tabindex="0" role="link">