change background when logged in
-
place this after the body tag in the header
make sure you dont have a body in your css<?php if ( current_user_can('read') ) { ?> <style type="text/css"> body { background-image: url(<?php bloginfo('stylesheet_directory'); ?>/images/bg.gif); background-repeat: repeat-x; background-position: top; } </style> <?php } else { ?> <style type="text/css"> body { background-image: url(<?php bloginfo('stylesheet_directory'); ?>/images/bgnonmember.gif); background-color:#ECECEC; background-repeat: repeat-x; background-position: top; } </style> <?php } ?>i think it’s a awesome trick,
The topic ‘change background when logged in’ is closed to new replies.