Forum

This forum is now read-only. Support is provided at https://wordpress.org/support/plugin/sermon-browser/

Please consider registering
guest

sp_LogInOut Log In sp_Registration Register

Register | Lost password?
Advanced Search

— Forum Scope —




— Match —





— Forum Options —





Minimum search word length is 3 characters - maximum search word length is 84 characters

sp_Feed Topic RSS sp_TopicIcon
Adding Second Bible Passage Bug
11 June, 2013
10:26 am
maalamb
New Member
Members
Forum Posts: 1
Member Since:
14 March, 2012
sp_UserOfflineSmall Offline

When adding the first Bible Passage when the "From" book field is selected the "To" book field is populated with the same book

 

But when you do this with the second reading the "To" book field is populated with the book selected for the first reading

 

Peter Lamb

 

11 June, 2013
7:42 pm
Ben Miller
Appleton, WI, USA
Moderator
Members

Moderators
Forum Posts: 1628
Member Since:
18 June, 2009
sp_UserOfflineSmall Offline

Peter,

Agreed; I've always found this a little annoying.  I think I've got a fix worked out for it.  The changes are to the "wp-content/plugins/sermon-browser/sb-includes/admin.php" file.

In the file, there is a PHP function named sb_new_sermon that begins on line 1314 (in version 0.45.8).  Inside that PHP function, there is some Javascript code.  We need to make changes to two Javascript functions inside the sb_new_sermon PHP function.

Javascript function addPassage, begins on line 1632

OLD code:

http://pastebin.com/LVH9m3Dj

NEW code:

http://pastebin.com/MbudW6mN

 

There is one more Javascript function that needs to be changed.  Continued in next post.

Ben Miller, Pathways Church, Appleton, Wisconsin, USA
Read the new FAQ, last updated 11/21/2013
Announcing version 0.45.12

11 June, 2013
7:46 pm
Ben Miller
Appleton, WI, USA
Moderator
Members

Moderators
Forum Posts: 1628
Member Since:
18 June, 2009
sp_UserOfflineSmall Offline

The second Javascript function that needs to be changed in admin.php:

Javascript function syncBook, begins on line 1643:

OLD code:

http://pastebin.com/m2KZNqhW

NEW code:

http://pastebin.com/UXQcnzcP

 

If you try out the fix yourself, let me know how it works for you.  I'll put this fix into the next version of Sermon Browser.

Thanks for the opportunity to learn something about jQuery.  :)

Ben Miller, Pathways Church, Appleton, Wisconsin, USA
Read the new FAQ, last updated 11/21/2013
Announcing version 0.45.12

Forum Timezone: Europe/London

Most Users Ever Online: 381

Currently Online:
11 Guest(s)

Currently Browsing this Page:
1 Guest(s)

Top Posters:

Rich Brown: 358

Matt Schlueter: 93

Mindy: 72

Don Johnson: 65

anointed: 57

0be1: 55

Member Stats:

Guest Posters: 7

Members: 3188

Moderators: 1

Admins: 1

Forum Stats:

Groups: 1

Forums: 2

Topics: 1713

Posts: 7499

Newest Members:

marktest, deatles50, ValeriaGoodriz, dapedPup, oapedPup, Margarettoimb

Moderators: Ben Miller: 1628

Administrators: Mark Barnes: 435