* adjust the previewlink logic.
 * adjust template code.