--- profile.inc	2007-06-12 20:53:01.000000000 -0400
+++ profile.inc	2007-06-26 11:49:02.000000000 -0400
@@ -195,7 +195,8 @@ function mysite_type_profile_form_items(
           $current[$v['name']] = $v['name'];
         }      
       }
-      $form[$key]= array(
+      // urlencode() the $key to handle spaces      
+      $form[urlencode($key)]= array(
         '#type' => 'checkboxes',
         '#title' => $key,
         '#value' => $current,
@@ -378,7 +379,8 @@ function mysite_type_profile_load($profi
   unset($fields['History']['_mysite']);
   if (!empty($fields)) {
     foreach ($fields as $key => $value) {
-      if (!in_array($key, $allowed)) {
+      // urlencode() the $key to handle spaces
+      if (!in_array(urlencode($key), $allowed)) {
         unset($fields[$key]);
       }
       if (isset($fields[$key]) && is_array($value)) {
