FEATURE: Added swipe left/right to open search/menu

* cleaned up bar to maximize space
  * renamed index
This commit is contained in:
jason.wall 2014-12-26 09:41:15 -05:00
parent 799dd61dbb
commit 38efa19a4a
3 changed files with 122 additions and 176 deletions

View File

@ -1,70 +1,113 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml">
<!doctype html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<meta http-equiv="Access-Control-Allow-Origin" content="*" />
<meta name="author" content="Jason Wall" />
<meta name="PBO.auth" content="8bff0c5d7a8f61d1e5dfa6c58da67c2b" />
<meta name="geo.country" content="US" />
<meta name="dc.language" content="en" />
<meta name="dc.title" content="walljm.com || AJAX Bible || King James Version with Strong's Dictionary and Cross References" />
<meta name="description" content="An AJAX implimentation of The King James Version Bible with Strong's Dictionary integrated." />
<meta name="keywords" content="AJAX, KJV, King James Version, Strong's Dictionary, Strongs" />
<meta name="copyright" content="All content copyrighted to Jason Wall, and available by permission of the owner." />
<title>The Bible with Strong's Numbers and Cross References</title>
<style>@import "css/bible.css";@import "css/jquery-ui.css";</style>
<script data-main="js/main" type="text/javascript" src="js/require-jquery.js"></script>
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" href="css/jquery.mobile-1.4.5.min.css" />
<link rel="stylesheet" href="css/themes/db.css" />
<style>@import "css/bible.css";</style>
<script src="js/jquery-1.11.1.min.js"></script>
<script src="js/jquery.ui.js"></script>
<script src="js/jquery.slidePanel.js"></script>
<script src="js/jquery.mobile-1.4.5.js"></script>
<script src="js/reference.js"></script>
<script src="js/common.js"></script>
<script src="js/main.js"></script>
<style>
.panel-content { padding:3px; }
.ui-btn-text { font-size: .75em;}
h3 { font-size: 1em;}
p {font-size: .8em;}
.ui-submit .ui-btn-inner .ui-btn-text { font-size: 1.2em;}
.ui-submit {height:35px;}
.ui-block-c div {
margin-top: 9px;
}
</style>
</head>
<body>
<table style="width: 100%; padding: 12px;">
<tr>
<td style="width: 320px;"><h1>King James Bible <span>with Strong's Numbers and Cross References</span></h1></td>
<td id="query" align="center">
<table style="width: 100%;">
<tr><form id="searchform">
<td><input id="searchvalue" type="search" results="10" /></td>
<td style="width: 100px;"><input value="Search" type="submit" id="searchbtn" /></td>
</form></tr>
</table>
</td>
</tr>
<tr><td colspan="3" id="settings" style="padding-top: 6px; text-align:right;">
Display Strongs in Dialog <input type="checkbox" id="display-strongs-as-dialog" /> |
<a href="javascript:void();" id="showhelp">Help</a> |
<a href="javascript:void();" id="showhidesearch">Hide Search</a> |
<a href="javascript:void();" id="switch-panes">Switch Panes</a> | Select Font:
<select id="changefont"><option value="georgia" selected="selected">Georgia</option><option value="verdana">Verdana</option><option value="courier">Courier</option><option value="serif">Serif</option><option value="sans-serif">Sans Serif</option></select> |
<span style="letter-spacing:2px;"><a href="javascript:void();" id="shrinkfont">A<span style="font-size:12px;">A</span></a> | <a href="javascript:void();" id="growfont"><span style="font-size:12px;">A</span>A</a></span></td></tr>
</table>
<div id="resultwrap">
<ul id="result"></ul>
</div>
<div id="searchresultswrap">
<h3>Search Results: <span id="searchTotal"></span></h3>
<div id="searchresults"></div>
</div>
<br clear="all" />
<div style="display: none; font-size: 14px; line-height: 18px;" id="help">
<h3>Acceptable Search Items:</h3>
<br />
<b>John 1</b> (displays whole chapter)<br />
<b>John 1-2</b> (displays both chapters<br />
<b>John 1 - John 2</b> (same as above)<br />
<b>John 1:3 - 2:4</b> (displays verses starting with chapter 1 verse 3 and ending with chapter 2 verse 4)<br />
<b>John 1:3 - John 2:4</b> (same as above)<br />
<b>John 1:3-5</b> (displays verses starting with chapter 1 verse 3 through chapter 1 vs 5)<br />
<b>H1234</b> (displays the strongs definition for the Hebrew # 1234)<br />
<b>G1234</b> (displays the strongs definition for the Greek # 1234)<br />
<b>Jesus</b> (searches for "Jesus". all search terms assume boolean AND, i.e. "Jesus Christ" assumes "Jesus AND Christ". an word without a number is interpreted as search).<br />
<br />
<h3>Notes:</h3>
<br />multiple lookups can be made useing a semicolon as a seperator, i.e. "Ruth 1; g1234; jesus"). <br />
<br />The list of results in the main window are sortable, just click and drag to reorder them.<br /><br />
<br />All greek/hebrew cross references translations are taken from the 1933 Websters version and often are not the same as the KJV translation. <br />
<br />All source materials were taken from the <a href="http://sourceforge.net/projects/zefania-sharp/">Zefania XML Bible Project</a> on SourceForge. <br />
<br />Any Errors and Omission you find would be appreciated. Please contact me via <a href='http://www.jasonwall.org/'>www.jasonwall.org</a>.<br />
<div data-role="page" id="mainpage">
<a href='biblerefparsingtests.html'>Reference Parsing Tests</a>
<div data-role="header" data-theme="a">
<div class="ui-grid-c my-breakpoint">
<div class="ui-block-a"><a id="menuicon" href="#defaultpanel"></a></div>
<div class="ui-block-b"><input id="searchvalue" type="search" /></div>
<div class="ui-block-c"><input value="Search" type="submit" id="searchbtn" /></div>
<div class="ui-block-d"><a id="searchicon" href="#searchpanel"></a></div>
</div>
</div>
</div>
<div data-role="content">
<div id="resultwrap">
<ul id="result"></ul>
</div><!-- /content -->
</div>
<div data-role="panel" id="searchpanel" data-theme="a" data-position="right" data-display="overlay">
<div class="panel-content">
<h3>Search Results: <span id="searchTotal"></span></h3>
<div id="searchresults"></div>
</div>
</div>
<div data-role="panel" id="defaultpanel" data-theme="a">
<div class="panel-content">
<h3>Settings</h3>
<ul data-role="listview">
<!--<li><label><input type="checkbox" name="display-strongs-as-dialog" id="display-strongs-as-dialog" />Display Strong's in Dialog</label></li>-->
<li><label>Select Font:
<select id="changefont">
<option value="georgia" selected="selected">Georgia</option>
<option value="verdana">Verdana</option>
<option value="courier">Courier</option>
<option value="serif">Serif</option>
<option value="sans-serif">Sans Serif</option>
</select>
</label>
</li>
<li><span style="letter-spacing:2px;"><a href="javascript:void();" id="shrinkfont">A<span style="font-size:12px;">A</span></a> | <a href="javascript:void();" id="growfont"><span style="font-size:12px;">A</span>A</a></span></li>
</ul>
<h3>Acceptable Search Items:</h3>
<p>
<b>John 1</b> (displays whole chapter)<br />
<b>John 1-2</b> (displays both chapters<br />
<b>John 1 - John 2</b> (same as above)<br />
<b>John 1:3 - 2:4</b> (displays verses starting with chapter 1 verse 3 and ending with chapter 2 verse 4)<br />
<b>John 1:3 - John 2:4</b> (same as above)<br />
<b>John 1:3-5</b> (displays verses starting with chapter 1 verse 3 through chapter 1 vs 5)<br />
<b>H1234</b> (displays the Strong's definition for the Hebrew # 1234)<br />
<b>G1234</b> (displays the Strong's definition for the Greek # 1234)<br />
<b>Jesus</b> (searches for "Jesus". all search terms assume boolean AND, i.e. "Jesus Christ" assumes "Jesus AND Christ". an word without a number is interpreted as search).<br />
</p>
<h3>Terms Excluded from Search Index</h3>
<p> "us", "these", "her", "saith", "shalt", "let", "do", "your", "we", "no", "go", "if", "at", "an", "so", "before", "also", "on", "had", "you", "there", "then", "up", "by", "upon", "were", "are", "this", "when", "thee", "their", "ye", "will", "as", "thy", "my", "me", "have", "from", "was", "but", "which", "thou", "all", "it", "with", "them", "him", "they", "is", "be", "not", "his", "i", "shall", "a", "for", "unto", "he", "in", "to", "that", "of", "and", "the"</p>
<h3>Notes:</h3>
<p>
multiple lookups can be made using a semicolon as a separator, i.e. "Ruth 1; g1234; Jesus"). <br />
<br />The list of results in the main window are sortable, just click and drag to reorder them.<br /><br />
<br />All Greek/Hebrew cross references translations are taken from the 1933 Webster's version and often are not the same as the KJV translation. <br />
<br />All source materials were taken from the <a href="http://sourceforge.net/projects/zefania-sharp/">Zefania XML Bible Project</a> on SourceForge. <br />
<br />Any Errors and Omission you find would be appreciated. Please contact me via <a href='http://www.jasonwall.org/'>www.jasonwall.org</a>.<br />
</p>
</div>
</div>
</div><!-- /page -->
</body>
</html>

View File

@ -1,113 +0,0 @@
<!doctype html>
<html>
<head>
<meta name="author" content="Jason Wall" />
<meta name="geo.country" content="US" />
<meta name="dc.language" content="en" />
<meta name="description" content="An AJAX implimentation of The King James Version Bible with Strong's Dictionary integrated." />
<meta name="keywords" content="AJAX, KJV, King James Version, Strong's Dictionary, Strongs" />
<title>The Bible with Strong's Numbers and Cross References</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" href="css/jquery.mobile-1.4.5.min.css" />
<link rel="stylesheet" href="css/themes/db.css" />
<style>@import "css/bible.css";</style>
<script src="js/jquery-1.11.1.min.js"></script>
<script src="js/jquery.ui.js"></script>
<script src="js/jquery.slidePanel.js"></script>
<script src="js/jquery.mobile-1.4.5.js"></script>
<script src="js/reference.js"></script>
<script src="js/common.js"></script>
<script src="js/main.js"></script>
<style>
.panel-content { padding:3px; }
.ui-btn-text { font-size: .75em;}
h3 { font-size: 1em;}
p {font-size: .8em;}
.ui-submit .ui-btn-inner .ui-btn-text { font-size: 1.2em;}
.ui-submit {height:35px;}
.ui-block-c div {
margin-top: 9px;
}
</style>
</head>
<body>
<div data-role="page">
<div data-role="header" data-theme="a">
<div class="ui-grid-c my-breakpoint">
<div class="ui-block-a"><a id="menuicon" href="#defaultpanel"></a></div>
<div class="ui-block-b"><input id="searchvalue" type="search" /></div>
<div class="ui-block-c"><input value="Search" type="submit" id="searchbtn" /></div>
<div class="ui-block-d"><a id="searchicon" href="#searchpanel"></a></div>
</div>
</div>
<div data-role="content">
<div id="resultwrap">
<ul id="result"></ul>
</div><!-- /content -->
</div>
<div data-role="panel" id="searchpanel" data-theme="a" data-position="right" data-display="overlay">
<div class="panel-content">
<h3>Search Results: <span id="searchTotal"></span></h3>
<div id="searchresults"></div>
</div>
</div>
<div data-role="panel" id="defaultpanel" data-theme="a">
<div class="panel-content">
<h3>Settings</h3>
<ul data-role="listview">
<!--<li><label><input type="checkbox" name="display-strongs-as-dialog" id="display-strongs-as-dialog" />Display Strong's in Dialog</label></li>-->
<li><label>Select Font:
<select id="changefont">
<option value="georgia" selected="selected">Georgia</option>
<option value="verdana">Verdana</option>
<option value="courier">Courier</option>
<option value="serif">Serif</option>
<option value="sans-serif">Sans Serif</option>
</select>
</label>
</li>
<li><span style="letter-spacing:2px;"><a href="javascript:void();" id="shrinkfont">A<span style="font-size:12px;">A</span></a> | <a href="javascript:void();" id="growfont"><span style="font-size:12px;">A</span>A</a></span></li>
</ul>
<h3>Acceptable Search Items:</h3>
<p>
<b>John 1</b> (displays whole chapter)<br />
<b>John 1-2</b> (displays both chapters<br />
<b>John 1 - John 2</b> (same as above)<br />
<b>John 1:3 - 2:4</b> (displays verses starting with chapter 1 verse 3 and ending with chapter 2 verse 4)<br />
<b>John 1:3 - John 2:4</b> (same as above)<br />
<b>John 1:3-5</b> (displays verses starting with chapter 1 verse 3 through chapter 1 vs 5)<br />
<b>H1234</b> (displays the Strong's definition for the Hebrew # 1234)<br />
<b>G1234</b> (displays the Strong's definition for the Greek # 1234)<br />
<b>Jesus</b> (searches for "Jesus". all search terms assume boolean AND, i.e. "Jesus Christ" assumes "Jesus AND Christ". an word without a number is interpreted as search).<br />
</p>
<h3>Terms Excluded from Search Index</h3>
<p> "us", "these", "her", "saith", "shalt", "let", "do", "your", "we", "no", "go", "if", "at", "an", "so", "before", "also", "on", "had", "you", "there", "then", "up", "by", "upon", "were", "are", "this", "when", "thee", "their", "ye", "will", "as", "thy", "my", "me", "have", "from", "was", "but", "which", "thou", "all", "it", "with", "them", "him", "they", "is", "be", "not", "his", "i", "shall", "a", "for", "unto", "he", "in", "to", "that", "of", "and", "the"</p>
<h3>Notes:</h3>
<p>
multiple lookups can be made using a semicolon as a separator, i.e. "Ruth 1; g1234; Jesus"). <br />
<br />The list of results in the main window are sortable, just click and drag to reorder them.<br /><br />
<br />All Greek/Hebrew cross references translations are taken from the 1933 Webster's version and often are not the same as the KJV translation. <br />
<br />All source materials were taken from the <a href="http://sourceforge.net/projects/zefania-sharp/">Zefania XML Bible Project</a> on SourceForge. <br />
<br />Any Errors and Omission you find would be appreciated. Please contact me via <a href='http://www.jasonwall.org/'>www.jasonwall.org</a>.<br />
</p>
</div>
</div>
</div><!-- /page -->
</body>
</html>

View File

@ -1,3 +1,19 @@
$( document ).on( "pageinit", "#mainpage", function() {
$( document ).on( "swipeleft swiperight", "#mainpage", function( e ) {
// We check if there is no open panel on the page because otherwise
// a swipe to close the left panel would also open the right panel (and v.v.).
// We do this by checking the data that the framework stores on the page element (panel: open).
if ( $.mobile.activePage.jqmData( "panel" ) !== "open" ) {
if ( e.type === "swipeleft" ) {
$( "#searchpanel" ).panel( "open" );
} else if ( e.type === "swiperight" ) {
$( "#defaultpanel" ).panel( "open" );
}
}
});
});
$(document).ready(function()
{
$("#searchvalue").keypress(function(event) {
@ -50,16 +66,16 @@ $(document).ready(function()
// you need to do this last, otherwise the settings load resets the window height.
$(window).bind("resize", function()
{
$(".my-breakpoint.ui-grid-c .ui-block-a").css("width", 55);
$(".my-breakpoint.ui-grid-c .ui-block-b").css("width", window.innerWidth - 230);
$(".my-breakpoint.ui-grid-c .ui-block-c").css("width", 100);
$(".my-breakpoint.ui-grid-c .ui-block-a").css("width", 50);
$(".my-breakpoint.ui-grid-c .ui-block-b").css("width", window.innerWidth - 175);
$(".my-breakpoint.ui-grid-c .ui-block-c").css("width", 65);
$(".my-breakpoint.ui-grid-c .ui-block-d").css("width", 55);
$("#searchresults").css("height", window.innerHeight - 100);
return false;
});
$(".my-breakpoint.ui-grid-c .ui-block-a").css("width", 55);
$(".my-breakpoint.ui-grid-c .ui-block-b").css("width", window.innerWidth - 235);
$(".my-breakpoint.ui-grid-c .ui-block-c").css("width", 100);
$(".my-breakpoint.ui-grid-c .ui-block-a").css("width", 50);
$(".my-breakpoint.ui-grid-c .ui-block-b").css("width", window.innerWidth - 175);
$(".my-breakpoint.ui-grid-c .ui-block-c").css("width", 65);
$(".my-breakpoint.ui-grid-c .ui-block-d").css("width", 55);
$("#searchresults").css("height", window.innerHeight - 100);