[phpBB Debug] PHP Warning: in file [ROOT]/phpbb/session.php on line 580: sizeof(): Parameter must be an array or an object that implements Countable
[phpBB Debug] PHP Warning: in file [ROOT]/phpbb/session.php on line 636: sizeof(): Parameter must be an array or an object that implements Countable
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4511: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3257)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4511: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3257)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4511: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3257)
SELinux Super Administrator Forum • Custom wallpaper by user name
Page 1 of 1

Custom wallpaper by user name

Posted: Mon May 22, 2017 11:03 am
by micklang
Have you ever wanted custom wallpaper based on userid? Well, now you can!

The config file is: /opt/jcdx/sbin/j**x-wallpaper

As this is a python file, you'll want to point out how to identify a human. Place this entry near the top, just below the function called getsite():

human = os.getlogin() # Used to determine who is loggin in-- for determining custom wallpaper

Then, under the below variable:

site = getsite()

Add the below code for each group of users:

# begin code for custom wallpaper
if str(human) in ('andre','chip'): # add users here for the cool j**x wallpaper
os.system("/usr/bin/Esetroot -scale /var/opt/jcdx/images/wallpaper/7051/jcdx-v7-purple-wide.png")
quit();




If you have multiple wallpapers that require different ones for different sizes, create more of the same code blocks for the above.

If this does not work, make sure that one of the modules that are imported at the beginning are reflected as below:

import gtk
import os