diff --git a/modules/system/system.js b/modules/system/system.js
index 62bb4b86228623f0d947f409a9d11869ee564194..a77c7ac996a8a6ddca8059c1fdae8b586cfef0fd 100644
--- a/modules/system/system.js
+++ b/modules/system/system.js
@@ -11,7 +11,7 @@ Drupal.cleanURLsSettingsCheck = function() {
   var url = location.pathname +"admin/settings/clean-urls";
   $("#clean-url .description span").html('<div id="testing">'+ Drupal.settings.cleanURL.testing +"</div>");
   $("#clean-url p").hide();
-  $.ajax({url: location.protocol +"//"+ location.hostname + url, type: "GET", data: " ", complete: function(response) {
+  $.ajax({url: location.protocol +"//"+ location.host + url, type: "GET", data: " ", complete: function(response) {
     $("#testing").toggle();
     if (response.status == 200) {
       // Check was successful.