Bug 28583 - Temporarily disable CSS and Javascript for pages doesn't work
Summary: Temporarily disable CSS and Javascript for pages doesn't work
Status: NEW
Alias: None
Product: Koha
Classification: Unclassified
Component: Staff interface (show other bugs)
Version: Main
Hardware: All All
: P5 - low normal (vote)
Assignee: Bugs List
QA Contact: Testopia
URL:
Keywords:
Depends on: 14004
Blocks:
  Show dependency treegraph
 
Reported: 2021-06-17 10:02 UTC by Séverine Queune
Modified: 2022-12-16 22:00 UTC (History)
3 users (show)

See Also:
Change sponsored?: ---
Patch complexity: ---
Documentation contact:
Documentation submission:
Text to go in the release notes:
Version(s) released in:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Séverine Queune 2021-06-17 10:02:24 UTC
Bug 14004 introduced the ability to temporarily disable added CSS and Javascript in OPAC and interface by adding ?DISABLE_SYSPREF_IntranetUserCSS=1 for example to the url, but it doesn't work for pages referring to specific ids, for example :
  -https://kohapro.bulac.fr/cgi-bin/koha/circ/circulation.pl?borrowernumber=xxx
  -https://kohapro.bulac.fr/cgi-bin/koha/catalogue/detail.pl?biblionumber=xxx

I thought I was because two '?' in the same url can't be used and try to replace it by '&' but it still doesn't work.
Comment 2 Fridolin Somers 2021-06-17 14:28:50 UTC
I dont reproduce in master

With IntranetUserCSS :
  body { background-color:red; }

Using :
/cgi-bin/koha/catalogue/detail.pl?biblionumber=1&DISABLE_SYSPREF_IntranetUserCSS=1

It works perfect, no red color.
Comment 3 Katrin Fischer 2021-06-19 11:37:44 UTC
Could the difference be related to setup?
Comment 4 Fridolin Somers 2022-12-16 20:11:04 UTC
Still valid ?
Comment 5 Fridolin Somers 2022-12-16 22:00:15 UTC
Ahhh I found a case where it does not work.

When authentication is mandatory, with preference OpacPublic disabled.
The authentication page is aked from C4::Auth::checkauth() and we do not execute the code from Bug 14004 in C4::Auth::get_template_and_user()

Do we move code at the beginning of C4::Auth::get_template_and_user() ?