WordPress.org

Forums

Images in Sidebar? (8 posts)

  1. gidge
    Member
    Posted 11 years ago #

    I've seen some blogs with a small image in the sidebar, and a small description to the right of it.

    Does anyone know how this can be done?

  2. lawtai
    Member
    Posted 11 years ago #

    you can hard code it in your sidebar.php file
    < img src = " blah balh" /> text text text

  3. bradrice
    Member
    Posted 11 years ago #

    Or if you want it to be a background image and you are using Kubrick as a start, use the header.php file to put your file in a css seletor. If you do it like this:

    background-image: url("<?php bloginfo('stylesheet_directory'); ?>/images/yourimage.png");

    it will write out the directory to your stylesheet for you.

  4. gidge
    Member
    Posted 11 years ago #

    great info guys. thanks.

    now what if i wanted the image and the text to link to one of my pages? example: a picture of myself, and the text says "about."

    would i have to hard-code the link in as a href tag? if hard-coded, would there then be a way to have that page not listed on my sidebar in another place? (because it would be a duplicate)

  5. august
    Member
    Posted 9 years ago #

    IF I want the image and title to appear at the bottom of the sidebar, should I just place that code at the bottom of sidebar.php?
    Which file should I open to place my images and links???

    Any idea?

  6. moshu
    Member
    Posted 9 years ago #

    My educated guess would be the sidebar.php file in your theme's directory.

  7. august
    Member
    Posted 9 years ago #

    can u give me an example?

  8. Chris_K
    Member
    Posted 9 years ago #

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags

No tags yet.