Child pages
  • Sakai - External gadget - Best practices & Install

Versions Compared


  • This line was added.
  • This line was removed.
  • Formatting was changed.


  • It's always a good idea to keep your CSS external. This makes it faster when you load your widget several times, it is more manageable and it is easier to convert you widget from Sakai 2 to 3.
  • (put the following code in your head tag)
    Code Block
     <link type="text/css" href="/devwidgets/filemanager/css/filemanager.css"  />

External JavaScript

  • The same rule counts for JavaScript files. You should always separate your JavaScript from the (x)HTML code and put it in another file. (so avoid using onlick="")
  • Code Block
     <script type="text/javascript" language="JavaScript" src="/devwidgets/filemanager/lib/jquery.accordion.js" ></script>

Use labels

  • For accessibility purposes always use labels in combination with a input type "text", "checkbox", ... and with textareas.
  • Code Block
    <input type="checkbox" name="filemanager_option_public" id="filemanager_option_public" />
    <label for="filemanager_option_public">Public</label>