Mpdx 153

Should this be abstracted to a separate script file that can be minified and shared?