I found something interesting

the setcookie function in ubb.inc.php reads as follows:

setcookie("$name","$value",$time,$cookiepath);

it is missing cookie domain information which is not in any config files either. Having cookie domain information and setting it to ".yourdomain.com" should make it available on both http://www.yourdomain.com and http://yourdomain.com.

I wonder what Rick has to say:

setcookie("$name","$value",$time,$cookiepath,$cookiedomain) ???