Improve performance by loading posts information via ajax only when necessary