[wikka-community] Background Images

Dario Taraborelli dartar
Wed May 12 12:51:54 GMT 2010


hi Kevin

> I know you can edit the style sheet in order to add a background image but what I need to know is if it is possible to somewhere add a different background image for different pages within the wikka site?

you can do this by adding a style block in the <head> of the header file of your theme, e.g.

/plugins/templates/kevin/header.php

you can then check the page name (if that's what you want to use) to load a different image, for instance:

<?php 
if ($this->tag == "MyPage") $imgurl = "mybackground.jpg";
?>
<style type="text/css">
div#content {
background-image:url('<?php echo $imgurl ?>');
}
</style>

Hope this helps,

Dario
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.wikkawiki.org/pipermail/community_wikkawiki.org/attachments/20100512/46715f5a/attachment.html>



More information about the community mailing list