site.css for admin

Discussion in 'Templates customization' started by bennyuk1, Jan 24, 2018.

  1. bennyuk1

    bennyuk1 aMember Pro Customer

    Joined:
    Jan 12, 2012
    Messages:
    200
    I can see to add css changes to
    application/default/views/public/css/site.css

    for front end,

    but where to I add css changes for admin back end, eg login page at amember/admin/
    ?
    Thanks
  2. caesar

    caesar aMember Pro Developer Staff Member

    Joined:
    Oct 16, 2009
    Messages:
    2,295
    Hello,

    I am afraid there is not such file for admin interface. You can use the following approach to add some CSS file from site.php file
    http://www.amember.com/docs/Site.php_file
    PHP:
    Am_Di::getInstance()->hook->add(Am_Event::BEFORE_RENDER, function(Am_Event $e) {
        if (
    defined('AM_ADMIN') && AM_ADMIN) {
            
    $e->getView()->headLink()->appendStylesheet('/path/to/any.css');
        }
    });
    Then put your CSS to file /path/to/any.css

    Best Regards.

Share This Page