I know I can access the head section of a page which uses a masterpage programmatically this way (in code behind):
This is only an example (I’d like to insert scripts and styles etc.):
this.Header.Title = 'I just set the page's title';
Is there a simple way to do this in a declarative way on in the aspx file itself?
Sometimes it would be handy to insert a client script or a style declaration or a link to an external resource.
You can do this by using content regions in the
head, in exactly the same way as you would in thebodyof the page. eg, In your masterpage:And then in the page itself just something like: