Several folks have asked for this, so here it is... the two other pieces of the ResourceRedirect solution from my LAYOUTS branding post. They're also the least interesting, which is why I didn't post them before. :) Enjoy... review this post for the full context.
Redirect.cs
using
namespace
{
pattern = _pattern;
masterPageUrl = _masterPageUrl;
originalMaster = _originalMaster;
destinationPageUrl = _destinationPageUrl;
}
RedirectSectionHandler.cs
#region
XmlElement root = (XmlElement)section;
XmlNode patternNode = parentNode.Attributes.GetNamedItem(
XmlNode originalMasterNode = parentNode.Attributes.GetNamedItem(
XmlNode masterPageUrlNode = parentNode.Attributes.GetNamedItem(
XmlNode destinationPageUrlNode = parentNode.Attributes.GetNamedItem(
Redirect redirect =
coll.Add(redirect);
#endregion