Bad Script on Text Instance editing form?

You are here

Haruo's picture

Every time, for the last several days, that I have opened the link to "Edit Hymn Text Instance", my browser has virtual frozen up, at least for the window in question, and eventually a warning box opens that tells me that a Script on the page in question has stopped working, asking if I want to stop the script, and warning that if I don't the computer may become unresponsive. When I then say to stop the script, eventually it apparently does so and then it functions reasonably well from that point on. This does not happen when I am editing a Tune Instance or a Person. It happens on my home computer with all four of my browsers (IE, Firefox, Safari and Chrome), and it also happens on other computers, so it's not a problem specific to my machine. It has drastically slowed my progress in working on the AGO Founders Hymnal's texts.


Comments

It looks like the issue is caused by the comboboxes in the "Text Persons" section. The form builds a list of names of people in instances that are associated with the same authority. And in some cases, this list can be very large, leading to a lot of unnecessary javascript processing. This feature was added in July of last year, so I'm surprised it has not caused a problem until now (it is more noticeable on older computers that do not execute the javascript as quickly).

I think that using an autocomplete box instead of a pre-populated combobox would speed things up. I'll see what I can do.

Brian Vanderwal
Hymnary.org Software Developer

Thanks, Brian!

Haruo

I discovered that it was also treating instances not connected to any authority as one giant hymnal, thus presenting far too many (irrelevant) options. That was the real slowdown, but I also changed it to use an autocomplete if there were more than 30 options.

That made all the difference in the world.

One other thing someone could do to make editing quicker and more often correct would be to put a link to the LOC authority lookup page (here) on the "Add New Person" page, preferably by making "[Library of Congress format]" a live link. All too often I get to that point only to discover that the person who wrote the song is not in the database, and then I have to either fudge the LOC part and guess, or go through all kinds of hoops to get to the LOC page in question. If the live link were there I would not be nearly so tempted to skip it, which occasionally results in wrongly formatting a name (e.g. I just now entered "Jane La Rowe", and went through a bunch of hoops only to discover that the LOC doesn't even have a listing for her (which I find surprising, since she has published music readily googlable). The question in such a case is whether her last name should be La Rowe or Rowe; I found other La Rowes (through Google, not LOC) for whom the La was part of the last name, so I made Jane "LaRowe_J", but the whole process would have been speeded up had there been a link to LOC on the page I started from. Thanks in advance.