diff --git a/src/prefs-dialog.c b/src/prefs-dialog.c
index 4b4761f..4685a59 100644
--- a/src/prefs-dialog.c
+++ b/src/prefs-dialog.c
@@ -1332,8 +1332,11 @@ new_tab_homepage_set_mapping (const GValue       *value,
                               const GVariantType *expected_type,
                               gpointer            user_data)
 {
+  PrefsDialog *dialog = user_data;
+
   if (!g_value_get_boolean (value))
     return NULL;
+  gtk_entry_set_text (GTK_ENTRY (dialog->custom_homepage_entry), "");
   return g_variant_new_string ("");
 }
 
@@ -1356,8 +1359,11 @@ blank_homepage_set_mapping (const GValue       *value,
                             const GVariantType *expected_type,
                             gpointer            user_data)
 {
+  PrefsDialog *dialog = user_data;
+
   if (!g_value_get_boolean (value))
     return NULL;
+  gtk_entry_set_text (GTK_ENTRY (dialog->custom_homepage_entry), "");
   return g_variant_new_string ("about:blank");
 }
 
@@ -1384,6 +1390,7 @@ custom_homepage_set_mapping (const GValue       *value,
 
   if (!g_value_get_boolean (value)) {
     gtk_widget_set_sensitive (dialog->custom_homepage_entry, FALSE);
+	gtk_entry_set_text (GTK_ENTRY (dialog->custom_homepage_entry), "");
     return NULL;
   }
 
@@ -1401,8 +1408,10 @@ static void
 custom_homepage_entry_changed (GtkEntry    *entry,
                                PrefsDialog *dialog)
 {
-  g_settings_set_string (EPHY_SETTINGS_MAIN, EPHY_PREFS_HOMEPAGE_URL,
-                         gtk_entry_get_text (entry));
+  if (gtk_toggle_button_get_active 
+      (GTK_TOGGLE_BUTTON (dialog->custom_homepage_radiobutton)))
+    g_settings_set_string (EPHY_SETTINGS_MAIN, EPHY_PREFS_HOMEPAGE_URL,
+                           gtk_entry_get_text (entry));
 }
 
 static void
@@ -1451,7 +1460,7 @@ setup_general_page (PrefsDialog *dialog)
                                 G_SETTINGS_BIND_DEFAULT,
                                 new_tab_homepage_get_mapping,
                                 new_tab_homepage_set_mapping,
-                                NULL,
+                                dialog,
                                 NULL);
   g_settings_bind_with_mapping (settings,
                                 EPHY_PREFS_HOMEPAGE_URL,
@@ -1460,7 +1469,7 @@ setup_general_page (PrefsDialog *dialog)
                                 G_SETTINGS_BIND_DEFAULT,
                                 blank_homepage_get_mapping,
                                 blank_homepage_set_mapping,
-                                NULL,
+                                dialog,
                                 NULL);
   g_settings_bind_with_mapping (settings,
                                 EPHY_PREFS_HOMEPAGE_URL,
