pass the original element title through the element stack so that it we don't lose it in the ajaxuploader.
This commit is contained in:
parent
03753f463e
commit
28228f5862
@ -264,6 +264,9 @@
|
|||||||
action: 'upload.php',
|
action: 'upload.php',
|
||||||
// File upload name
|
// File upload name
|
||||||
name: 'userfile',
|
name: 'userfile',
|
||||||
|
|
||||||
|
title: 'Upload',
|
||||||
|
|
||||||
// Additional data to send
|
// Additional data to send
|
||||||
data: {},
|
data: {},
|
||||||
// Submit file as soon as it's selected
|
// Submit file as soon as it's selected
|
||||||
@ -380,6 +383,7 @@
|
|||||||
|
|
||||||
var input = document.createElement("input");
|
var input = document.createElement("input");
|
||||||
input.setAttribute('type', 'file');
|
input.setAttribute('type', 'file');
|
||||||
|
input.setAttribute('title',this._settings.title);
|
||||||
input.setAttribute('name', this._settings.name);
|
input.setAttribute('name', this._settings.name);
|
||||||
|
|
||||||
addStyles(input, {
|
addStyles(input, {
|
||||||
|
@ -112,11 +112,14 @@ function enableOnUser(){
|
|||||||
/* enable tinymce on focus and click */
|
/* enable tinymce on focus and click */
|
||||||
$("#profile-jot-text").focus(enableOnUser);
|
$("#profile-jot-text").focus(enableOnUser);
|
||||||
$("#profile-jot-text").click(enableOnUser);
|
$("#profile-jot-text").click(enableOnUser);
|
||||||
|
var upload_title = $('#wall-image-upload').attr('title');
|
||||||
|
var attach_title = $('#wall-file-upload').attr('title');
|
||||||
|
|
||||||
var uploader = new window.AjaxUpload(
|
var uploader = new window.AjaxUpload(
|
||||||
'wall-image-upload',
|
'wall-image-upload',
|
||||||
{ action: '{{$baseurl}}/wall_upload/{{$nickname}}',
|
{ action: '{{$baseurl}}/wall_upload/{{$nickname}}',
|
||||||
name: 'userfile',
|
name: 'userfile',
|
||||||
|
title: upload_title,
|
||||||
onSubmit: function(file,ext) { $('#profile-rotator').spin('tiny'); },
|
onSubmit: function(file,ext) { $('#profile-rotator').spin('tiny'); },
|
||||||
onComplete: function(file,response) {
|
onComplete: function(file,response) {
|
||||||
addeditortext(response);
|
addeditortext(response);
|
||||||
@ -129,6 +132,7 @@ function enableOnUser(){
|
|||||||
'wall-file-upload',
|
'wall-file-upload',
|
||||||
{ action: '{{$baseurl}}/wall_attach/{{$nickname}}',
|
{ action: '{{$baseurl}}/wall_attach/{{$nickname}}',
|
||||||
name: 'userfile',
|
name: 'userfile',
|
||||||
|
title: attach_title,
|
||||||
onSubmit: function(file,ext) { $('#profile-rotator').spin('tiny'); },
|
onSubmit: function(file,ext) { $('#profile-rotator').spin('tiny'); },
|
||||||
onComplete: function(file,response) {
|
onComplete: function(file,response) {
|
||||||
addeditortext(response);
|
addeditortext(response);
|
||||||
|
Reference in New Issue
Block a user