fix template
Former-commit-id: e3e8196ec34e4ba9c1d99397691d4923250658b2
--- a/documents/template.inc.php
+++ b/documents/template.inc.php
@@ -1,6 +1,7 @@
<?php
function include_header_documents($title) {
+header('X-UA-Compatible: IE=edge,chrome=1');
?>
<!doctype html>
<!-- paulirish.com/2008/conditional-stylesheets-vs-css-hacks-answer-neither/ -->
@@ -11,10 +12,6 @@
<!--[if gt IE 8]><!--> <html class="no-js" lang="en"> <!--<![endif]-->
<head>
<meta charset="utf-8">
-
- <!-- Use the .htaccess and remove these lines to avoid edge case issues.
- More info: h5bp.com/i/378 -->
- <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<title>Australian Disclosure Logs<?php if ($title != "") echo " - $title";?></title>
<meta name="description" content="">
@@ -145,8 +142,8 @@
}
function displayLogEntry($row, $idtoname) {
$result = "";
- $result .= "<div><h2>".$row->value->date.": ".truncate($row->value->title, 80)." (".$idtoname[$row->value->agencyID].")</h2>";
- echo "<p> Title".$row->value->title."<br/>".str_replace("\n","<br>",$row->value->description);
+ $result .= "<div><h2>".$row->value->date.": ".truncate($row->value->title, 120)." (".$idtoname[$row->value->agencyID].")</h2>";
+ $result .= "<p> Title".$row->value->title."<br/>".str_replace("\n","<br>",$row->value->description);
if (isset($row->value->notes)) {
$result .= " <br>Note: ".$row->value->notes;
}
@@ -155,7 +152,7 @@
if (isset($row->value->links)){
$result .= "<h3>Links/Documents</h3><ul>";
foreach ($row->value->links as $link) {
- $result .= "<li><a href='$link'>".$link."</a></li>";
+ $result .= "<li><a href='$link'>".urlencode($link)."</a></li>";
}
$result .= "</ul>";