ExpressionEngine CMS
Open, Free, Amazing

Thread

This is an archived forum and the content is probably no longer relevant, but is provided here for posterity.

The active forums are here.

Using login.php for CP theme overrides?

January 29, 2011 5:29pm

Subscribe [3]
  • #1 / Jan 29, 2011 5:29pm

    russlipton

    305 posts

    Can login.php be interecepted for cp theming per 2.1.2+ feature enhancements?

    Placing login.php within an account folder into my_theme goes unrecognized at startup:

    my_theme
    ... account
    ....... login.php
    ... css
    ....... override.css or global.css

    I didn’t expect this to work (and it didn’t), but also created just a new login.css like so:

    my_theme
    ... css
    ....... login.css

    It would be super-nice to skin the login page conveniently to match a customized theme. Am I missing something obvious or something hackable?

  • #2 / Jan 31, 2011 2:16am

    John Henry Donovan

    12339 posts

    russlipton,

    Dropping login.css into my_theme/css and editing that works for me. I didn’t add the login.php to my_theme folder.

    Does that not work for you?

  • #3 / Jan 31, 2011 3:35am

    russlipton

    305 posts

    John,

    Right, doesn’t work for me. Here, again is what I have done to rule out other issues:

    1. Installed new, clean remote site with latest version, build of 2.1.3.

    2. Uploaded custom theme(s) working on a MAMP site. These work on the remote site.

    3. Created login.css and placed it in the css folder of a theme (e.g., myTheme/css/login.css with suitable tweaks so its activation will be perceptible ...

    4. Activated the custom theme with the login.css file. Theme activates.

    5. Logged out. It logs out to the Default login screen.

    6. Logged back in from Default login screen. Login directs, as expected to the custom theme which remains the selected CP theme.

    7. Emptied all caches

    8. Logged out again and again was presented with the Default login screen.

    :Thoughts? Glad to give you access to the site if you’d like.

  • #4 / Feb 01, 2011 1:58am

    John Henry Donovan

    12339 posts

    russlipton,

    Have you also changed the default theme to your customized one like the one under your Account?

  • #5 / Feb 01, 2011 4:14am

    russlipton

    305 posts

    Of course - if the custom theme isn’t activated (e.g, functioning as the current theme), I wouldn’t expect EE to pay attention to login.css within that (inactive) theme’s css folder 😉

    E.g., When MyTheme is the selected CP theme under My Account, I experience the issue described above.

    This is why I wonder whether it might be best for you to check it out directly. If I am missing something, how likely is it that we will converge on that here?

  • #6 / Feb 01, 2011 12:02pm

    russlipton

    305 posts

    I tried two small things (with the myTheme activated as the current CP theme):

    1. Changed the name of myTheme global.css to override.css, thinking that perhaps EE needs to match that name before recognizing login.css. Of course, myTheme continued to work normally, but no joy with login.css.

    2. Removed myTheme’s custom CSS file, leaving only the login.css file in myTheme css:

    /cp-themes
    .... myTheme
    ........ login.css

    myTheme continued toi ‘work’ (still the activated theme) though, of course, it was actually using Default’s global.css since I provided no file with override code. Still no recognition of login.css within myTheme.

    I have attached my login.css file for inspection. Because I have mainly been trying to get it to work, it’s just like the original login.css, except for a background change and a few minor tweaks. Let me know if there is a problem with it.

    Thanks for your help fixing this; it is rather important to me.

    (used .txt suffix on login file name attachment to upload to this forum)

  • #7 / Feb 02, 2011 4:16am

    John Henry Donovan

    12339 posts

    russlipton,

    /cp-themes
    .... myTheme
    ........ login.css

    login.css should be in a css folder. Is that the case?

    Change the theme in both My Account and General Configuration for this to work

  • #8 / Feb 02, 2011 5:38am

    russlipton

    305 posts

    John,

    Sorry, yes, did have login.css in css folder despite the impression created by my previous post. Setting the theme in general config did the trick. I should have thought of that, but had become used to changing themes in 2.X through Accessories and leaving Default always as the default theme.

    Thanks for sticking with me on this.

  • #9 / Feb 02, 2011 4:28pm

    Ingmar

    29245 posts

    Glad to see John Henry was able to help. Please post again in case there’s anything else.

.(JavaScript must be enabled to view this email address)

ExpressionEngine News!

#eecms, #events, #releases