Customer's Canvas is honored with a 2020 InterTech Technology Award! Learn more 
This documentation is for the old version. Go to the latest Upload Suite docs

ImageUploaderFlash.RestrictionFailed Event

This event fires when some restriction is broken.

Syntax

ASP.NET
<script type="text/javascript">
function ImageUploaderFlash1_RestrictionFailed(errorCode, fileName, message){
    //...your code...
}
</script>
<aur:ImageUploaderFlash ID="ImageUploaderFlash1" runat="server">
    <ClientEvents>
        <aur:ClientEvent EventName="RestrictionFailed" HandlerName="ImageUploaderFlash1_RestrictionFailed" />
    </ClientEvents>
</aur:ImageUploaderFlash>
PHP
<script type="text/javascript">
function ImageUploaderFlash1_RestrictionFailed(errorCode, fileName, message){
    //...your code...
}
</script>
<?php
    $ImageUploaderFlash = new ImageUploaderFlash("ImageUploaderFlash1");
    //...other params...
    $ImageUploaderFlash->getClientEvents()->setRestrictionFailed("ImageUploaderFlash1_RestrictionFailed");
    //...other params...
    $ImageUploaderFlash->render();
?>
JavaScript
function ImageUploaderFlash1_RestrictionFailed(errorCode, fileName, message){
    //...your code...
}
$au.imageUploaderFlash({
    events: {
        //...other params...
        restrictionFailed: [ImageUploaderFlash1_RestrictionFailed],
        //...other params...
    }
})

Parameters

errorCode

Type: Number

One of the following values:

fileName

Type: String

The name of the file which breaks the restriction.

message

Type: String

The message stating that the restriction is broken. The same message is displayed in the information bar.

See Also

Reference

Manual