Vincent Massol wrote:
Interesting problem... I think there are several possibilities:
1) You intercept page save and parse the content to add links for acronyms. 2) You do as you suggest and play with the rendering. This means that the links will not exist in the database though
I prefer 1) because with 2) you'll probably not benefit from features like automatic page rename. In addition 1) is easier to implement as we have a notification API to get called when the page is saved for example.
What algorithm will you use to detect an acronym vs a standard word?
2) done and stored in plugin section. On second thought, 1) is not that important with acronyms because they are immutable. However, if existing renaming concept tries to rename everything at once, and if 1) is used, then there is a race condition between automatic links and renaming. Renaming should leave old page as redirect page for some time. Redirect page should be detectable by link processors (using special class?), so they can detect outdated links and replace them eventually.