That's a good idea.
Claus Färber wrote:
David Strauss david@fourkitchens.com schrieb/wrote:
I'm certainly no expert for the MediaWiki parser, but you could take a microtime() from the start of parsing and periodically check time elapsed. With anything beyond the allotted parsing time, the template would return either nothing or a warning.
This way, complex templates would sometimes work (if the server load is low) and sometimes not work (if the server load is high, causing longer execution times).
Better use a counter instead of real time. If a script requires less than, say, 100 "ticks", it will always work no matter how long a tick currently is.
Claus
foundation-l mailing list foundation-l@lists.wikimedia.org http://lists.wikimedia.org/mailman/listinfo/foundation-l