Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

uploadify 3 pass formdata issue

Status
Not open for further replies.

thompom

Technical User
Dec 4, 2006
395
0
0
GB
Hi - anyone useing uloadify v3?

am trying to pass values to my server script using the following, however fiddler tells me that the value of actionid is always 'notset' the alert shows 47185 how can i get the onstart to change formdata?

Code:
$('.file_upload').uploadify({
'formData' : {'actionid':'notset'},
'swf'      : 'uploadify3/uploadify.swf',
'uploader' : 'uploadify3/upload.asp',
'onUploadStart' : function(file) { 
   var x_key = $('#x_curractionid').val();
   $('.file_upload').uploadify('settings', 'formData', {'actionid' : x_key});
   alert(x_key);
}
});
 
actionid = 'not set' because actionid = 'not set' from the parent declaration. Use $(this) for child objects (I think)

Code:
$('.file_upload').uploadify({
'formData' : {'actionid':'notset'},
'swf'      : 'uploadify3/uploadify.swf',
'uploader' : 'uploadify3/upload.asp',
'onUploadStart' : function(file) { 
   var x_key = $('#x_curractionid').val();
   [red][b]$(this)[/b][/red].uploadify('settings', 'formData', {'actionid' : x_key});
   alert(x_key);
}
});

-Geates

"I do not offer answers, only considerations."
- Geates's Disclaimer

 
hi - thanks for reply - tried following but using this causes script to fail

Code:
	$('.file_upload').uploadify({
		'swf'      : 'uploadify3/uploadify.swf',
		'uploader' : 'uploadify3/upload.asp',
		'onUploadStart' : function(file) { 
			var x_key = $('#x_curractionid').val();
                   $(this).uploadify('settings', 'formData', {'actionid' : x_key});
			alert(x_key);
        }
	});
 
Hi - found issue - was because the settings line was using class instead of id
your post got me thinking - thankyou!!! (wasted hours on this)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top