Use session_set_cookie_params() ;)
session_set_cookie_params ( $lifetime , '/', '.yourdomain.com');
Note, that the domain starts with a dot. This means, the session cookie is valid for every subdomain!
http://php.net/manual/en/function.session-set-cookie-params.php