WordPress.org

Forums

custom background for single post (1 post)

  1. prashanth1990
    Member
    Posted 1 year ago #

    Hi,

    I have this plugin installed "Category Images" which basically helps me add an image for a category.

    when i view my post, say for example from category "movies". Can i put the category image has a background image for my single post?

    this helps me get the link of the category image.(plugin)

    <?php if (function_exists('z_taxonomy_image_url')) echo z_taxonomy_image_url(); ?>

    i tried this code

    <style type="text/css">
    body.single{
    background-image:url(<?php if (function_exists('z_taxonomy_image_url')) echo z_taxonomy_image_url(); ?>);
    }
    	</style>

    thank you

Topic Closed

This topic has been closed to new replies.

About this Topic