/**
* Filebrowser - Friendica Communications Server
*
- * Copyright (c) 2010-2015 the Friendica Project
+ * Copyright (c) 2010-2021, the Friendica project
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Affero General Public License as published by
var embed = "";
if (FileBrowser.type == "image") {
- embed = "[url="+this.dataset.link+"][img="+this.dataset.img+"][/img][/url]";
+ embed = "[url="+this.dataset.link+"][img="+this.dataset.img+"]"+this.dataset.alt+"[/img][/url]";
}
if (FileBrowser.type=="file") {
// attachment links are "baseurl/attach/id"; we need id
if ($("#upload-image").length)
var image_uploader = new window.AjaxUpload(
'upload-image',
- { action: 'wall_upload/'+FileBrowser.nickname+'?response=json',
+ { action: 'profile/' + FileBrowser.nickname + '/photos/upload?response=json',
name: 'userfile',
responseType: 'json',
onSubmit: function(file,ext) { $('#profile-rotator').show(); $(".error").addClass('hidden'); },
if ($("#upload-file").length)
var file_uploader = new window.AjaxUpload(
'upload-file',
- { action: 'wall_attach/'+FileBrowser.nickname+'?response=json',
+ { action: 'profile/' + FileBrowser.nickname + '/attachment/upload?response=json',
name: 'userfile',
+ responseType: 'json',
onSubmit: function(file,ext) { $('#profile-rotator').show(); $(".error").addClass('hidden'); },
onComplete: function(file,response) {
if (response['error']!= undefined) {