allow treedata to be changed at runtime
Added support for both  Bootstrap 2 and Bootstrap 3