Bible Passage System V2.0

By napa182 on Feb 29, 2008

Ok Heres Version 2 Of The Bible Passage System. I redid the whole Script I gave it a diff look And Diff options. Copy'paste into a new remote click either in ur menubar or in a channel to open. If You Still Want Version 1 you can get it from this link. http://www.mywebs.biz/Uploads/V1BiblePassageDialog.txt

Heres A pic of my Version 2.
Image
I hope you all like version 2..
Enjoy....

dialog bp2 {
  title "Bible Passage System V2.0"
  size -1 -1 187 127
  option dbu
  box "Old Testament Book's", 1, 2 2 63 62
  combo 2, 6 11 55 50, size vsbar
  box "New Testament Book's", 3, 68 2 63 62
  combo 4, 72 11 55 50, size vsbar
  box "Chapter  /  Verse", 5, 134 2 52 30
  edit "", 6, 138 11 21 9, read autohs center
  edit "", 7, 162 11 21 9, read autohs center
  button ">", 10, 149 21 10 8, flat
  button "<", 8, 138 21 10 8, flat
  button ">", 9, 173 21 10 8, flat
  button "<", 11, 162 21 10 8, flat
  box "Old/New On/Off", 12, 134 34 52 30
  radio "Old Test On", 13, 139 43 40 9
  radio "New Test On", 14, 139 53 42 9
  box "Bible Passage", 15, 2 65 184 61
  button "Clip", 17, 31 113 20 10, flat
  button "Msg", 18, 58 113 20 10, flat
  button "Find", 19, 84 113 20 10, flat
  button "Back", 20, 110 113 20 10, flat
  button "Next", 21, 135 113 20 10, flat
  button "Exit", 22, 161 113 20 10, flat cancel
  button "Clear", 23, 6 113 20 10, flat
  list 16, 6 73 176 38, size vsbar
}
alias bp2 { dialog $iif($dialog(bp2),-v,-md) bp2 bp2 }
menu menubar,channel {
  .Bible Passage System V2.0:{ bp2 }
}
on *:load: { 
  echo 12 -a You Have Just Loaded Napa182's Bible Passage System V2.0 
  echo 12 -a A Script0rs Inc. Production 
  echo -a 14,1(14,1?15,1?0,1?0,1? ?ט?Ǯ0??X׻ ?0,1?15,1?14,1?)?
}
on *:dialog:bp2:close:0:{ unset %biblebooks* %newt %oldt %chaptern %versen %1passage }
on *:dialog:bp2:init:0:{
  inc %chaptern 1
  inc %versen 1
  did -ra bp2 6 %chaptern
  did -ra bp2 7 %versen
  if (!%biblebooks) { set %biblebooks Genesis Exodus Leviticus Numbers Deuteronomy Joshua Ruth 1Samuel 2Samuel 1Kings 2Kings 1Chronicles 2Chronicles Ezra Nehemiah Esther Job Psalm Proverbs Ecclesiastes Songofsolomon Isaiah Jeremiah Lamentations Ezekiel Daniel Joel Amos Obadiah Jonah Micah Nahum Habakkuk Zephaniah Haggai Zechariah Malachi }
  if (!%biblebooks2) { set %biblebooks2 Matthew Mark Luke John Acts Romans 1Corinthians 2Corinthians Galatians Ephesians Philippians Colossians 1Thessalonians 2Thessalonians 1Timothy 2Timothy Titus Philemon Hebrews James 1Peter 2Peter 1John 2John 3John Jude Revelation }
  var %otb = $gettok(%biblebooks,1-,32)
  var %boo = $numtok(%otb,32), %oh = 1
  while ( %oh <= %boo ) {
    did -a bp2 2 $gettok(%otb,%oh,32)
    inc %oh
  }
  var %ntb = $gettok(%biblebooks2,1-,32)
  var %bo = $numtok(%ntb,32), %ooh = 1
  while ( %ooh <= %bo ) {
    did -a bp2 4 $gettok(%ntb,%ooh,32)
    inc %ooh
  }
  if (%oldt) { did -c bp2 13 | did -e bp2 2  }
  if (!%oldt) { did -b bp2 2 | did -u bp2 13 }
  if (%newt) { did -c bp2 14 | did -e bp2 4 }
  if (!%newt) { did -b bp2 4 | did -u bp2 14 }
  if (%chaptern <= 1) { did -b bp2 8 }
  if (%versen <= 1) { did -b bp2 11,20 }
}
on *:dialog:bp2:sclick:*:{
  if ($did == 13) { set %oldt on | did -c bp2 13 | did -e bp2 2 | unset %newt | did -u bp2 14 | did -b bp2 4 }
  if ($did == 14) { set %newt on | did -c bp2 14 | did -e bp2 4 | unset %oldt | did -u bp2 13 | did -b bp2 2 }
  if ($did == 10) { inc %chaptern 1 | did -ra bp2 6 %chaptern | did - $+ $iif(%chaptern >= 1,e) bp2 8 | did -r bp2 16 }
  if ($did == 8) { dec %chaptern 1 | did -ra bp2 6 %chaptern | did - $+ $iif(%chaptern <= 1,b,e) bp2 8 | did -r bp2 16 }
  if ($did == 9) { inc %versen 1 | did -ra bp2 7 %versen | did - $+ $iif(%versen >= 1,e) bp2 11,20 | did -r bp2 16 }
  if ($did == 11) { dec %versen 1 | did -ra bp2 7 %versen | did - $+ $iif(%versen <= 1,b,e) bp2 11,20 | did -r bp2 16 }
  if ($did == 23) { did -r bp2 16 | unset %1passage }
  if ($did == 17) { clipboard %1passage }
  if ($did == 18) {
    if (!%1passage) {
      noop $input(No Passage To Message,uwo,Error)
    }
    elseif (!%newt) {
      msg $active 14,1[12,1?0,1:: Book $did(2).text ::12,1?14,1]14,1[12,1?0,1:: Chapter $did(6).text ::12,1?14,1]14,1[12,1?0,1:: %1passage ::12,1?14,1]14,1[12,1?0,1:: Bible Script By :: Napa182 0,1::12,1?14,1] 
    }
    elseif (!%oldt) {
      msg $active 14,1[12,1?0,1:: Book $did(4).text ::12,1?14,1]14,1[12,1?0,1:: Chapter $did(6).text ::12,1?14,1]14,1[12,1?0,1:: %1passage ::12,1?14,1]14,1[12,1?0,1:: Bible Script By :: Napa182 0,1::12,1?14,1] 
    }
  }
  if ($did == 19) {
    unset %next
    if (!%newt) && (!%oldt) {
      noop $input(Please Pick Either An Old Or New Testament Book,uwo,Error)
    }
    elseif (!%oldt) {
      if (!$did(4).seltext) {
        noop $input(Please Pick Either An New Testament Book,uwo,Error)
      }
      else {
        if ($sock(bverse)) .sockclose bverse
        did -r bp2 16
        set %verse $did(4).seltext $+ $chr(43) $+ $did(6).text $+ $chr(37) $+ 3A $+ $did(7).text
        sockopen bverse bibleresources.bible.com 80
      }
    }
    elseif (!%newt) {
      if (!$did(2).seltext) {
        noop $input(Please Pick Either An Old Testament Book,uwo,Error)
      }
      else {
        if ($sock(bverse)) .sockclose bverse
        did -r bp2 16
        set %verse $did(2).seltext $+ $chr(43) $+ $did(6).text $+ $chr(37) $+ 3A $+ $did(7).text
        sockopen bverse bibleresources.bible.com 80
      }
    }
  }
  if ($did == 21) { 
    set %next on
    if (!%newt) && (!%oldt) {
      noop $input(Please Pick Either An Old Or New Testament Book,uwo,Error)
    }
    elseif (!%oldt) {
      if (%notfound) {
        unset %notfound
        set %versen 1
        inc %chaptern 1
        did -ra bp2 7 %versen
        did -ra bp2 6 %chaptern
        did - $+ $iif(%versen <= 1,b,e) bp2 11,20
        did - $+ $iif(%chaptern <= 1,b,e) bp2 8
        if ($sock(bverse)) .sockclose bverse
        did -r bp2 16
        set %verse $did(4).seltext $+ $chr(43) $+ $did(6).text $+ $chr(37) $+ 3A $+ $did(7).text
        sockopen bverse bibleresources.bible.com 80
      }
      else {
        if (!%notfound) {
          inc %versen 1
          did -ra bp2 7 %versen
          did - $+ $iif(%versen >= 1,e) bp2 11,20
          if (!%oldt) {
            if ($sock(bverse)) .sockclose bverse
            did -r bp2 16
            set %verse $did(4).seltext $+ $chr(43) $+ $did(6).text $+ $chr(37) $+ 3A $+ $did(7).text
            sockopen bverse bibleresources.bible.com 80
          }
        }
      }
    }
    elseif (!%newt) {
      if (%notfound) {
        unset %notfound
        set %versen 1
        inc %chaptern 1
        did -ra bp2 7 %versen
        did -ra bp2 6 %chaptern
        did - $+ $iif(%versen <= 1,b,e) bp2 11,20
        did - $+ $iif(%chaptern <= 1,b,e) bp2 8
        if ($sock(bverse)) .sockclose bverse
        did -r bp2 16
        set %verse $did(2).seltext $+ $chr(43) $+ $did(6).text $+ $chr(37) $+ 3A $+ $did(7).text
        sockopen bverse bibleresources.bible.com 80
      }
      else {
        if (!%notfound) {
          inc %versen 1
          did -ra bp2 7 %versen
          did - $+ $iif(%versen >= 1,e) bp2 11,20
          if ($sock(bverse)) .sockclose bverse
          did -r bp2 16
          set %verse $did(2).seltext $+ $chr(43) $+ $did(6).text $+ $chr(37) $+ 3A $+ $did(7).text
          sockopen bverse bibleresources.bible.com 80
        }
      }
    }
  }
  if ($did == 20) {
    if (!%newt) && (!%oldt) {
      noop $input(Please Pick Either An Old Or New Testament Book,uwo,Error)
    }
    else {
      dec %versen 1
      did -ra bp2 7 %versen
      did - $+ $iif(%versen <= 1,b,e) bp2 11,20
      if (!%oldt) {
        if ($sock(bverse)) .sockclose bverse
        did -r bp2 16
        set %verse $did(4).seltext $+ $chr(43) $+ $did(6).text $+ $chr(37) $+ 3A $+ $did(7).text
        sockopen bverse bibleresources.bible.com 80
      }
      elseif (!%newt) {
        if ($sock(bverse)) .sockclose bverse
        did -r bp2 16
        set %verse $did(2).seltext $+ $chr(43) $+ $did(6).text $+ $chr(37) $+ 3A $+ $did(7).text
        sockopen bverse bibleresources.bible.com 80
      }
    }
  }
  if ($did == 2) { 
    did -r bp2 4,16 
    set %chaptern 1
    set %versen 1
    did -ra bp2 6 %chaptern
    did -ra bp2 7 %versen
    did - $+ $iif(%versen <= 1,b,e) bp2 11,20
    did - $+ $iif(%chaptern <= 1,b,e) bp2 8
    var %ntb = $gettok(%biblebooks2,1-,32)
    var %bo = $numtok(%ntb,32), %ooh = 1
    while ( %ooh <= %bo ) {
      did -a bp2 4 $gettok(%ntb,%ooh,32)
      inc %ooh
    }
  }
  if ($did == 4) { 
    did -r bp2 2,16 
    set %chaptern 1
    set %versen 1
    did -ra bp2 6 %chaptern
    did -ra bp2 7 %versen
    did - $+ $iif(%versen <= 1,b,e) bp2 11,20
    did - $+ $iif(%chaptern <= 1,b,e) bp2 8
    var %otb = $gettok(%biblebooks,1-,32)
    var %boo = $numtok(%otb,32), %oh = 1
    while ( %oh <= %boo ) {
      did -a bp2 2 $gettok(%otb,%oh,32)
      inc %oh
    }   
  }
}
on *:SOCKOPEN:bverse: {
  sockwrite -nt $sockname GET /passagesearchresults.php?passage1= $+ %verse $+ &version1=9 HTTP/1.1
  sockwrite -nt $sockname Host: bibleresources.bible.com
  sockwrite -nt $sockname $crlf
}
on *:SOCKREAD:bverse: {
  if ($sockerr) {
    echo -a Socket Error: $sockname
  }
  else { 
    var %bible
    sockread %bible
    if (%next) && (*not found* iswm %Bible) {
      set %notfound on
      did -ra bp2 16 Please Click Next To Go To The Next Chapter.
      unset %verse %next
      sockclose bverse
    }
    elseif (!%next) && (*not found* iswm %Bible) {
      set %notfound on
      did -ra bp2 16 Sorry No Such Bible Passage.
      unset %verse  
      sockclose bverse
    }
    if (*<sup id=* iswm %bible ) {
      var %passage Verse $htmlfree(%bible)
      set %1passage Verse $htmlfree(%bible)
      var %passage $instok(%passage,|,10,32)
      var %passage $instok(%passage,|,20,32)
      var %passage $instok(%passage,|,30,32)
      var %passage $instok(%passage,|,40,32)
      var %passage $instok(%passage,|,50,32)
      var %wbible = $gettok(%passage,1-,124)
      var %o = $numtok(%wbible,124), %ot = 1
      while ( %ot <= %o ) {
        did -a bp2 16 $gettok(%passage,%ot,124)
        inc %ot
        unset %verse %next
        sockclose bverse
      }    
    }
  }
}
alias htmlfree { 
  var %b,%p 
  %p = $regsub($1-,/[^<]*>|<[^>]*>|<[^>]*/g,$chr(32),%b)
  %b = $remove(%b,&nbsp;) 
  return %b 
}

Comments

Sign in to comment.
napa182   -  Jul 24, 2008

yeah the website changed a number on the look up. script should be fixed now

glucht23  -  Apr 30, 2014

not working for me... I'd love to see this script up and running again let me know if it gets fixed :)

Sign in to comment

H_M   -  Jul 23, 2008

This script doesn\'t work for me, I don\'t know why.

-Update-

Still doesn\'t work......

 Respond  
guest598594   -  Jul 07, 2008

I had to change

sockwrite -nt bverse GET /passagesearchresults.php?passage1=John+1%3A1&version1=31 HTTP/1.1

to

sockwrite -nt bverse GET /passagesearchresults.php?passage1=John+1%3A1&version1=9 HTTP/1.1
 Respond  
AdrianF   -  Jun 13, 2008

life*

 Respond  
AdrianF   -  Jun 13, 2008

Korvin, Your A Bitch. You Need To Stfu And Appreaciete Like Nigga.

 Respond  
EL   -  Apr 19, 2008

LOL eugene change that fuckin pic man.Wd napa to bad we wont get to see anymore of your codes=/

 Respond  
napa182   -  Mar 05, 2008

Scakk said:

napa182 -- Perhaps if there is text in the box ( box where passage shows ) and you choose another testament , book or verse it should empty the box.

Yeah i know what you mean and i fixed that

 Respond  
Scakk   -  Mar 05, 2008

mountaindew -- It switches list from Old Testament to New Testament.

napa182 -- Perhaps if there is text in the box ( box where passage shows ) and you choose another testament , book or verse it should empty the box.

 Respond  
guest598594   -  Mar 05, 2008

What\'s old/new on/off do?

 Respond  
EL   -  Mar 05, 2008

P.S: I hate korvin\'s attitude an everything it stands for.

 Respond  
EL   -  Mar 05, 2008

i hate jesus and everything he stands for.

loL @ korvin stfu dude no one cares what you like or dislike ya little punk just test the damn script an rate it or don\'t,your personal view on GOD means just about sh here bud.Dumb s.

@ Napa182 woot awesome updates man love the new version glad i go tto test it before you released it lol still a 10 in my book.`-.-

 Respond  
ShAmPi   -  Mar 05, 2008

I don\'t hate jesus ;)
But that\'s just because I don\'t believe at all.
Besides that fact that nobody cares about.
Your script is damn nicely done and should be rated for the scripting. And not enterily because someone \"hates\" jesus.

I give you my props! And a 10 ;)

 Respond  
napa182   -  Mar 05, 2008

Korvin said:

i hate jesus and everything he stands for.

um thats nice to know....

 Respond  
Korvin   -  Mar 04, 2008

i hate jesus and everything he stands for.

 Respond  
SnoooP   -  Mar 04, 2008

10/10 works perfect scripted to perfection :D

 Respond  
napa182   -  Mar 04, 2008

Version 2 Of My Bible Passage System....

 Respond  
napa182   -  Mar 02, 2008

Thank you for all the comments..

 Respond  
Callison1   -  Mar 02, 2008

This script is very nice. I\'m not religious (No real point in saying that but everyone else did) and I don\'t own a bible, at least now I can easily look things up I hear on the TV. Great Scripting 10/10

 Respond  
Jonesy44   -  Mar 02, 2008

Nice work napa!
Gotta agree, im not a very religious person, but hey, on the scripting side of things, dam good job!

 Respond  
EL   -  Mar 01, 2008

Napa dude seriously nice work i like this alot even tho im not religious.Its clean its fast its accurate its diverse and its acually usefull to me in some extent(Stories an characters an stuff) i get alot of insperation from myths an religion(Note im not puttin the two together so relax ppl)covered my ass there eh?.any way man where you at now?.Nyx said shewas watchin ya test and i got my security bots up an running now i wanna start somethin OTHER then effin protections rotfl.Any ways man great work on this again.\"Rate it or Hate it?\"...10/10.`-.-

 Respond  
bourneident   -  Mar 01, 2008

nice work but could you make one for Buddha more specifically Dhammapada: The Sayings of Buddha
which i can send to you a txt file of ones already done if you find me on irc.xeromem.com #games-r-us to use as an example

 Respond  
Are you sure you want to unfollow this person?
Are you sure you want to delete this?
Click "Unsubscribe" to stop receiving notices pertaining to this post.
Click "Subscribe" to resume notices pertaining to this post.