aboutsummaryrefslogtreecommitdiffstats
path: root/www/js
diff options
context:
space:
mode:
Diffstat (limited to 'www/js')
-rw-r--r--www/js/config.js-example3
-rw-r--r--www/js/locate.js2
-rw-r--r--www/js/models/report.js7
3 files changed, 6 insertions, 6 deletions
diff --git a/www/js/config.js-example b/www/js/config.js-example
index 75c66f9..49c2003 100644
--- a/www/js/config.js-example
+++ b/www/js/config.js-example
@@ -6,7 +6,8 @@ var CONFIG = {
APP_NAME: 'FixMyStreet',
// URL of the fixmystreet install to report to. See also config.xml-example
- FMS_URL: 'http://fixmystreet.example.org/',
+ // Make sure it does *not* end with a slash.
+ FMS_URL: 'http://fixmystreet.example.org',
// Name of the cobrand to use for templates, stylesheets etc.
// Cobrand files should be placed in a new directory within www/cobrands/
diff --git a/www/js/locate.js b/www/js/locate.js
index 97beece..b589ddf 100644
--- a/www/js/locate.js
+++ b/www/js/locate.js
@@ -108,7 +108,7 @@
}
var that = this;
$.ajax( {
- url: CONFIG.FMS_URL + 'report/new/ajax',
+ url: CONFIG.FMS_URL + '/report/new/ajax',
global: showSpinner,
dataType: 'json',
data: {
diff --git a/www/js/models/report.js b/www/js/models/report.js
index 9e6290c..1a72e73 100644
--- a/www/js/models/report.js
+++ b/www/js/models/report.js
@@ -1,7 +1,7 @@
(function(FMS, Backbone, _, $) {
_.extend( FMS, {
Report: Backbone.Model.extend({
- urlRoot: CONFIG.FMS_URL + 'report/ajax',
+ urlRoot: CONFIG.FMS_URL + '/report/ajax',
defaults: {
lat: 0,
@@ -36,7 +36,6 @@
lon: res.report.longitude,
title: res.report.title,
details: res.report.detail,
- photo: res.report.photo && res.report.photo.url ? CONFIG.FMS_URL + res.report.photo.url : null,
meta: res.report.meta,
confirmed_pp: res.report.confirmed_pp,
created_pp: res.report.created_pp,
@@ -177,12 +176,12 @@
});
window.setTimeout( checkUpload, 15000 );
FMS.uploading = true;
- ft.upload(fileURI, CONFIG.FMS_URL + "report/new/mobile", fileUploadSuccess, fileUploadFail, fileOptions);
+ ft.upload(fileURI, CONFIG.FMS_URL + "/report/new/mobile", fileUploadSuccess, fileUploadFail, fileOptions);
};
setupChecker();
} else {
$.ajax( {
- url: CONFIG.FMS_URL + "report/new/mobile",
+ url: CONFIG.FMS_URL + "/report/new/mobile",
type: 'POST',
data: params,
dataType: 'json',