summaryrefslogtreecommitdiffstats
path: root/settings/js
diff options
context:
space:
mode:
Diffstat (limited to 'settings/js')
-rw-r--r--settings/js/personal.js2
-rw-r--r--settings/js/users/users.js2
2 files changed, 2 insertions, 2 deletions
diff --git a/settings/js/personal.js b/settings/js/personal.js
index 3439eba686f..c9280d31353 100644
--- a/settings/js/personal.js
+++ b/settings/js/personal.js
@@ -70,7 +70,7 @@ function changeDisplayName () {
// Serialize the data
var post = $("#displaynameform").serialize();
// Ajax foo
- $.post('ajax/changedisplayname.php', post, function (data) {
+ $.post(OC.generateUrl('/settings/users/{id}/displayName', {id: OC.currentUser}), post, function (data) {
if (data.status === "success") {
$('#oldDisplayName').val($('#displayName').val());
// update displayName on the top right expand button
diff --git a/settings/js/users/users.js b/settings/js/users/users.js
index 8ce9cb6ac7c..c20a21b060a 100644
--- a/settings/js/users/users.js
+++ b/settings/js/users/users.js
@@ -687,7 +687,7 @@ $(document).ready(function () {
$div.imageplaceholder(uid, displayName);
}
$.post(
- OC.filePath('settings', 'ajax', 'changedisplayname.php'),
+ OC.generateUrl('/settings/users/{id}/displayName', {id: uid}),
{username: uid, displayName: $(this).val()},
function (result) {
if (result && result.status==='success' && $div.length){