From dfa7753c6753e835d6542cb0f6b8d26df84ae7b1 Mon Sep 17 00:00:00 2001
From: Kevin Abel <kevin.abel.0@gmail.com>
Date: Thu, 17 Apr 2014 17:19:21 -0500
Subject: [PATCH] Add template files to support some controller/view
 separation.

---
 www/templates/breadcrumbs.tpl.php    |  4 +++
 www/templates/embed.tpl.php          | 41 ++++++++++++++++++++++++++++
 www/templates/google-results.tpl.php |  4 +++
 www/templates/search-form.tpl.php    | 11 ++++++++
 www/templates/search-results.tpl.php | 39 ++++++++++++++++++++++++++
 5 files changed, 99 insertions(+)
 create mode 100644 www/templates/breadcrumbs.tpl.php
 create mode 100644 www/templates/embed.tpl.php
 create mode 100644 www/templates/google-results.tpl.php
 create mode 100644 www/templates/search-form.tpl.php
 create mode 100644 www/templates/search-results.tpl.php

diff --git a/www/templates/breadcrumbs.tpl.php b/www/templates/breadcrumbs.tpl.php
new file mode 100644
index 0000000..f1d3f92
--- /dev/null
+++ b/www/templates/breadcrumbs.tpl.php
@@ -0,0 +1,4 @@
+<ul>
+    <li><a href="http://www.unl.edu/" title="University of Nebraska&ndash;Lincoln">UNL</a></li>
+    <li>Search</li>
+</ul>
diff --git a/www/templates/embed.tpl.php b/www/templates/embed.tpl.php
new file mode 100644
index 0000000..56db317
--- /dev/null
+++ b/www/templates/embed.tpl.php
@@ -0,0 +1,41 @@
+<!DOCTYPE html>
+<!--[if IEMobile 7 ]><html class="ie iem7 embed"><![endif]-->
+<!--[if lt IE 7 ]><html class="ie ie6 embed" lang="en"><![endif]-->
+<!--[if IE 7 ]><html class="ie ie7 embed" lang="en"><![endif]-->
+<!--[if IE 8 ]><html class="ie ie8 embed" lang="en"><![endif]-->
+<!--[if (gte IE 9)|(gt IEMobile 7) ]><html class="ie embed" lang="en"><![endif]-->
+<!--[if !(IEMobile) | !(IE)]><!--><html class="embed" lang="en"><!--<![endif]-->
+<head>
+    <meta charset="utf-8" />
+    <title>UNL Search | University of Nebraska&ndash;Lincoln</title>
+<!-- Load Cloud.typography fonts -->
+	<link rel="stylesheet" type="text/css" href="//cloud.typography.com/7717652/616662/css/fonts.css" />
+<!-- Load our base CSS file -->
+<!--[if gte IE 9]><!-->    
+    <link rel="stylesheet" type="text/css" media="all" href="//unlcms.unl.edu/wdn/templates_4.0/css/all.css" />
+<!--<![endif]-->
+
+<!-- Load the template JS file -->
+    <script type="text/javascript" src="/wdn/templates_4.0/scripts/compressed/all.js?dep=4.0.7" id="wdn_dependents"></script>
+    
+<!--[if lt IE 9]>
+    <link rel="stylesheet" type="text/css" media="all" href="//unlcms.unl.edu/wdn/templates_4.0/css/all_oldie.css" />
+    <script src="//html5shiv.googlecode.com/svn/trunk/html5.js"></script>
+<![endif]-->
+
+<!-- For all IE versions, bring in the tweaks -->
+<!--[if IE]>
+    <link rel="stylesheet" type="text/css" media="all" href="//unlcms.unl.edu/wdn/templates_4.0/css/ie.css" />
+<![endif]-->
+    <?php echo $head ?>
+</head>
+<body>
+    <div id="wdn_wrapper">
+        <div id="wdn_content_wrapper">
+            <div id="maincontent" class="wdn-main">
+            <?php echo $maincontent ?>
+            </div>
+        </div>
+    </div>
+</body>
+</html>
diff --git a/www/templates/google-results.tpl.php b/www/templates/google-results.tpl.php
new file mode 100644
index 0000000..38ef9b0
--- /dev/null
+++ b/www/templates/google-results.tpl.php
@@ -0,0 +1,4 @@
+<?php if (isset($title)): ?>
+<h3><?php echo $title ?> Results</h3>
+<?php endif; ?>
+<div id="<?php echo isset($id) ? $id : '' ?>" class="google-results"></div>
diff --git a/www/templates/search-form.tpl.php b/www/templates/search-form.tpl.php
new file mode 100644
index 0000000..1302a3a
--- /dev/null
+++ b/www/templates/search-form.tpl.php
@@ -0,0 +1,11 @@
+<div id="searchform" class="wdn-band">
+  <form action="./" method="get" class="wdn-inner-wrapper">
+      <div class="input-group">
+        <input type="text" value=""  name="q" id="search_q" title="Search Query" placeholder="e.g., Herbert Husker, Ph.D." />
+        <span class="input-group-btn"><button class="button wdn-icon-search" title="Search" type="submit"></button></span>
+    </div>
+      <?php if (!empty($local_results)): ?>
+      <input type="hidden" name="u" value="<?php echo htmlentities($_GET['u'], ENT_QUOTES) ?>" />
+      <?php endif; ?>
+  </form>
+</div>
diff --git a/www/templates/search-results.tpl.php b/www/templates/search-results.tpl.php
new file mode 100644
index 0000000..b0deffb
--- /dev/null
+++ b/www/templates/search-results.tpl.php
@@ -0,0 +1,39 @@
+<section class="wdn-band" id="search_wrapper">
+    <div class="<?php if (!$isEmbed): ?>wdn-inner-wrapper wdn-inner-padding-sm<?php endif; ?>">
+    
+        <div class="wdn-grid-set search-set">
+        
+            <div id="search_results" class="results-group">
+                <div class="result-head">
+                    <h2>UNL Web</h2>
+                    <ul class="result-tab">
+                        <?php if (!empty($local_results)): ?>
+                        <li><a href="#">This unit</a></li>
+                        <?php endif; ?>
+                        <li><a href="#">All of UNL</a></li>
+                    </ul>
+                </div>
+                <div class="search-results">
+                <?php echo $local_results ?>
+                <?php renderTemplate('templates/google-results.tpl.php', array(
+                    'title' => 'All of UNL',
+                    'id' => 'unl_results',
+                )) ?>
+                </div>
+            </div>
+            
+            <div id="directory_results" class="results-group">
+                <div class="result-head">
+                    <h2>UNL Directory</h2>
+                    <ul class="result-tab">
+                        <li><a href="#">People</a></li>
+                        <li><a href="#">Departments</a></li>
+                    </ul>
+                </div>
+                <div id="ppl_results" class="search-results"></div>
+            </div>
+            
+        </div>
+    
+    </div>
+</section>
\ No newline at end of file
-- 
GitLab