Added initial setting of subscription buttons to entity pages. Also clea...

...ned up js