Check documentation for the latest version of dhtmlxSuite Migrating from 1.7 to 2.0 DHTMLX Docs

Migrating from 1.7 to 2.0

  • dhtmlxVault is initialized only with the dhtmlXVaultObject() constructor which starts to take a number of parameters providing a required configuration
  • the create() method is deprecated, vault is inited from constructor
  • the setServerHandlers() method is deprecated. The handlers are set directly in the constructor or by using setURL(), setSWFURL() and setSLURL() methods
  • the setImagePath() method is deprecated, images and icons use css now
  • the events' handlers are attached with the attachEvent() method, old event handlers still will work
  • the Perl server side is not supported anymore

  • Init code
// version 1.7
var myVault = new dhtmlXVaultObject(); 
// version 2.0
var myVault = new dhtmlXVaultObject({
   container: "vaultObj",               // html container for vault
   uploadUrl: "handler.php",            // html4/html5 upload url
   swfPath:   "dhxvault.swf",           // path to flash uploader
   swfUrl:    "handler.php",            // flash upload url
   slXap:     "dhxvault.xap",           // path to silverlight uploader
   slUrl:     "https://.../handler.php" // silverlight upload url, FULL path required
  • Events code
// version 1.7
myVault.onUploadComplete = function(files) {
    // your code here
// version 2.0
myVault.attachEvent("onUploadComplete", function(files){
    // your code here
Back to top