Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

session_login.cgi doesn't print footer #1691

Closed
michaelbaisch opened this issue Jan 11, 2024 · 5 comments
Closed

session_login.cgi doesn't print footer #1691

michaelbaisch opened this issue Jan 11, 2024 · 5 comments

Comments

@michaelbaisch
Copy link

Hello,

I wanted to use the Theme Extension feature with script.js to modify the login page. Even though it was mentioned here that is should work, I didn't see any js in the login page.

As far as I can tell the problem is with this line

((!$miniserv::theme_header_captured && !$miniserv::page_capture) && return);

in theme_footer. session_login.cgi doesn't use &header so theme_header is never called and so this is never called

$miniserv::page_capture          = 1;
$miniserv::theme_header_captured = 1;

which would enable actually printing the footer including embed_js_scripts();

Just placing $miniserv::page_capture = 1; before &footer(); is called, in session_login.cgi didn't work for me, also seems like a dirty fix. I'm not sure where this should be fixed.

Greetings

@jcameron
Copy link
Collaborator

@iliajie can you take a look at this one?

@iliajie
Copy link
Collaborator

iliajie commented Jan 11, 2024

Well, this is expected. We don't print script.js in the login page.

@michaelbaisch
Copy link
Author

@iliajie, I was just wondering about this because earlier, you specifically mentioned in your comment that it was possible. Also, I believe there are some HTML closing tags missing.

Is this the current intended design? And should we not expect script.js on the login page anytime soon?

iliajie added a commit that referenced this issue Jan 15, 2024
@iliajie
Copy link
Collaborator

iliajie commented Jan 15, 2024

Hello, Michael!

Gosh, you're right! I have reviewed the code, and this appears to be a bug, and certainly not expected! The fix is here ca319c2.

Thank you for the heads up!

@iliajie iliajie closed this as completed Jan 15, 2024
@michaelbaisch
Copy link
Author

@iliajie, thank you for the quick fix!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants