Commit e0fe6b82 authored by Anders Damsgaard's avatar Anders Damsgaard

put navigation html into separate file

parent 8e79e68c
......@@ -20,39 +20,9 @@ if (isset($_GET['wait_id']) && !empty($_GET['wait_id'])) {
<meta http-equiv="refresh" content="5" >
<?php
}
?>
</head>
<!--<body ng-controller="mainController">-->
<body ng-app="cosmoApp">
<div ng-controller="mainController">
<!-- Navigation bar -->
<nav class="light-blue lighten-1" role="navigation">
<div class="nav-wrapper container"><a id="logo-container" href="/#/"
class="brand-logo"><img src="img/logo.png" alt="logo"
height="92" width="220"></a>
<ul class="right hide-on-med-and-down">
<li><a href="#/">Calculator</a></li>
<li><a href="#/methods">Methods</a></li>
<!--<li><a href="#/about">About</a></li>-->
<li><a href="#/help">Help</a></li>
</ul>
<ul id="nav-mobile" class="side-nav">
<li><a href="#/">Calculator</a></li>
<li><a href="#/methods">Methods</a></li>
<!--<li><a href="#/about">About</a></li>-->
<li><a href="#/help">Help</a></li>
</ul>
<a href="#" data-activates="nav-mobile"
class="button-collapse"><i
class="material-icons">menu</i></a>
</div>
</nav>
include('navigation.html');
?>
<main>
<?php
if (isset($_GET['wait_id']) && !empty($_GET['wait_id'])) {
......@@ -216,3 +186,5 @@ if (isset($_GET['wait_id']) && !empty($_GET['wait_id'])) {
</main>
<?php include('foot.html'); ?>
</head>
<!--<body ng-controller="mainController">-->
<body ng-app="cosmoApp">
<div ng-controller="mainController">
<!-- Navigation bar -->
<nav class="light-blue lighten-1" role="navigation">
<div class="nav-wrapper container"><a id="logo-container" href="/#/"
class="brand-logo"><img src="img/logo.png" alt="logo"
height="92" width="220"></a>
<ul class="right hide-on-med-and-down">
<li><a href="#/">Calculator</a></li>
<li><a href="#/methods">Methods</a></li>
<!--<li><a href="#/about">About</a></li>-->
<li><a href="#/help">Help</a></li>
</ul>
<ul id="nav-mobile" class="side-nav">
<li><a href="#/">Calculator</a></li>
<li><a href="#/methods">Methods</a></li>
<!--<li><a href="#/about">About</a></li>-->
<li><a href="#/help">Help</a></li>
</ul>
<a href="#" data-activates="nav-mobile"
class="button-collapse"><i
class="material-icons">menu</i></a>
</div>
</nav>
......@@ -102,8 +102,7 @@ if ((isset($_POST['ne_conc']) && $_POST['ne_conc'] != '') &&
if (count($missing_fields) > 0) {
//$error_msg = '<html><body>' .
//'<h2>Invalid input</h2>';
$error_msg = '</head><body>' .
'<h2>Invalid input</h2>';
$error_msg = '<main><h2>Invalid input</h2>';
// generate comma-separated list of missing field names
for ($i = 0; $i < count($missing_fields); $i++) {
......@@ -118,10 +117,12 @@ if (count($missing_fields) > 0) {
$error_msg .= '<li>' . $missing_fields[$i] . '</li>';
}
$error_msg .= '</ul></p><p>Please <a href="javascript:history.back()">go' .
' back</a> and fill in the missing fields.</p></body></html>';
' back</a> and fill in the missing fields.</p></main>';
//' back</a> and fill in the missing fields.</p></main></html>';
//die($error_msg); // end this script, print error
include('head.html');
echo($error_msg); // end this script, print error
include('navigation.html');
echo($error_msg);
include('foot.html');
die();
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment