Try this
Code:
<if condition="$forum[icon] == 1 AND $extrauseroptions[display_forumicon] == 1">
Display the forum icon code goes here.
I've used that a 1000 times (without the quotes too) and it's always worked...as long as you set $extrauseroptions before the template is called.
It would only be a scope problem if $extrauseroptions was set in a function and wasn't returned, nor set to global within the function.