When an unauthenticated user goes to report a problem, they're first prompted to login, then they have to click the "report a problem" link a second time and now the value of the $referer variable is going to be opac-user.pl and not the original page. Steps to recreate: - enter a KohaAdminEmailAddress and set OPACReportProblem to Allow - as an unauthenticated user visit any page other than your account (opac-user.pl) e.g. search results (opac-search.pl) or a bib detail (opac-detail.pl) - select the "report a problem" link at the bottom - you're interrupted by the user login process, complete your authentication - you land on the user account page opac-user.pl - if you select "report a problem" again now, the "problempage" value on the form will be some form of "/cgi-bin/koha/opac-user.pl..." and not the original page you attempted to report There is a work around—users can return to where they originally had the problem and click "report a problem" there, but that's not intuitive nor user friendly.
This works for me on master when the OPACBaseURL is correctly set.
FWIW we have OPACBaseURL set and this still does not work, but I believe it is due to CAS authentication. The problem page is lost after passing through CAS authentication, whose end result is always the opac-user.pl page no matter where you started from.