WordPress.org

Ready to get started?Download WordPress

Forums

My Brand Login
Empty url() in Admin CSS rules breaks some plugins / pages (1 post)

  1. Scott Kingsley Clark
    Member
    Posted 3 years ago #

    In the function my_brand_adminlogo there is some code that should be adjusted to prevent issues with some plugins / pages:

    function my_brand_adminlogo() { ?> <?php $ilogo = get_option('mybrandadminlogo'); ?>
    <style type="text/css"> #header-logo { width:40px;height:40px; background : transparent url(<?php echo $ilogo; ?>) no-repeat scroll center center;} <? }

    to be changed to:

    function my_brand_adminlogo() { ?> <?php $ilogo = get_option('mybrandadminlogo'); if (empty($ilogo)) { return; } ?>
    <style type="text/css"> #header-logo { width:40px;height:40px; background : transparent url(<?php echo $ilogo; ?>) no-repeat scroll center center;} <? }

    And the same for the function my_brand_adminbg:

    function my_brand_adminbg() { ?> <?php $ibg = get_option('mybrandadminbg'); ?>
    html { background : url(<?php echo $ibg; ?>) repeat; }#footer-upgrade {color:transparent;display:none;} #footer {background-color:transparent;border-top:0px;} </style> <? }

    to be changed to:

    function my_brand_adminbg() { ?> <?php $ibg = get_option('mybrandadminbg'); if (empty($ibg)) { return; } ?>
    html { background : url(<?php echo $ibg; ?>) repeat; }#footer-upgrade {color:transparent;display:none;} #footer {background-color:transparent;border-top:0px;} </style> <? }

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic

  • RSS feed for this topic
  • Started 3 years ago by Scott Kingsley Clark
  • This topic is not resolved
  • WordPress version: 3.1.1

Tags