I think restricted text (http://drupal.org/project/restricted_text) has similar implementations. It offers hooks you can use to extend and add various conditions too. Might be useful.

Drupal 7 port is here : http://drupal.org/node/1175630

Comments

tamasd’s picture

Status: Active » Closed (won't fix)

I have seen a few good tricks there, but I don't think that I can reuse bigger parts. The module functionality is similar, but conditional_text is much more powerful :)

Restricted text is really designed to do user role based hiding. Conditional text is pluggable both in the evaluations and the display. I also have a nice parser, which allows quite flexible syntax.