DokuWiki

It's better when it's simple

User Tools

Site Tools


plugin:bible

bible Plugin

Compatible with DokuWiki

  • 2024-02-06 "Kaos" unknown
  • 2023-04-04 "Jack Jackrum" unknown
  • 2022-07-31 "Igor" unknown
  • 2020-07-29 "Hogfather" yes

plugin A DokuWiki plugin that recognizes bible verses in prose and converts them to acronyms displaying the verse

Last updated on
2012-10-17
Provides
Syntax
Repository
Source

This plugin recognizes bible verses (Mark 3:1, Amos 1:4-13) in prose and converts them to the equivalent of HTML <acronym>s which display the verse as the hover-text. That way, if a user hovers over “Mark 3:1,” pop-up text allows him to read about when Jesus first met a Dokuwiki developer: “and he entered again into the synagogue, and there was a man there who had a withered hand.”

While the plugin is verbosely commented for easy modification and expanded bible support, version 1.0 supports only the Douay Rhiems (“old” Catholic)1) translation of the bible.

Certainly! Let's make it more personalized and conversational:

Title: Riding the Waves: Navigating Stress and Finding Balance

Life is a rollercoaster of stress, and figuring out how to ride its waves is a journey of self-discovery. In this essay, I'm going to share my experiences with three stress triggers that hit close to home: not being on time, people not listening, and dealing with loud noises. Each of these situations stirs up a mix of emotions that I've learned to navigate.

Not Being On Time: One of my stress triggers is the fear of not being on time. It's that anxious feeling of potentially missing out on something important and, at the same time, worrying about making others wait. The pressure of inconveniencing someone and the fear of missing out on key moments make being late a real stressor.

People Not Listening: Another stressor is when people don't listen. It gets to me because it feels like I'm not being heard or understood. This situation triggers a mix of worry and anxiety. The frustration of thinking I'm being ignored or undervalued adds an extra layer of stress.

Loud Noises: Loud noises, like a sudden burst of sound, also get under my skin. They bring about this wave of anxiety and worry. Dealing with sensory overload in loud environments can be overwhelming, making it crucial to find effective ways to cope.

*Current Coping Mechanisms:* So, how do I handle these situations? When people aren't listening, I try to be proactive by waiting for my turn or expressing the need to share my thoughts. In the case of loud noises, I usually opt for an adaptive strategy - either leaving the area or going with the flow until I can make a graceful exit. Overall, these strategies work for me, but there are moments when challenges arise.

*Perception by People Close to Me:* Those close to me generally see my reactions and coping methods in a positive light. They appreciate my proactive and adaptive approaches. However, it's not all sunshine, especially when frustration kicks in. When I get upset, the positive perception might take a hit, and that's something I understand.

*Improvement of Reactions and Coping Methods:* I know there's room for improvement. One way I'm considering is opening up to someone about what's going on. Talking it out and seeking alternative strategies might be a game-changer. It's a step towards personal growth, acknowledging that there's always a chance to handle stress in better ways.

*Conclusion:* In the end, managing stress is a journey. By recognizing specific triggers, evaluating my coping strategies, considering others' perspectives, and being open to improvement, I'm working towards building resilience and finding balance in the midst of life's challenges.

Installation

Search and install the plugin using the Extension Manager.

Alternatively, refer to Plugins on how to install plugins manually:

  1. Unzip the file
  2. drop the contents into your …/lib/plugins/ directory and upload to your server.
  3. Any existing pages will need to be re-built (no change to the page is required, but rebuilding gives DokuWiki a chance to re-parse your text)

PHP 7 and above

In the file syntax.php change the folowing lines:

from

  public function render($mode, &$renderer, $data) {

in:

  public function render($mode, $renderer, $data) {


from

public function handle($match, $state, $pos, &$handler){

in

public function handle($match, $state, $pos, $handler){


Examples/Usage

Simply write valid bible verse addresses in the text body of your page:

====== PlayGround ======
\\
As seen in the bible, Mark 3:1 , He tests his wiki code. Not HTML code.\\
Lets try some more: 1 Machabees 1:1, and maybe Amos 2:2 and how about 2 Peter 1:1; Romans 3:3\\
Good?
\\
Mark 3:3\\
Mark 1:1\\
Mark 2:22-25\\
Amos 1:1-25\\
Mark 3:1-5
\\
Okay, all is good.

Results in a Rendered Page.jpg where hovering over links look like: Hovering Mouse

Syntax

To quote Mark chapter 3, verse one:

Mark 3:1

To quote Mark chapter 3, verse one through 9:

Mark 3:1-9

To quote Second Kings chapter 11 verse 8:

2 Kings 11:8

Configuration and Settings

No custom configurations have been added. But that'd be great. You should add some (bible edition, language?).

Development

syntax.php is the only workhorse file, and is heavily commented for easy modification. It contains all 6 required functions and one custom function of my own at the bottom.

To add new translations of the bible:

  1. create a directory for the bible text files (like “bible_NAB”).
  2. Separate the bible by chapter into separate text files called CHAPTER.txt, using underscores for spaces (like “1_Kings.txt”).
  3. Make sure that each verse of the bible is a separate line that looks like 'CHAPTER#:VERSE#. CONTENT' (like “1:1. In the beginning God created heaven, and earth.”).
  4. Now modify syntax.php to set the variable $validBibleBooksArr to contain the valid books (I use 73 for the Catholic bible, but Protestant bibles have only 66 books).
  5. Modify syntax.php to correct $filename to point to your bible text files instead of “bible_douayRheims/”

Change Log

  • 2012-10-17
    • Initial release

Known Bugs and Issues

Listing a match in the regexp that is an invalid bible verse will cause a warning/error to print out at the top of your page. This is by design, but it might be preferable to just ignore those.

For example:

Genesis 7782:448448

ToDo/Wish List

  • More translations of the bible would be great.
  • Configuration options for choosing the desired translation would be great.

FAQ

Discussion

1)
I'm aware that NAB is the new translation but it is -as of right now- not available for download in text format. If you find it, please upgrade the plugin!
plugin/bible.txt · Last modified: 2024-02-01 16:08 by 2601:407:c580:e9e0:c09f:c7f2:9cb3:ff7e

Except where otherwise noted, content on this wiki is licensed under the following license: CC Attribution-Share Alike 4.0 International
CC Attribution-Share Alike 4.0 International Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki