Logo Bib[le] (WWW/PHP)
Bib[le] (WWW/PHP)

Bib[le] (WWW/PHP)

Current Version: 1.3.6
41
Unique Views
0
Free Downloads
0
Donation Downloads

Bib v1.36

A fast, efficient web-based Bible reading and study application. Created by Jason Page yahbib.com ---

Overview

Bib is a powerful Bible study tool that allows users to search, read, and study Scripture across multiple translations. Built with performance in mind, Bib uses an indexed data loading system to deliver lightning-fast search results and verse lookups.

Features

Core Functionality

  • Verse Reference Lookup - Quickly find any Bible verse by book, chapter, and verse number
  • Context Verses - View verses before and after your selected verse for better context
  • Keyword Search - Search for any word or phrase across all 66 books of the Bible
  • Multiple Translations - Access 10 different Bible translations simultaneously:
  • - King James Bible (KJV) - American Standard Version (ASV) - Douay-Rheims Bible (DRB) - Darby Bible Translation (DBT) - English Revised Version (ERV) - Webster Bible Translation (WBT) - World English Bible (WEB) - Young's Literal Translation (YLT) - American King James Version (AKJ) - Weymouth New Testament (WNT)

    Study Tools

  • Study Notes Panel - Draggable and resizable floating panel for taking notes
  • Local Storage - Notes are automatically saved to your browser
  • Server Backup - Save notes anonymously to the server and share via link
  • Download Notes - Export your study notes as timestamped text files
  • Results Management

  • Advanced Filtering - Filter search results by verse reference, translation, or text
  • Live Highlighting - Search terms are highlighted in filtered results
  • CSV Export - Download search results as CSV files for offline study
  • URL Sharing - Share searches via URL with all parameters preserved
  • Analytics

  • Hit Tracking - Total page visits, human visits, and unique human visitors
  • Search Counter - Track total searches performed
  • Bot Detection - Automatically filters bot traffic from human statistics
  • Performance

  • 2,196x faster page loads - Optimized from ~3000ms to ~1.4ms
  • Indexed Data System - Pre-generated indexes split Bible data by book
  • Lazy Loading - Only loads required book data for each search
  • Memory Efficient - Loads 1-2MB per book instead of entire 37MB file
  • Requirements

  • PHP 7.0 or higher
  • Web server (Apache, Nginx, or similar)
  • File write permissions for counters directory
  • 37MB disk space for Bible data
  • 29MB disk space for generated indexes
  • Installation

  • Upload files to your web server directory
  • Generate Bible indexes (required for first-time setup):
  • bash
       php generate_indexes.php
       
    This creates the bible_index/ directory with 51 index files for fast lookups.
  • Set permissions for the counters directory:
  • bash
       chmod 755 counters/
       
  • Access the application via your web browser
  • Usage

    Searching for Verses

  • Select "Verse Reference" query type
  • Choose a book from the dropdown menu
  • Enter the chapter and verse numbers
  • Optionally set context verses (verses before/after)
  • Select one or more translations to display
  • Click Query
  • Keyword Searching

  • Select "Keyword Search" query type
  • Enter your search term (e.g., "faith", "love", "beginning")
  • Select one or more translations to search
  • Click Query
  • Using Study Notes

  • The Study Notes panel appears on the right side (desktop only)
  • Type notes directly - they auto-save to your browser
  • Drag the panel by the header to reposition it
  • Resize by dragging the bottom-right corner
  • Download notes as a text file with timestamp
  • Save to Server to get a shareable link (anonymous)
  • View Saved Notes to see all server-saved notes
  • Filtering Results

  • Use the filter box to narrow down results
  • Choose to filter all columns or specific ones
  • Matching text is highlighted in yellow
  • Result count updates to show filtered/total results
  • Exporting Data

  • Copy URL - Share your exact search with others
  • Download CSV - Export results to spreadsheet software
  • Download Notes - Save study notes as timestamped .txt files
  • Technical Details

    Architecture

  • Frontend: Vanilla JavaScript, responsive CSS
  • Backend: PHP 7+ with efficient file handling
  • Data Storage: CSV format with JSON indexes
  • Session Management: LocalStorage for notes, file-based counters
  • File Structure

    
    bib/
    ├── index.php              # Main application
    ├── bible_loader.php       # Efficient data loading class
    ├── generate_indexes.php   # Index generation script
    ├── notes_save.php         # Server-side note saving
    ├── notes_list.php         # View all saved notes
    ├── notes_view.php         # View individual notes
    ├── changelog.php          # Version history viewer
    ├── styles.css             # Application styles
    ├── bibles.csv             # Main Bible data (37MB)
    ├── bible_index/           # Generated index files (29MB)
    │   ├── translations.json
    │   ├── book_index.json
    │   └── book_*.json       # Individual book indexes (66 files)
    ├── counters/              # Hit tracking data
    └── CHANGELOG.md          # Version history
    

    Performance Optimization

    Version 4.0 introduced a major performance overhaul:
  • Before: Loading entire 37MB file on every page load (~3000ms)
  • After: Loading only metadata on page load (~1.4ms)
  • Method: Pre-generated JSON indexes split by book
  • Memory: Reduced from 37MB to 1-2MB per search
  • Result: 2,196x performance improvement
  • Browser Compatibility

  • Modern browsers (Chrome, Firefox, Safari, Edge)
  • LocalStorage support required for notes feature
  • Clipboard API for copy/share features
  • Responsive design for mobile and desktop
  • Development

    Generating Indexes

    After modifying the Bible data file, regenerate indexes:
    bash
    php generate_indexes.php
    
    This creates:
  • bible_index/translations.json - List of all translations
  • bibleindex/bookindex.json - Book metadata
  • bibleindex/book*.json - Individual book data (66 files)

Testing Performance

Run the performance test script:
bash
php test_performance.php

Changelog

See CHANGELOG.md for version history and updates. Current version: v1.36 (4.0)

Credits

Developer: Jason Page Organization: Amfile.org Version: 1.36 License: Open source

Support

For questions, issues, or feature requests, please contact Amfile.org. --- Bib v1.36 - Fast, efficient Bible study for everyone.

Download Options

Donation-Based Downloads: Support development with a donation via PayPal to receive source code and compiled binaries.

Source Code (Donation-Based)

Changelog

Changelog

Version 1.3.6 (2025-11-21)

Major Performance Optimization

  • 2,196x faster initial page load (from ~3000ms to ~1.4ms)
  • Implemented indexed data loading system to avoid reading entire 37MB file on every page load
  • Created pre-generated index files that split bible data by book
  • Only loads metadata (translations + book names) on initial page load
  • Lazy-loads specific book data only when performing searches
  • New Files

  • generate_indexes.php - Script to generate index files from bible data
  • bible_loader.php - Efficient data loading class
  • bible_index/ - Directory containing 51 index files (~29MB total)
  • test_performance.php - Performance testing and comparison script
  • PERFORMANCE_OPTIMIZATION.md - Detailed documentation
  • Bug Fixes

  • Fixed UTF-8 encoding issues that were preventing some books (like Exodus) from being properly indexed
  • Used JSONINVALIDUTF8_SUBSTITUTE flag to handle malformed UTF-8 characters
  • Setup Required

    Run php generate_indexes.php once to generate the index files before using version 4.0

    Technical Changes

  • Modified index.php lines 95-136 to use BibleLoader class instead of loading entire file
  • Verse lookups now load only 1-2MB per book instead of entire 37MB file
  • Keyword searches load books sequentially to reduce memory usage
  • No breaking changes to functionality, URLs, or user interface
  • ---

    Version 1.x (Previous)

  • Bible verse lookup with context verses
  • Keyword search across all translations
  • 10 Bible translations support
  • Study notes with server saving
  • CSV export functionality
  • URL sharing