filterTag extention function

Hi @pturmel,
I went through all the discussions relating to filterTag, I saw one of your suggestions too in Limit the information displayed when using the Tag Browse Tree.
You have suggested the implementation of the filterTag extension function.
But working example code for implementing it would be appreciated.

I have tried the code explained in other discussions relating to FilterTag function, But didn’t seem to workout.