Name | Type | Default |
---|---|---|
autoUpload | Boolean | false |
Sets or gets whether files will be automatically uploaded when selected. <template> <div> <p>Note: to be able to upload a file you would have to set the property uploadUrl to point to a file hosted on your server, which handles the upload process.</p> <JqxFileUpload ref="myFileUpload" /> </div> </template> <script> import JqxFileUpload from 'jqwidgets-scripts/jqwidgets-vue/vue_jqxfileupload.vue'; export default { components: { JqxFileUpload } } </script> Get the let autoUpload = this.$refs.myFileUpload.autoUpload; |
||
accept | String | null |
Sets or gets the file types that can be submitted to the server through jqxFileUpload. This property corresponds to the
<template> <div> <p>Note: to be able to upload a file you would have to set the property uploadUrl to point to a file hosted on your server, which handles the upload process.</p> <JqxFileUpload ref="myFileUpload" /> </div> </template> <script> import JqxFileUpload from 'jqwidgets-scripts/jqwidgets-vue/vue_jqxfileupload.vue'; export default { components: { JqxFileUpload } } </script> Get the let accept = this.$refs.myFileUpload.accept; |
||
browseTemplate | String | '' |
Sets or gets the template applied to the 'Browse' button. Possible Values:
<template> <div> <p>Note: to be able to upload a file you would have to set the property uploadUrl to point to a file hosted on your server, which handles the upload process.</p> <JqxFileUpload ref="myFileUpload" /> </div> </template> <script> import JqxFileUpload from 'jqwidgets-scripts/jqwidgets-vue/vue_jqxfileupload.vue'; export default { components: { JqxFileUpload } } </script> Get the let browseTemplate = this.$refs.myFileUpload.browseTemplate; |
||
cancelTemplate | String | '' |
Sets or gets the template applied to the 'Cancel All' button. Possible Values:
<template> <div> <p>Note: to be able to upload a file you would have to set the property uploadUrl to point to a file hosted on your server, which handles the upload process.</p> <JqxFileUpload ref="myFileUpload" /> </div> </template> <script> import JqxFileUpload from 'jqwidgets-scripts/jqwidgets-vue/vue_jqxfileupload.vue'; export default { components: { JqxFileUpload } } </script> Get the let cancelTemplate = this.$refs.myFileUpload.cancelTemplate; |
||
disabled | Boolean | false |
Enables or disables the jqxFileUpload. <template> <div> <p>Note: to be able to upload a file you would have to set the property uploadUrl to point to a file hosted on your server, which handles the upload process.</p> <JqxFileUpload ref="myFileUpload" /> </div> </template> <script> import JqxFileUpload from 'jqwidgets-scripts/jqwidgets-vue/vue_jqxfileupload.vue'; export default { components: { JqxFileUpload } } </script> Get the let disabled = this.$refs.myFileUpload.disabled; |
||
fileInputName | String | '' |
Sets or gets the <template> <div> <p>Note: to be able to upload a file you would have to set the property uploadUrl to point to a file hosted on your server, which handles the upload process.</p> <JqxFileUpload ref="myFileUpload" /> </div> </template> <script> import JqxFileUpload from 'jqwidgets-scripts/jqwidgets-vue/vue_jqxfileupload.vue'; export default { components: { JqxFileUpload } } </script> Get the let fileInputName = this.$refs.myFileUpload.fileInputName; |
||
height | Number | String | 'auto' |
Sets or gets the jqxFileUpload's height. <template> <div> <p>Note: to be able to upload a file you would have to set the property uploadUrl to point to a file hosted on your server, which handles the upload process.</p> <JqxFileUpload ref="myFileUpload" /> </div> </template> <script> import JqxFileUpload from 'jqwidgets-scripts/jqwidgets-vue/vue_jqxfileupload.vue'; export default { components: { JqxFileUpload } } </script> Get the let height = this.$refs.myFileUpload.height; |
||
localization | Object | null |
Sets the various text values used in the widget. Useful for localization. The localization object has the following fields:
<template> <div> <p>Note: to be able to upload a file you would have to set the property uploadUrl to point to a file hosted on your server, which handles the upload process.</p> <JqxFileUpload ref="myFileUpload" /> </div> </template> <script> import JqxFileUpload from 'jqwidgets-scripts/jqwidgets-vue/vue_jqxfileupload.vue'; export default { components: { JqxFileUpload }, data: function () { return { localization: { browseButton: 'Blättern', uploadButton: 'Laden Sie alle', cancelButton: 'alle Abbrechen', uploadFileTooltip: 'Datei hochladen', cancelFileTooltip: 'aufheben' } } } } </script> Get the let localization = this.$refs.myFileUpload.localization; |
||
multipleFilesUpload | Boolean | true |
Sets or gets whether multiple files selection and upload are allowed. <template> <div> <p>Note: to be able to upload a file you would have to set the property uploadUrl to point to a file hosted on your server, which handles the upload process.</p> <JqxFileUpload ref="myFileUpload" /> </div> </template> <script> import JqxFileUpload from 'jqwidgets-scripts/jqwidgets-vue/vue_jqxfileupload.vue'; export default { components: { JqxFileUpload } } </script> Get the let multipleFilesUpload = this.$refs.myFileUpload.multipleFilesUpload; |
||
renderFiles | Function | null |
A callback function used for rendering the file selection rows. <template> <div> <p>Note: to be able to upload a file you would have to set the property uploadUrl to point to a file hosted on your server, which handles the upload process.</p> <JqxFileUpload ref="myFileUpload" /> </div> </template> <script> import JqxFileUpload from 'jqwidgets-scripts/jqwidgets-vue/vue_jqxfileupload.vue'; export default { components: { JqxFileUpload }, methods: { renderFiles: function (fileName) { return fileName.toUpperCase(); } } } </script> Get the let renderFiles = this.$refs.myFileUpload.renderFiles; |
||
rtl | Boolean | false |
Sets or gets a value indicating whether widget's elements are aligned to support locales using right-to-left fonts. <template> <div> <p>Note: to be able to upload a file you would have to set the property uploadUrl to point to a file hosted on your server, which handles the upload process.</p> <JqxFileUpload ref="myFileUpload" /> </div> </template> <script> import JqxFileUpload from 'jqwidgets-scripts/jqwidgets-vue/vue_jqxfileupload.vue'; export default { components: { JqxFileUpload } } </script> Get the let rtl = this.$refs.myFileUpload.rtl; |
||
theme | String | '' |
Sets the widget's theme.
<template> <div> <p>Note: to be able to upload a file you would have to set the property uploadUrl to point to a file hosted on your server, which handles the upload process.</p> <JqxFileUpload ref="myFileUpload" /> </div> </template> <script> import JqxFileUpload from 'jqwidgets-scripts/jqwidgets-vue/vue_jqxfileupload.vue'; export default { components: { JqxFileUpload } } </script> |
||
uploadUrl | String | '' |
Sets or gets the upload URL. This property corresponds to the upload form's <?php A few notes about file uploads in PHP: Many shared hosting servers allow a very low maximum file upload size. If you plan on accepting larger files, you should consider a dedicated or virtual dedicated server. To adjust the file upload size in PHP, modify the php.ini file's "upload_max_filesize" value. You can also adjust this value using PHP's .ini_set() function. The file upload counts towards the hosting environment's $_POST size, so you may need to increase the php.ini file's post_max_size value. Be sure to do a lot of file validation when allowing users to upload files. How horrible would it be to allow a user to upload a .exe file to your server? They could do horrible things on the server. <template> <div> <p>Note: to be able to upload a file you would have to set the property uploadUrl to point to a file hosted on your server, which handles the upload process.</p> <JqxFileUpload ref="myFileUpload" /> </div> </template> <script> import JqxFileUpload from 'jqwidgets-scripts/jqwidgets-vue/vue_jqxfileupload.vue'; export default { components: { JqxFileUpload } } </script> Get the let uploadUrl = this.$refs.myFileUpload.uploadUrl; |
||
uploadTemplate | String | '' |
Sets or gets the template applied to the 'Upload All' button. Possible Values:
<template> <div> <p>Note: to be able to upload a file you would have to set the property uploadUrl to point to a file hosted on your server, which handles the upload process.</p> <JqxFileUpload ref="myFileUpload" /> </div> </template> <script> import JqxFileUpload from 'jqwidgets-scripts/jqwidgets-vue/vue_jqxfileupload.vue'; export default { components: { JqxFileUpload } } </script> Get the let uploadTemplate = this.$refs.myFileUpload.uploadTemplate; |
||
width | Number | String | null |
Sets or gets the jqxFileUpload's width. <template> <div> <p>Note: to be able to upload a file you would have to set the property uploadUrl to point to a file hosted on your server, which handles the upload process.</p> <JqxFileUpload ref="myFileUpload" /> </div> </template> <script> import JqxFileUpload from 'jqwidgets-scripts/jqwidgets-vue/vue_jqxfileupload.vue'; export default { components: { JqxFileUpload } } </script> Get the let width = this.$refs.myFileUpload.width; |
||
Events |
||
remove | Event | |
This event is triggered when a file row has been removed. Code examples
Bind to the
<template> <div> <p>Note: to be able to upload a file you would have to set the property uploadUrl to point to a file hosted on your server, which handles the upload process.</p> <JqxFileUpload ref="myFileUpload" @remove="onRemove($event)" /> </div> </template> <script> import JqxFileUpload from 'jqwidgets-scripts/jqwidgets-vue/vue_jqxfileupload.vue'; export default { components: { JqxFileUpload }, methods: { onRemove: function (event) { alert('do something...'); } } } </script> |
||
select | Event | |
This event is triggered when a file has been selected. Code examples
Bind to the
<template> <div> <p>Note: to be able to upload a file you would have to set the property uploadUrl to point to a file hosted on your server, which handles the upload process.</p> <JqxFileUpload ref="myFileUpload" @select="onSelect($event)" /> </div> </template> <script> import JqxFileUpload from 'jqwidgets-scripts/jqwidgets-vue/vue_jqxfileupload.vue'; export default { components: { JqxFileUpload }, methods: { onSelect: function (event) { alert('do something...'); } } } </script> |
||
uploadStart | Event | |
This event is triggered when a file upload operation has started. Code examples
Bind to the
<template> <div> <p>Note: to be able to upload a file you would have to set the property uploadUrl to point to a file hosted on your server, which handles the upload process.</p> <JqxFileUpload ref="myFileUpload" @uploadStart="onUploadStart($event)" /> </div> </template> <script> import JqxFileUpload from 'jqwidgets-scripts/jqwidgets-vue/vue_jqxfileupload.vue'; export default { components: { JqxFileUpload }, methods: { onUploadStart: function (event) { alert('do something...'); } } } </script> |
||
uploadEnd | Event | |
This event is triggered when a file upload operation has ended. Code examples
Bind to the
<template> <div> <p>Note: to be able to upload a file you would have to set the property uploadUrl to point to a file hosted on your server, which handles the upload process.</p> <JqxFileUpload ref="myFileUpload" @uploadEnd="onUploadEnd($event)" /> </div> </template> <script> import JqxFileUpload from 'jqwidgets-scripts/jqwidgets-vue/vue_jqxfileupload.vue'; export default { components: { JqxFileUpload }, methods: { onUploadEnd: function (event) { alert('do something...'); } } } </script> |
||
Methods |
||
Name | Arguments | Return Type |
browse | None | None |
Browses for a file. Due to browser restrictions, this method would not work on Internet Explorer 9 or earlier. <template> <div> <p>Note: to be able to upload a file you would have to set the property uploadUrl to point to a file hosted on your server, which handles the upload process.</p> <JqxFileUpload ref="myFileUpload" /> <br /> <JqxButton @click="onClick()" :width="120">Browse For a File</JqxButton> </div> </template> <script> import JqxFileUpload from 'jqwidgets-scripts/jqwidgets-vue/vue_jqxfileupload.vue'; import JqxButton from 'jqwidgets-scripts/jqwidgets-vue/vue_jqxbuttons.vue'; export default { components: { JqxFileUpload, JqxButton }, methods: { onClick: function () { this.$refs.myFileUpload.browse(); } } } </script> |
||
cancelFile | fileIndex | None |
Cancels a selected file. <template> <div> <p>Note: to be able to upload a file you would have to set the property uploadUrl to point to a file hosted on your server, which handles the upload process.</p> <JqxFileUpload ref="myFileUpload" /> <p>You should browse for a file and then click the button to cancel it:</p> <JqxButton @click="onClick()" :width="120">Cancel File</JqxButton> </div> </template> <script> import JqxFileUpload from 'jqwidgets-scripts/jqwidgets-vue/vue_jqxfileupload.vue'; import JqxButton from 'jqwidgets-scripts/jqwidgets-vue/vue_jqxbuttons.vue'; export default { components: { JqxFileUpload, JqxButton }, methods: { onClick: function() { this.$refs.myFileUpload.cancelFile(0); } } } </script> |
||
cancelAll | None | None |
Cancels all selected files. <template> <div> <p>Note: to be able to upload a file you would have to set the property uploadUrl to point to a file hosted on your server, which handles the upload process.</p> <JqxFileUpload ref="myFileUpload" /> <p>You should browse for a file/files and then click the button to cancel them:</p> <JqxButton @click="onClick()" :width="120">Cancel Files</JqxButton> </div> </template> <script> import JqxFileUpload from 'jqwidgets-scripts/jqwidgets-vue/vue_jqxfileupload.vue'; import JqxButton from 'jqwidgets-scripts/jqwidgets-vue/vue_jqxbuttons.vue'; export default { components: { JqxFileUpload, JqxButton }, methods: { onClick: function() { this.$refs.myFileUpload.cancelAll(); } } } </script> |
||
destroy | None | None |
Destroys the jqxFileUpload. <template> <div> <p>Note: to be able to upload a file you would have to set the property uploadUrl to point to a file hosted on your server, which handles the upload process.</p> <JqxFileUpload ref="myFileUpload" /> </div> </template> <script> import JqxFileUpload from 'jqwidgets-scripts/jqwidgets-vue/vue_jqxfileupload.vue'; export default { components: { JqxFileUpload }, mounted: function () { this.$refs.myFileUpload.destroy(); } } </script> |
||
render | None | None |
Renders the widget. <template> <div> <p>Note: to be able to upload a file you would have to set the property uploadUrl to point to a file hosted on your server, which handles the upload process.</p> <JqxFileUpload ref="myFileUpload" /> </div> </template> <script> import JqxFileUpload from 'jqwidgets-scripts/jqwidgets-vue/vue_jqxfileupload.vue'; export default { components: { JqxFileUpload }, mounted: function () { this.$refs.myFileUpload.render(); } } </script> |
||
refresh | None | None |
Refreshes the widget. <template> <div> <p>Note: to be able to upload a file you would have to set the property uploadUrl to point to a file hosted on your server, which handles the upload process.</p> <JqxFileUpload ref="myFileUpload" /> </div> </template> <script> import JqxFileUpload from 'jqwidgets-scripts/jqwidgets-vue/vue_jqxfileupload.vue'; export default { components: { JqxFileUpload }, mounted: function () { this.$refs.myFileUpload.refresh(); } } </script> |
||
uploadFile | fileIndex | None |
Uploads a selected file. <template> <div> <p>Note: to be able to upload a file you would have to set the property uploadUrl to point to a file hosted on your server, which handles the upload process.</p> <JqxFileUpload ref="myFileUpload" @uploadStart="onUploadStart($event)" /> <p>You should browse for a file and then click the button to upload it:</p> <JqxButton @click="onClick()" :width="120">Upload File</JqxButton> </div> </template> <script> import JqxFileUpload from 'jqwidgets-scripts/jqwidgets-vue/vue_jqxfileupload.vue'; import JqxButton from 'jqwidgets-scripts/jqwidgets-vue/vue_jqxbuttons.vue'; export default { components: { JqxFileUpload, JqxButton }, methods: { onClick: function () { this.$refs.myFileUpload.uploadFile(0); }, onUploadStart: function (event) { alert('Uploading File...'); } } } </script> |
||
uploadAll | None | None |
Uploads all selected files. <template> <div> <p>Note: to be able to upload a file you would have to set the property uploadUrl to point to a file hosted on your server, which handles the upload process.</p> <JqxFileUpload ref="myFileUpload" @uploadStart="onUploadStart($event)" /> <p>You should browse for a file/files and then click the button to upload them:</p> <JqxButton @click="onClick()" :width="120">Upload Files</JqxButton> </div> </template> <script> import JqxFileUpload from 'jqwidgets-scripts/jqwidgets-vue/vue_jqxfileupload.vue'; import JqxButton from 'jqwidgets-scripts/jqwidgets-vue/vue_jqxbuttons.vue'; export default { components: { JqxFileUpload, JqxButton }, methods: { onClick: function () { this.$refs.myFileUpload.uploadAll(); }, onUploadStart: function (event) { alert('Uploading Files...'); } } } </script> |