It seems your else-statements have syntax errors.
In reply to Re: Backreferences by Anonymous Monk in thread Backreferences by OCTweak