-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Implementation of Meta page. A lot of modules rejiggered. More module…
…s to be added but it closes #32.
- Loading branch information
Showing
10 changed files
with
169 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
{{include file="header.tpl" page="meta"}} | ||
<div class="hero-unit"> | ||
<h1>{{$masthead}}</h1> | ||
<p>{{$subhead}}</p> | ||
</div> | ||
|
||
<div class="row"> | ||
|
||
<div class="span4"> | ||
<h2>Services</h2> | ||
<table class="table table-bordered table-condensed"> | ||
<tbody> | ||
{{foreach $serviceList as $service}} | ||
<tr><td><strong>{{$service.title}}</strong></td><td><span class={{if $service.status == 1}}text-warning{{elseif $service.status == 2}}text-error{{else}}text-success{{/if}}>{{$service.message}}</span></td></tr> | ||
{{/foreach}} | ||
</tbody> | ||
</table> | ||
</div> | ||
|
||
<div class="span8"> | ||
<h2>Error log</h2> | ||
<pre class=.pre-scrollable>{{$errorLog}}</pre> | ||
</div> | ||
|
||
</div> | ||
{{include file="footer.tpl" page="meta"}} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
<?php | ||
require "alice.php"; | ||
|
||
if (time()-$u['time'] > 1200) $errors[] = array("error", "Alice's data is at least 20 minutes old."); | ||
|
||
/* Masthead */ | ||
$masthead = "Meta"; | ||
|
||
/* Subhead */ | ||
$subhead = "It is ".date("g:i a"); | ||
|
||
$errorLog = file_get_contents(PATH."error.log"); | ||
|
||
$smarty->assign("masthead", $masthead); | ||
$smarty->assign("subhead", $subhead); | ||
$smarty->assign("serviceList", $serviceList); | ||
$smarty->assign("errorLog", $errorLog); | ||
$smarty->assign("updateTime", date("g:i a", $u['time'])); | ||
$smarty->assign("updateCity", $l['city'].', '.$l['state']); | ||
$smarty->assign("error", $errors); | ||
$smarty->display("meta.tpl"); | ||
?> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters