This project is read-only.


Awesome.ClientID can be configured one of two ways.
  • Page per Page
  • All pages via HTTPModule in the web.config

Page per Page

To serialize the information simply override the PreRenderComplete method of the page, passing in the page and call Serialize().

        protected override void OnPreRenderComplete(EventArgs e)

            new PageSerializer(this).Serialize();

I suggest the PreRenderComplete so that anything you've changed to controls/properties during PreRender, Load, Init, etc will be included in the serialization.

All pages via HTTPModule

This is similar and doesn't require changing of the code in your pages, handy if you don't have access to the source code, or can't be bothered doing it on a page-by-page basis. Tho you wont get the luxuary of properties if you can't modify the source code since they require Attributes. (See Property serialization documentation for more info)

To configure this you just need to add 1 (or two, if you're using IIS7) lines to your web.config.

The first section goes in system.web:

<add name="PageSerializer" type="Awesome.ClientID.PageSerializerModule, Awesome.ClientID"/>

And the second, which is identical, goes in the system.webServer section:

<add name="PageSerializer" type="Awesome.ClientID.PageSerializerModule, Awesome.ClientID"/>


Last edited Jan 6, 2011 at 12:51 PM by NaturalCause, version 3


No comments yet.