diff --git json_server.js json_server.js
index cc56b80..b395208 100644
--- json_server.js
+++ json_server.js
@@ -32,7 +32,7 @@ Drupal.service = function(service_method, args, success) {
   for(i in args) {
     args_done[i] = Drupal.toJson(args[i]);
   }
-  $.post(Drupal.settings.baseurl + "?q=services/json", args_done, function(unparsed_data) {
+  $.post(Drupal.settings.basePath + "?q=services/json", args_done, function(unparsed_data) {
     parsed_data = Drupal.parseJson(unparsed_data);
     success(!parsed_data['#error'], parsed_data['#data']);
   });
diff --git json_server.module json_server.module
index 3b8e0dc..56190c5 100644
--- json_server.module
+++ json_server.module
@@ -72,10 +72,7 @@ if (!isset($_POST)) {
  *  Load the needed assets to run the server via js.
  */
 function json_load() {
-  global $base_url;
-  $path = drupal_get_path("module", "json_server");
-  drupal_add_js($path ."/json_server.js");
-  drupal_add_js(array("baseurl" => $base_url ."/"), 'setting');
+  drupal_add_js(drupal_get_path("module", "json_server") .'/json_server.js');
 }
 
 function drupal_parse_json($v) {
