Create a function,
get_member_background($userinfo). Have it return the color you want. Define it in a plugin on
global_complete or something.
Do you want to be able to call this function in a template? If so, add another plugin on the
template_safe_functions hook, and then add your function name into the allowed functions for conditionals, like so:
PHP Code:
$safe_functions[] = 'get_member_background';
Now, in your Template, you could go something like,
HTML Code:
<vb:if condition="$post['background'] = get_member_background($post)"><div class="{vb:raw post.background}">
<vb:else />
<div class="userinfo">
</vb:if>