summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCarson Fleming <cflems@cflems.net>2017-07-08 16:05:25 -0700
committerCarson Fleming <cflems@cflems.net>2017-07-08 16:05:25 -0700
commit2f14a6bc40fefc5ef573e45348050071708dff71 (patch)
tree9687519c27e1063c888db35c0d0c8048cdee0fe5
parentff73103903dd3417e1a4d2b180e6d652b548a9de (diff)
downloadbulletin-2f14a6bc40fefc5ef573e45348050071708dff71.tar.gz
Automated copyright notice update
-rw-r--r--dash/footer.php2
-rw-r--r--forgot.php2
-rw-r--r--inc/app_eml.tpl2
-rw-r--r--inc/changed.tpl2
-rw-r--r--inc/eml.tpl2
-rw-r--r--inc/fatal.tpl2
-rw-r--r--inc/forgot.tpl2
-rw-r--r--inc/functions.php4
-rw-r--r--inc/hire_eml.tpl2
-rw-r--r--index.php3
-rw-r--r--login.php2
-rw-r--r--signup.php2
12 files changed, 16 insertions, 11 deletions
diff --git a/dash/footer.php b/dash/footer.php
index 11e6462..6fd2633 100644
--- a/dash/footer.php
+++ b/dash/footer.php
@@ -5,7 +5,7 @@ $db->close();
?>
</div>
<div id="footer">
- <p id="copy">Copyright &copy; 2016 Bulletin Team</p>
+ <p id="copy"><?=copy_notice();?></p>
</div>
</body>
</html>
diff --git a/forgot.php b/forgot.php
index 24860e2..41625f2 100644
--- a/forgot.php
+++ b/forgot.php
@@ -63,6 +63,6 @@ if (!empty($_POST['email'])) {
</div>
<div class="hr"></div>
<p class="welcome">Welcome back to Bulletin! :)</p>
- <p class="copy">Copyright &copy; 2016 Bulletin Team</p>
+ <p class="copy"><?=copy_notice();?></p>
</body>
</html>
diff --git a/inc/app_eml.tpl b/inc/app_eml.tpl
index 779e242..c66caf2 100644
--- a/inc/app_eml.tpl
+++ b/inc/app_eml.tpl
@@ -17,6 +17,6 @@
</div>
<div style="width: 450px; height: 1px; margin: auto; background: #dddddd;"></div>
[config:eml_footer]
- <p style="color: #dddddd; margin: 4em auto auto auto; text-align: center; font-size: x-small; font-family: sans-serif;">Copyright &copy; 2016 Bulletin Team</p>
+ <p style="color: #dddddd; margin: 4em auto auto auto; text-align: center; font-size: x-small; font-family: sans-serif;">[copyright]</p>
</body>
</html>
diff --git a/inc/changed.tpl b/inc/changed.tpl
index 60c1cae..653a2f4 100644
--- a/inc/changed.tpl
+++ b/inc/changed.tpl
@@ -18,6 +18,6 @@
</div>
<div style="width: 450px; height: 1px; margin: auto; background: #dddddd;"></div>
[config:eml_footer]
- <p style="color: #dddddd; margin: 4em auto auto auto; text-align: center; font-size: x-small; font-family: sans-serif;">Copyright &copy; 2016 Bulletin Team</p>
+ <p style="color: #dddddd; margin: 4em auto auto auto; text-align: center; font-size: x-small; font-family: sans-serif;">[copyright]</p>
</body>
</html>
diff --git a/inc/eml.tpl b/inc/eml.tpl
index 49cd743..bdf64a2 100644
--- a/inc/eml.tpl
+++ b/inc/eml.tpl
@@ -18,6 +18,6 @@
</div>
<div style="width: 450px; height: 1px; margin: auto; background: #dddddd;"></div>
[config:eml_footer]
- <p style="color: #dddddd; margin: 4em auto auto auto; text-align: center; font-size: x-small; font-family: sans-serif;">Copyright &copy; 2016 Bulletin Team</p>
+ <p style="color: #dddddd; margin: 4em auto auto auto; text-align: center; font-size: x-small; font-family: sans-serif;">[copyright]</p>
</body>
</html>
diff --git a/inc/fatal.tpl b/inc/fatal.tpl
index 610b2b4..c8e9893 100644
--- a/inc/fatal.tpl
+++ b/inc/fatal.tpl
@@ -18,6 +18,6 @@
[tpl:label]
</a>
</p>
- <p class="copy">Copyright &copy; 2016 Bulletin Team</p>
+ <p class="copy">[copyright]</p>
</body>
</html>
diff --git a/inc/forgot.tpl b/inc/forgot.tpl
index 38e109f..96511da 100644
--- a/inc/forgot.tpl
+++ b/inc/forgot.tpl
@@ -19,6 +19,6 @@
<div style="width: 450px; height: 1px; margin: auto; background: #dddddd;"></div>
<p style="margin-top: 2em; text-align: center; font-family: sans-serif; font-size: 12pt; color: #aaaaaa;">Welcome back to Bulletin!</p>
[config:eml_footer]
- <p style="color: #dddddd; margin: 4em auto auto auto; text-align: center; font-size: x-small; font-family: sans-serif;">Copyright &copy; 2016 Bulletin Team</p>
+ <p style="color: #dddddd; margin: 4em auto auto auto; text-align: center; font-size: x-small; font-family: sans-serif;">[copyright]</p>
</body>
</html>
diff --git a/inc/functions.php b/inc/functions.php
index 430a6d6..34b74aa 100644
--- a/inc/functions.php
+++ b/inc/functions.php
@@ -1,9 +1,13 @@
<?php
+function copy_notice () {
+ return 'Copyright &copy; 2016-'.date('Y').' Bulletin Team';
+}
function eml_tpl ($options) {
return tpl($options, 'eml.tpl');
}
function tpl ($options, $file) {
$tpl_htm = file_get_contents(INCLUDE_PATH.$file);
+ $tpl_htm = str_replace('[copyright]', copy_notice(), $tpl_htm);
$tpl_htm = preg_replace_callback('/\[tpl:([^\]]*)\]/i',
function ($matches) use (&$options) {
if (!isset($options[$matches[1]])) return '';
diff --git a/inc/hire_eml.tpl b/inc/hire_eml.tpl
index 16b46ed..76b88e4 100644
--- a/inc/hire_eml.tpl
+++ b/inc/hire_eml.tpl
@@ -18,6 +18,6 @@
</div>
<div style="width: 450px; height: 1px; margin: auto; background: #dddddd;"></div>
[config:eml_footer]
- <p style="color: #dddddd; margin: 4em auto auto auto; text-align: center; font-size: x-small; font-family: sans-serif;">Copyright &copy; 2016 Bulletin Team</p>
+ <p style="color: #dddddd; margin: 4em auto auto auto; text-align: center; font-size: x-small; font-family: sans-serif;">[copyright]</p>
</body>
</html>
diff --git a/index.php b/index.php
index bc9e323..8caeea2 100644
--- a/index.php
+++ b/index.php
@@ -1,5 +1,6 @@
<?php
require('inc/common.php');
+fatal('hi');
?>
<!DOCTYPE html>
<html>
@@ -72,7 +73,7 @@ require('inc/common.php');
</a>
</div>
<div id="footer">
- <p id="copy"><a href="#cover">Top</a>&nbsp;&nbsp;&nbsp;&bull;&nbsp;&nbsp;&nbsp;Copyright &copy; 2016 Bulletin Team</p>
+ <p id="copy"><a href="#cover">Top</a>&nbsp;&nbsp;&nbsp;&bull;&nbsp;&nbsp;&nbsp;<?=copy_notice();?></p>
</div>
</div>
</div>
diff --git a/login.php b/login.php
index 135f7c7..191e551 100644
--- a/login.php
+++ b/login.php
@@ -74,7 +74,7 @@ if (!empty($_POST["email"]) && !empty($_POST["password"])) {
</div>
<div class="hr"></div>
<p class="welcome">Welcome back to Bulletin! :)</p>
- <p class="copy">Copyright &copy; 2016 Bulletin Team</p>
+ <p class="copy"><?=copy_notice();?></p>
</body>
</html>
<?php
diff --git a/signup.php b/signup.php
index 8cb8d62..469aed1 100644
--- a/signup.php
+++ b/signup.php
@@ -151,6 +151,6 @@ if ($e == 2 || $e == 101)
</div>
<div class="hr"></div>
<p class="welcome">Welcome to Bulletin! :)</p>
- <p class="copy">Copyright &copy; 2016 Bulletin Team</p>
+ <p class="copy"><?=copy_notice();?></p>
</body>
</html>