[System.Web.Services.WebMethodAttribute(), System.Web.Script.Services.ScriptMethodAttribute()]
public static string[] myfunc(string a)
{
// do stuff
}
What does the stuff inside the [] do or used for?
This is an attribute. Generally speaking,
Attributes provide a powerful method of associating declarative information with C# code (types, methods, properties, and so forth). Once associated with a program entity, the attribute can be queried at run time and used in any number of ways.
For further information on this, please have a look here.