improved rating script

Reduced the number of requests made towards reddit. Added support for
increasing the number of tags searched for without the need to copy +
paste more lines of code.
Rating page template
defined variable before usage in time_ago