adding publish/unpublish button to preview page