protected void uiButtonSearch_Click(object sender, EventArgs e) { BLL.Pages objData = new BLL.Pages(); objData.SearchPages(uiTextBoxSearch.Text); uiGridViewPages.DataSource = objData.DefaultView; uiGridViewPages.DataBind(); }
protected void Page_Load(object sender, EventArgs e) { if (!IsPostBack) { int pid = 0; if (Request.QueryString["pid"] != null) { try { pid = Convert.ToInt32(Request.QueryString["pid"].ToString()); } catch (Exception ex) { pid = 0; } } if (pid == 0) { Response.Redirect("~/Default.aspx"); } else { BLL.Pages page = new BLL.Pages(); page.LoadByPrimaryKey(pid); uiLabelTitle.Text = page.ArTitle; uiLiteralContent.Text = Server.HtmlDecode(page.ArContent); } } }
private void BindEnglishData() { BLL.Pages page = new BLL.Pages(); page.LoadByPrimaryKey(13); uiLabelEnTitle.Text = page.EnTitle; uiLiteralEnContent.Text = Server.HtmlDecode(page.EnContent); }
private void BindArabicData() { BLL.Pages page = new BLL.Pages(); page.LoadByPrimaryKey(13); uiLabelArTitle.Text = page.ArTitle; uiLiteralArContent.Text = Server.HtmlDecode(page.ArContent); }
protected void Page_Load(object sender, EventArgs e) { if (!IsPostBack) { BLL.Pages page = new BLL.Pages(); page.LoadByPrimaryKey(2); uiLiteralContent.Text = Server.HtmlDecode(page.ArContent); } }
protected void uiButtonUpdate_Click(object sender, EventArgs e) { BLL.Pages objData = new BLL.Pages(); objData = CurrentPage; objData.EnTitle = uiTextBoxEnTitle.Text; objData.ArTitle = uiTextBoxArTitle.Text; objData.EnContent = Server.HtmlEncode(uiFCKeditorEnContent.Value); objData.ArContent = Server.HtmlEncode(uiFCKeditorArContent.Value); objData.Save(); CurrentPage = null; uiPanelViewAllPages.Visible = true; uiPanelEdit.Visible = false; }
protected void uiGridViewPages_RowCommand(object sender, GridViewCommandEventArgs e) { if (e.CommandName == "EditPage") { BLL.Pages objData = new BLL.Pages(); objData.LoadByPrimaryKey(Convert.ToInt32(e.CommandArgument.ToString())); CurrentPage = objData; uiTextBoxArTitle.Text = objData.ArTitle; uiTextBoxEnTitle.Text = objData.EnTitle; uiFCKeditorArContent.Value = Server.HtmlDecode(objData.ArContent); uiFCKeditorEnContent.Value = Server.HtmlDecode(objData.EnContent); uiPanelViewAllPages.Visible = false; uiPanelEdit.Visible = true; } }
private void BindData() { BLL.Pages objData = new BLL.Pages(); objData.LoadAll(); uiGridViewPages.DataSource = objData.DefaultView; uiGridViewPages.DataBind(); }
private void LoadTerms() { BLL.Pages objTerms = new BLL.Pages(); objTerms.LoadByPrimaryKey(12); uiLiteralTerms.Text = Server.HtmlDecode(objTerms.ArContent); }