My favorites | Sign in
Project Home Downloads Wiki Issues Source
Project Information


This is a widget for use within the Yii PHP framework. It uses the jQuery File Tree plugin to render the file browser.

CFileBrowserWidget example

Installation & Usage

The widget relises on a 'connector' that gets called via AJAX requests to display a folders contents. You can cut and paste the code in the ControllerActionSample file located in the extensions' folder into the controller of your choice.

You can then call the widget like this...

<?php $this->widget('application.extensions.cfilebrowser.CFileBrowserWidget',array(
		'loadMessage'=>'File Browser Is Loading...hang on a sec',
		'callbackFunction'=>'alert("I selected " + f)'
)); ?>


  • script - (required) The connector. You must specify as an array e.g. 'array("site/filebrowser")'
  • root - The location to start from (default: '/')
  • folderEvent - The event to expand a folder (default: 'click')
  • expandSpeed - Time in miliseconds (default: 500)
  • collapseSpeed - Time in miliseconds (default: 500)
  • callbackMethod - Where 'f' is the file selected
  • expandEasing - (optional)The easing method
  • collapseEasing - (optional) The easing method
  • loadMessage - (optional) Specify your own message
  • containerID - (optional) Specify your own div id (default: 'filebrowser')
  • cssFile - (optional) Specify your own CSS file or set as false for none

Powered by Google Project Hosting