public string ShowHideArticlebyContentId(string requestParam) { string RetVal = string.Empty; EditHtmlContent EditArticle = null; int ContentId = 0; bool IsHidden = true; string[] Params; try { Params = Global.SplitString(requestParam, Constants.Delimiters.ParamDelimiter); ContentId = Convert.ToInt32(Params[0]); IsHidden = Convert.ToBoolean(Params[1]); if (ContentId > 0) { EditArticle = new EditHtmlContent(); RetVal = EditArticle.ShowHideArticlebyContentId(ContentId, IsHidden).ToString().ToLower(); } } catch (Exception Ex) { RetVal = string.Empty; Global.CreateExceptionString(Ex, null); } return RetVal; }
// Create new content page and add link on main html page public string EditArticle(string requestParam) { string RetVal = string.Empty; bool IsArticleUpdated = false; string OutCurrentPageNo = string.Empty; string MenuCategory = string.Empty; string OutCurrentTagNids = string.Empty; try { EditHtmlContent EditContent = new EditHtmlContent(); IsArticleUpdated = EditContent.EditArticleByArticleId(requestParam, out OutCurrentPageNo, out MenuCategory, out OutCurrentTagNids); if (IsArticleUpdated && !string.IsNullOrEmpty(OutCurrentPageNo) || !string.IsNullOrEmpty(OutCurrentTagNids)) { Session[Constants.SessionNames.CurrentArticlePageNo] = OutCurrentPageNo; Session[Constants.SessionNames.CurrentArticleTagIds] = OutCurrentTagNids; Session[Constants.SessionNames.CurrentArticleMenuCategory] = MenuCategory; } RetVal = IsArticleUpdated.ToString(); } catch (Exception Ex) { RetVal = string.Empty; Global.CreateExceptionString(Ex, null); } return RetVal; }