Welcome, Guest
Username Password: Remember me

{Scripture1} confusing output when single verse
(1 viewing) (1) Guest
  • Page:
  • 1

TOPIC: {Scripture1} confusing output when single verse

{Scripture1} confusing output when single verse 17 Feb 2010 06:31 #1882

If a study is on a single verse of the bible, eg 1 Peter 1:3, and a start and end scripture reference is filled in for the study, then the output of {Scripture1} (and possibly scripture2) in the study details, study list and series list is confusing.

I would expect the output for a single verse to be:
1 Peter 1:3

and not
1 Peter 1:3-3

which might be take to be chapter one verse three to chapter three.

I guess before returning the string, you could do a check to see... pseudo code:

if (chapter_begin = chapter_end AND verse_begin = verse_end)
Then
(print Bookname + chapter_begin + chapter_end)

...actually - might have just found it in the code.. in site/helpers/scripture.php, somewhere around line 44:

 
if ($ch_e == $ch_b && $v_b == $v_e) {
$b3 = '';
$ch_e = '';
$b2a = '';
$v_e = '';
}
 


oo - could this be my first dev contribution!?

Re:{Scripture1} confusing output when single verse 17 Feb 2010 07:41 #1883

  • Tom
  • OFFLINE
  • Administrator
  • Posts: 860
Did you try it out? I added it to the helper file in the Trunk of the SVN. Do you think it should replace the IF that is there now?

if ($ch_e == $ch_b) {
$ch_e = '';
$b2a = '';
}


When you get a chance, give me some more next steps on Xamp - where do I extract the backup and access it with Xamp?

Thanks!

Tom
"You shall know the truth and the truth shall set you free." JC

Re:{Scripture1} confusing output when single verse 17 Feb 2010 07:48 #1884

just a quick one for now, but the following two links should help you with joomla pack restores.. use the 'kickstart' method.. _really_ easy! it's great to have this method for when you can't get an internet connection to your server!

joomlapack.net/help-and-support/document...pack-user-guide.html

joomlapack.net/help-and-support/document...-guide/item/682.html

Re:{Scripture1} confusing output when single verse 17 Feb 2010 12:51 #1889

back on the topic of this fix..
i tried it out on my test site and it seemed to work ok.

i don't think it should replace the current IF for same-chapter verse ranges. The following wikipedia page gives as close to a 'standard' as i can see, which gives the example of John 3:16 for a single verse, and John 3:16-17 for multi-verse within a chapter.

http://en.wikipedia.org/wiki/Bible_citation

Re:{Scripture1} confusing output when single verse 17 Feb 2010 14:13 #1892

  • Tom
  • OFFLINE
  • Administrator
  • Posts: 860
That's what I figured. It's been added as a condition then along with the original!

Tom
"You shall know the truth and the truth shall set you free." JC
  • Page:
  • 1
Time to create page: 0.89 seconds