mirror of
https://github.com/friendica/friendica
synced 2025-05-06 13:44:09 +02:00
Create Profile\Attachment\Upload module class
- Add missing response type in AjaxUpload initializition
This commit is contained in:
parent
6bf65eb515
commit
969b4f991e
5 changed files with 185 additions and 13 deletions
|
@ -203,8 +203,9 @@ var FileBrowser = {
|
|||
if ($("#upload-file").length) {
|
||||
//AjaxUpload for files
|
||||
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) {
|
||||
$(".fbrowser-content").hide();
|
||||
$(".fbrowser .profile-rotator-wrapper").show();
|
||||
|
@ -214,7 +215,7 @@ var FileBrowser = {
|
|||
if (response["error"] != undefined) {
|
||||
$(".error span").html(response["error"]);
|
||||
$(".error").removeClass("hidden");
|
||||
$("#profile-rotator").hide();
|
||||
$(".fbrowser .profile-rotator-wrapper").hide();
|
||||
$(".fbrowser-content").show();
|
||||
return;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue