using System;
using System.Collections.Specialized;
using System.Data;
using System.Collections;
using System.Text;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.HtmlControls;
using CMS.IO;
using CMS.OutputFilter;
using CMS.UIControls;
using CMS.URLRewritingEngine;
using CMS.SettingsProvider;
public partial class CMSMessages_RestorePostback : MessagePage
{
#region "Variables"
protected string okText = null;
protected string cancelText = null;
protected string mBodyParams = null;
#endregion
protected void Page_Load(object sender, EventArgs e)
{
titleElem.TitleText = GetString("RestorePostback.Header");
titleElem.TitleImage = GetImageUrl("Others/Messages/info.png");
lblInfo.Text = GetString("RestorePostback.Info");
okText = GetString("General.OK");
cancelText = GetString("General.Cancel");
// Add the state fields
SavedFormState state = FormStateHelper.GetSavedState();
if (state != null)
{
// Render the hidden fields for the form items
NameValueCollection form = state.Form;
foreach (string name in form.Keys)
{
ltlValues.Text += "\n";
}
state.Delete();
}
else
{
lblInfo.Text = GetString("RestorePostback.InfoNotSaved");
if (Request.RawUrl.IndexOfCSafe("/RestorePostback.aspx", true) < 0)
{
mBodyParams = "onload=\"document.location.replace(document.location.href); return false;\"";
}
plcOK.Visible = false;
cancelText = GetString("General.OK");
}
}
///