Parse error: syntax error, unexpected T_IF /home49
<p>I'm getting the following error when inserting this bit of code in my web site header. Can anyone help me to find the error and fix it?</p>

<p>"Parse error: syntax error, unexpected T_IF in /home/m3999316/public_html/testing/wp-content/themes/gridmarket/header.php on line 49" and here is my code:</p>

<pre><code>if ( is_user_logged_in() ) {
  global $current_user;
  get_currentuserinfo();
  echo 'Welcome, '.$current_user-&gt;user_login.'';
  $user_id = $current_user-&gt;ID;
  $user_blogs = get_blogs_of_user( $user_id );
  $playground = count($user_blogs);  
  $mainblog_name =

  if (is_super_admin()){echo ' | Manage Network';} elseif ($playground == 1) {
    echo ' | Start Selling';
  } else {
    foreach ($user_blogs as $user_blog) {
      if ($user_blog-&gt;blogname!= 'Marketpress Fronted Plugin - Demo' )
        echo 'Manage Store';
    }
  }
    echo ' | Log out';
} else {
    echo 'Login | Register';
}

?&gt;
</code></pre>
