WordPress.org

Ready to get started?Download WordPress

Forums

Clickable Background Image (1 post)

  1. JoePPV
    Member
    Posted 1 year ago #

    Hi there,

    I've been trying to include a clickable background image via CSS.

    My CSS

    /*###Background Image Advertisment START###*/
    #background_ad{
    top: 0;
    left:0;
    position: absolute;
    display: inline;
    width: 100%;
    cursor: pointer;}
    
    body{
    background:url('IMAGE.jpg');
    background-position:top center;
    background-repeat:no-repeat;
    background-attachment:fixed;}
    /*###Background Image Advertisment END###*/
    
    /*--###Basics START###*/

    My header

    </head>
    
    <body <?php body_class(); ?>>
    
    <!--<a style="height:3000px;" id="background_ad" href="http://www.URL.com" target="_blank">&nbsp;</a>-->
    
    <?php $theme->hook('html_before'); ?>

    So far, it works.
    However, the clickable area covers the main wrapped content.
    This means, when I move over the main content, the internal links are not clickable. Instead, the URL of the background image applies.

    I need the areas above, left and right from the main content to be clickable.

    How can this be achieved?

    I thought of padding, but this wouldn't work.

    The Background Manager plugin doesn't work since we don't run php5.3

    Any ideas?

    Best

    Joe

Topic Closed

This topic has been closed to new replies.

About this Topic