TOPIC: onFocus or onBlur?

Attempting to validate input on a short text question by comparing it to a question from a previous group (different page), with both having to be identical. I have hardly any js or jquery knowledge, so I'm not sure. What's the best way to approach this?

For the trigger, I'm thinking of using either onBlur for the current question that's being validated, or onFocus for the next question which is on the same page, but I don't know how to implement either in this case.

A preemptive thanks.

The administrator has disabled public write access.

JavaScript is currently disabled.Please enable it for a better experience of Jumi.

Thanks a lot. I was thinking it needed to be specified when to check, either by losing focus on current form or gaining focus on the next one. Other options I tried alerted immediately on question load.

I'm also seeing a lot of varying differences between how answers can be referenced (#questionID,SGQ,INSERTANS,etc.). I'm not exactly sure which ones are appropriate at which times (manual is rather vague on it). Is there any resource that clarifies on this? Any glossary or resource that lists functions and syntax that is exclusive to Limesurvey?

Yeah, I use Firebug very frequently, I guess this will be just one further use for it.

On another note, I'm having difficulties implementing this in current surveys. On test survey it works perfectly, and regardless of browser used. However, on all other surveys I've added it too, not one of them works. No syntax errors or anything brought up. Here's the differences between the test survey I used that works and the surveys I added the script into:

- Multiple Groups
- Each group has a single page.
- First question for each group (and page) are the ones being validated, so:
- Question 1 for group 2 (page 2) looks at Question 1 for group 1 (page 1)

I notice in Firebug that it grabs the var from the first question just fine. However it doesn't do anything with it. I suspect it may be a problem with the selector for the second question (current #answerQQ). I've altered it a couple ways (#answerSSSSSXGGGXQQ, #questionSSSSSXGGGXQQ, #questionQQ) but no dice. No errors that I see reported, and no prompt once focus is lost from the question (or attempting to submit). Any ideas?