diff options
author | Florian Pritz <bluewind@xinu.at> | 2013-07-15 21:02:58 +0200 |
---|---|---|
committer | Florian Pritz <bluewind@xinu.at> | 2013-07-15 21:06:53 +0200 |
commit | 463553f8216029942e478f6be346897e8ce2c83d (patch) | |
tree | e7f0459b7651c25288dd8615eb8d3f5a5c4e30bd /application | |
parent | f37cbe5725db038b42777848064c4a79b818d0a8 (diff) |
Add footer; move contact info to footer
Signed-off-by: Florian Pritz <bluewind@xinu.at>
Diffstat (limited to 'application')
-rw-r--r-- | application/config/config.php | 2 | ||||
-rw-r--r-- | application/controllers/file.php | 15 | ||||
-rw-r--r-- | application/views/contact.php | 1 | ||||
-rw-r--r-- | application/views/file/upload_form.php | 3 | ||||
-rw-r--r-- | application/views/footer.php | 15 | ||||
-rw-r--r-- | application/views/header.php | 2 |
6 files changed, 32 insertions, 6 deletions
diff --git a/application/config/config.php b/application/config/config.php index 639e4e566..3ff8b816b 100644 --- a/application/config/config.php +++ b/application/config/config.php @@ -380,8 +380,6 @@ $config['actions_max_age'] = 60*60*24*5; // 5 days // won't be deleted $config['small_upload_size'] = 1024*10; // 10KB -$config['contact_me_url'] = ''; // ommiting this will remove the "contact me" line. - // for possible drivers look into ./application/libraries/Duser/drivers/ $config['authentication_driver'] = 'db'; diff --git a/application/controllers/file.php b/application/controllers/file.php index d0884e3f7..438a47590 100644 --- a/application/controllers/file.php +++ b/application/controllers/file.php @@ -349,7 +349,6 @@ class File extends CI_Controller { $this->data['small_upload_size'] = $this->config->item('small_upload_size'); $this->data['max_upload_size'] = $this->config->item('upload_max_size'); $this->data['upload_max_age'] = $this->config->item('upload_max_age')/60/60/24; - $this->data['contact_me_url'] = $this->config->item('contact_me_url'); $this->data['username'] = $this->muser->get_username(); @@ -681,6 +680,20 @@ class File extends CI_Controller { $this->_show_url($ids, $last_upload["lexer"]); } + function contact() + { + $file = FCPATH."data/local/contact-info.php"; + if (file_exists($file)) { + $this->data["contact_info"] = file_get_contents($file); + } else { + $this->data["contact_info"] = '<p>Contact info not available.</p>'; + } + + $this->load->view('header', $this->data); + $this->load->view('contact', $this->data); + $this->load->view('footer', $this->data); + } + /* Functions below this comment can only be run via the CLI * `php index.php file <function name>` */ diff --git a/application/views/contact.php b/application/views/contact.php new file mode 100644 index 000000000..6497ab6a7 --- /dev/null +++ b/application/views/contact.php @@ -0,0 +1 @@ +<?php echo $contact_info; ?> diff --git a/application/views/file/upload_form.php b/application/views/file/upload_form.php index a83ca3c87..bc6362988 100644 --- a/application/views/file/upload_form.php +++ b/application/views/file/upload_form.php @@ -74,8 +74,5 @@ <?php if(auth_driver_function_implemented("can_register_new_users")) { ?> <p>If you believe you deserve an account, ask someone who is already using this service to <a href="<?php echo site_url("user/invite"); ?>">invite</a> you.</p> <?php } ?> - <?php if(isset($contact_me_url) && $contact_me_url) { ?> - <p>If you experience any problems feel free to <a href="<?php echo $contact_me_url; ?>">contact me</a>.</p> - <?php } ?> </div> </div> diff --git a/application/views/footer.php b/application/views/footer.php index 973210d19..459b62959 100644 --- a/application/views/footer.php +++ b/application/views/footer.php @@ -4,6 +4,21 @@ if (is_cli_client() && !isset($force_full_html)) { } ?> </div> +<div id="push"></div> +</div> +<footer class="footer" id="footer"> + <div class="container"> + <p class="muted credits"> + <p>Site code licensed under <a href="http://www.gnu.org/licenses/agpl-3.0.html" target="_blank">AGPL v3</a>.</p> + <p><a href="http://glyphicons.com">Glyphicons Free</a> licensed under <a href="http://creativecommons.org/licenses/by/3.0/">CC BY 3.0</a>.</p> + <ul class="footer-links"> + <li><a href="http://git.server-speed.net/users/flo/filebin/">Source</a></li> + <li class="muted">·</li> + <li><a href="<?php echo site_url("file/contact"); ?>">Contact</a></li> + </ul> + </p> + </div> +</footer> <?php echo include_js("/data/js/jquery-2.0.2.min.js"); ?> <?php echo include_js("/data/js/jquery-ui-1.10.3.custom.min.js"); ?> <?php echo include_js("/data/js/bootstrap-2.3.2.min.js"); ?> diff --git a/application/views/header.php b/application/views/header.php index deafa1ef5..ae6f037fb 100644 --- a/application/views/header.php +++ b/application/views/header.php @@ -24,6 +24,8 @@ if (is_cli_client() && !isset($force_full_html)) { </head> <body> +<div id="wrap"> +<div id="navbar-height"></div> <?php if (file_exists(FCPATH."data/local/header.inc.php")) { include FCPATH."data/local/header.inc.php"; }?> |