Plugins: How to Build a ThinkUp Plugin

finn edited this page Nov 1, 2010 · 3 revisions

Check the Twitter and Facebook plugins for examples of the state of the art of a ThinkUp plugin.

A plugin is located in /path/to/thinkup/webapp/plugin/pluginname/. Some notes on directories within a plugin directory:

  • assets: Like the main webapp, assets is where you store images, CSS, and JS for your plugin.
  • controller: This directory contains the guts of your plugin, and all PHP files in this directory get auto-included in ThinkUp at runtime. Here you define the functions that run your plugin, and register them with the Crawler and Webapp objects.
  • tests: All your plugin's model and controller methods should have regression tests. Include the tests in this directory, and any test data in the testdata directory.
  • view: Your plugin's Smarty templates live here.
  • Any other files in your plugin's directory will be available as regular web pages, like authorization callback URLs.
Clone this wiki locally
You can’t perform that action at this time.
You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session.
Press h to open a hovercard with more details.