Run once in an WSS/SPS site/area...

There are many times when you need to so somethign to a WSS site just after it has been created ... and before the users have get their sticky little hands on it.

Some of these might include setting up site groups, provisioning users into groups etc...

A nice way to do this is to use the ExecuteURL in the ONET.xml file of the site definition. This allows you to specify that a page be loaded right after the user clicks the OK button after they have picked the site template to use. This page (hint: create an ASP.Net page with some code to do your stuff) can sit in the _layouts directory somewhere and can programatically set your site up etc...

Here is the MSDN reference for it:

https://msdn.microsoft.com/library/default.asp?url=/library/en-us/spptsdk/html/tscamlexecuteurl_SV01113237.asp