Ultimate Branding on multisite - custom login page for each subsite possible?

I installed Ultimate Branding in a multisite environment hoping I could customize each subsite differently with it.

I have 2 subsites in the network that have their own branding. What I want is to customize the Login Screen for each subsite with different logos, colours and background images.

After checking all the settings of Ultimate Branding it looks like I can only activate and use it for the entire network, i.e. same logo, background for all subsites. Is that true? Is there a way around that?

  • Adam Czajczyk

    Hi Ocean Diveloper,

    I hope you're well and thank you for your question!

    Yes, you are right. The Ultimate Branding plugin can only be network activated and some of its modules - such as Login Screen - can only be set "site-wide", affecting entire network.

    The login form - in the default, not customized/tweaked in anyway Multisite - is in fact common for all the sites and there's no separate "wp-login.php" pages. That's why that works this way. Also, usually the module is used by Multisite admins to make sure that their "network branding" is used "all across the network" but that's a different story :slight_smile:

    The bottom line is: that's currently not possible to use that to separately customize for each sub-site. As for workarounds, I'm not entirely sure yet - that would mostly depends on the "amount of customization" and the current setup.

    If you could tell me a bit more about what elements/in what way you would like to customize and describe current setup a bit more (you can e.g. link me directly to those login areas that you want to customize) that would help me a bit and I'd see if we could find any way around that :slight_smile:

    Best regards,

  • Ocean Diveloper

    Hello Adam, thank you for your reply. In the meantime I solved it myself.

    First we need a custom jQuery script on the subsite's login page via functions.php of my subsite's theme using action hook "login_enqueue_scripts":

    //* Load subsite login script
    function load_subsite_login_script() {
        wp_enqueue_script( 'subsite-login-script', get_stylesheet_directory_uri() . '/js/login.js', array( 'jquery' ), '1.0.0', true );
    add_action( 'login_enqueue_scripts', 'load_subsite_login_script' );

    The code in that script adds a new class "subsite-login" to the body tag of the login page. This is what's inside the login.js:

    jQuery(function( $ ){
    	$(document).ready(function() {
    		// If we are on login page
    		if ($("body").hasClass("login")) {
    			// Add class "subsite-login" to body tag
    			var newClass = "subsite-login";

    After that you can simply style logo, background and colors via CSS ("body.subsite-login") using the handy "Login CSS" module of Ultimate Branding.

    • Adam Czajczyk

      Hi Steve - Just Think BiG

      Actually, you are right! I definitely made a mistake (I had some non-standard setup due to some other issue testing at the time I was responding here) and I apologize for that.

      Sometimes we're testing so many different things during the workday that we might overlook something or accidentally forget to restore "default" configuration when switching from testing one issue to another. That should never happen, obviously, but I guess that's because we're only humans... :wink: Anyway, once again, I'm sorry for giving a wrong information Ocean Diveloper and thank you Steve - Just Think BiG for pointing that out and correcting me!

      Kind regards,

        • Adam Czajczyk

          Hi @kevin8733!

          That's a fair question :slight_smile: I just double-checked that (it's always good to make sure) and you should definitely be able to activate it "per site". Unless it's already network-activated or there's some other plugin (like Pro Sites with it's Premium Plugins/Premium Plugin Manager module) that's blocking activation for particular site.

          If still can't activate it, you might try a small trick:
          - rename plugin's folder to something else (e.g. ultimate-branding-OFF)
          - login back to the site as a super-admin
          - go to the "Network Admin -> Plugins" page
          - not sure how many sites you got on your network but it might also be good to visit the "Plugins" page in the dashboard of each of them
          - then rename folder back to "ultimate-branding"

          This would give you a "fresh start" in terms of activation (though the data shouldn't be lost).

          Best regards,

Thank NAME, for their help.

Let NAME know exactly why they deserved these points.

Gift a custom amount of points.