Added script to include preview

This fixes the undefined issue shown here "https://github.com/lepture/editor/issues/49#issuecomment-50199580"
Merge pull request #51 from muffinjello/patch-1

Added script to include preview