• Every time I try to upload a custom image I get a “division by zero” error message but the image uploads successfully into the library. Can someone tell me what the problem is with the code?

    Thanks
    Charles

Viewing 2 replies - 1 through 2 (of 2 total)
  • What theme are you using? What plugins are turned on? Could you be more specific?

    Thread Starter charles_i

    (@charles_i)

    I’m trying to make my own theme. I’ve used the header code from the “Classic” theme and this in functions:

    define(‘header_image’, ‘%s/images/header.jpg’);
    define(‘header_width’, 576);
    define(‘header_height’, 131);

    function header_style() { ?>
    <style type=”text/css”>
    #wp_header {
    background: url(<?php header_image(); ?>) 0 0 no-repeat;
    height: <?php echo header_height; ?>px;
    width: <?php echo header_width; ?>px;
    }
    </style>
    <?php }
    function header_style() { ?>
    <style type=”text/css”>
    #wp_header {
    background: url(<?php header_image(); ?>) 0 0 no-repeat;
    height: <?php echo header_height; ?>px;
    width: <?php echo header_width; ?>px;
    }
    </style>
    <?php }

    Trying to make it as simple as I can.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘custom header image – division by zero’ is closed to new replies.