original_string: public function display() {
          $source = str_replace(['{VENDOR}', '{APP_ROOT}'], [LIBS_FOLDER, APP_ROOT], $this->jsSource);
          $url = AssetsPublisher::get()->publishFolder($source);
          $events = $this->getJSEvents();
          $r = Form::get()->input($this->name . '[]', 'file', null, [
                  'id' => $this->id,
                  'data-url' => $this->dataUrl,
                  'multiple' => 'multiple',
              ])
              . Html::get()->scriptFile($url . "js/vendor/jquery.ui.widget.js")
              . Html::get()->scriptFile($url . "js/jquery.iframe-transport.js")
              . Html::get()->scriptFile($url . "js/jquery.fileupload.js")
              . Html::get()->script("\$(function () {
      \$('#{$this->id}').fileupload({
          dataType: 'json' " . (isset($this->jsEventsHandlers['fileuploaddone'])?'': ",
          done: function (e, data) {
              $.each(data.result.files, function (index, file) {
                  $('<p/>').text(file.name).appendTo($(\"#{$this->resultsId}\"));
              });
          }") . "
      })$events;
  });");
          if ($this->generateResultsDiv) {
              $r .= Html::get()->tag("div", "", ["id" => $this->resultsId]);
          }
          return $r;
      }
code: public function display() {
          $source = str_replace(['{VENDOR}', '{APP_ROOT}'], [LIBS_FOLDER, APP_ROOT], $this->jsSource);
          $url = AssetsPublisher::get()->publishFolder($source);
          $events = $this->getJSEvents();
          $r = Form::get()->input($this->name . '[]', 'file', null, [
                  'id' => $this->id,
                  'data-url' => $this->dataUrl,
                  'multiple' => 'multiple',
              ])
              . Html::get()->scriptFile($url . "js/vendor/jquery.ui.widget.js")
              . Html::get()->scriptFile($url . "js/jquery.iframe-transport.js")
              . Html::get()->scriptFile($url . "js/jquery.fileupload.js")
              . Html::get()->script("\$(function () {
      \$('#{$this->id}').fileupload({
          dataType: 'json' " . (isset($this->jsEventsHandlers['fileuploaddone'])?'': ",
          done: function (e, data) {
              $.each(data.result.files, function (index, file) {
                  $('<p/>').text(file.name).appendTo($(\"#{$this->resultsId}\"));
              });
          }") . "
      })$events;
  });");
          if ($this->generateResultsDiv) {
              $r .= Html::get()->tag("div", "", ["id" => $this->resultsId]);
          }
          return $r;
      }
code_tokens: public function display ( ) { $ source = str_replace ( [ '{VENDOR}' , '{APP_ROOT}' ] , [ LIBS_FOLDER , APP_ROOT ] , $ this -> jsSource ) ; $ url = AssetsPublisher :: get ( ) -> publishFolder ( $ source ) ; $ events = $ this -> getJSEvents ( ) ; $ r = Form :: get ( ) -> input ( $ this -> name . '[]' , 'file' , null , [ 'id' => $ this -> id , 'data-url' => $ this -> dataUrl , 'multiple' => 'multiple' , ] ) . Html :: get ( ) -> scriptFile ( $ url . "js/vendor/jquery.ui.widget.js" ) . Html :: get ( ) -> scriptFile ( $ url . "js/jquery.iframe-transport.js" ) . Html :: get ( ) -> scriptFile ( $ url . "js/jquery.fileupload.js" ) . Html :: get ( ) -> script ( "\$(function () {
      \$('#{$this->id}').fileupload({
          dataType: 'json' " . ( isset ( $ this -> jsEventsHandlers [ 'fileuploaddone' ] ) ? '' : ",
          done: function (e, data) {
              $.each(data.result.files, function (index, file) {
                  $('<p/>').text(file.name).appendTo($(\"#{$this->resultsId}\"));
              });
          }" ) . "
      })$events;
  });" ) ; if ( $ this -> generateResultsDiv ) { $ r .= Html :: get ( ) -> tag ( "div" , "" , [ "id" => $ this -> resultsId ] ) ; } return $ r ; }
docstring: Returns the HTML code for the element.
  @return string
docstring_tokens: Returns the HTML code for the element .