当前位置: 首页>>代码示例>>C#>>正文


C# EkMessageHelper类代码示例

本文整理汇总了C#中EkMessageHelper的典型用法代码示例。如果您正苦于以下问题:C# EkMessageHelper类的具体用法?C# EkMessageHelper怎么用?C# EkMessageHelper使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。


EkMessageHelper类属于命名空间,在下文中一共展示了EkMessageHelper类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: Page_Init

    protected void Page_Init(object sender, EventArgs e)
    {
        var m_refMsg = new ContentAPI().EkMsgRef;

        BackLabel.Text = m_refMsg.GetMessage("btn back");
        DeleteLabel.Text = m_refMsg.GetMessage("btn delete");

        //Register CSS
        Ektron.Cms.API.Css.RegisterCss(this, Ektron.Cms.API.Css.ManagedStyleSheet.EktronWorkareaCss);
        Ektron.Cms.API.Css.RegisterCss(this, Ektron.Cms.API.Css.ManagedStyleSheet.EktronWorkareaIeCss);
        Ektron.Cms.API.Css.RegisterCss(this, Ektron.Cms.API.Css.ManagedStyleSheet.EktronFixedPositionToolbarCss);
        Ektron.Cms.API.JS.RegisterJS(this, Ektron.Cms.API.JS.ManagedScript.EktronJFunctJS);

        ltrlStyleSheetJS.Text = _styleHelper.GetClientScript();

        _msgHelper = new EkMessageHelper(_contentApi.RequestInformationRef);

        Utilities.ValidateUserLogin();
        if (_contentApi.RequestInformationRef.IsMembershipUser == 1 || !_contentApi.IsARoleMember(Ektron.Cms.Common.EkEnumeration.CmsRoleIds.AdminPersonalize)) {
            Response.Redirect(_contentApi.ApplicationPath + "reterror.aspx?info=" + _contentApi.EkMsgRef.GetMessage("msg login cms user"), true);
            return;
        }

        BindToolbars();
        this.image_link_100.Attributes.Add("onclick", string.Format("return validateList('{0}');", _msgHelper.GetMessage("select target content")));
    }
开发者ID:jaytem,项目名称:minGit,代码行数:26,代码来源:TargetContentDelete.aspx.cs

示例2: Page_Load

    protected void Page_Load(object sender, System.EventArgs e)
    {
        Ektron.Cms.Content.EkContent objContentRef;
        objContentRef = _refContentApi.EkContentRef;

        RegisterResources();
        agentDisabled.Visible = false;
        ektronPageHeader.Visible = true;
        msgHelper = _refContentApi.EkMsgRef;

        this.ParseCurrentPageNumber();

        //Licensing Check
        if (!Ektron.Cms.DataIO.LicenseManager.LicenseManager.IsFeatureEnable(_refContentApi.RequestInformationRef, Ektron.Cms.DataIO.LicenseManager.Feature.SocialNetworking, false))
        {
            Utilities.ShowError(_refContentApi.EkMsgRef.GetMessage("feature locked error"));
            return;
        }

        if (!(_refCommonApi.IsAdmin() || objContentRef.IsARoleMember((long)Ektron.Cms.Common.EkEnumeration.CmsRoleIds.CommunityAdmin, _refCommonApi.RequestInformationRef.UserId, false)))
        {
            Utilities.ShowError(_refContentApi.EkMsgRef.GetMessage("User not authorized"));
            return;
        }
        if (!String.IsNullOrEmpty(Request.QueryString["mode"]))
        {
            pageMode = Request.QueryString["mode"];
        }

        DisplayData();
    }
开发者ID:jaytem,项目名称:minGit,代码行数:31,代码来源:DefaultNotificationPreferences.aspx.cs

示例3: btnDecline_Click

    protected void btnDecline_Click(object sender, System.EventArgs e)
    {
        string comment = "";
        Ektron.Cms.UI.CommonUI.ApplicationAPI appUI = new Ektron.Cms.UI.CommonUI.ApplicationAPI();
        m_refMsg = appUI.EkMsgRef;

        RegExpValidator.ErrorMessage = m_refMsg.GetMessage("content size exceeded");
        //RegExpValidator.ValidationExpression = Utilities.BuildRegexToCheckMaxLength(65000)
        RegExpValidator.Validate();
        if (RegExpValidator.IsValid)
        {
            if (DeclineText.Content.Trim().Length > 0)
            {
                comment = (string)("&comment=" + EkFunctions.UrlEncode((string)(DeclineText.Content.Trim().Replace("<p>", "").Replace("</p>", ""))));
            }
            if(comment.Length>255)
            {
                RegExpValidator.IsValid=false;
         	            ViewToolBar();
            }
            else
            {
                Response.Redirect(content_api.ApplicationPath + "content.aspx?id=" + hdnContentId.Value + "&fldid=" + hdnFolderId.Value + "&action=declinecontent&LangType=" + hdnLangType.Value + comment);
            }
        }
        else
        {
            ViewToolBar();
        }
    }
开发者ID:jaytem,项目名称:minGit,代码行数:30,代码来源:DeclineContent.aspx.cs

示例4: Page_Load

 protected void Page_Load(object sender, System.EventArgs e)
 {
     try
     {
         Response.CacheControl = "no-cache";
         Response.AddHeader("Pragma", "no-cache");
         Response.Expires = -1;
         CurrentUserId = m_refCommon.RequestInformationRef.UserId;
         m_refContent = m_refCommon.EkContentRef;
         m_refMsg = m_refCommon.EkMsgRef;
         RegisterResources();
         //TODO: Ross - Not sure which role to check
         if ((CurrentUserId == 0) || (Convert.ToBoolean(m_refCommon.RequestInformationRef.IsMembershipUser) && m_refContent.IsARoleMember((long)Ektron.Cms.Common.EkEnumeration.CmsRoleIds.TaxonomyAdministrator, CurrentUserId, false) == false))
         {
             Response.Redirect("login.aspx?fromLnkPg=1", false);
             return;
         }
         else
         {
             AppImgPath = m_refCommon.AppImgPath;
             EnableMultilingual = m_refCommon.EnableMultilingual;
             if ((Request.QueryString["action"] != null) && Request.QueryString["action"] != "")
             {
                 m_strPageAction = Request.QueryString["action"].ToLower();
             }
             Utilities.SetLanguage(m_refCommon);
             MenuLanguage = m_refCommon.ContentLanguage;
             switch (m_strPageAction)
             {
                 case "deleted":
                     Message.Text = m_refMsg.GetMessage("lbl menu") + " \'" + Request.QueryString["title"] + "\' " + m_refMsg.GetMessage("lbl deleted");
                     Message.Text = Message.Text + "<script language=\"javascript\">" + "\r\n";
                     Message.Text = Message.Text + "top.refreshMenuAccordion(" + MenuLanguage + ");" + "\r\n";
                     Message.Text = Message.Text + "</script>" + "\r\n";
                     break;
                 case "viewcontent":
                 case "removeitems":
                     Control m_vi;
                     m_vi = (Control)(LoadControl("controls/menu/viewitems.ascx"));
                     m_vi.ID = "menu";
                     DataHolder.Controls.Add(m_vi);
                     break;
                 case "viewmenu":
                     Control m_va;
                     m_va = (Control)(LoadControl("controls/menu/viewmenu.ascx"));
                     m_va.ID = "menuprops";
                     DataHolder.Controls.Add(m_va);
                     break;
             }
         }
     }
     catch (System.Threading.ThreadAbortException)
     {
         //Do nothing
     }
     catch (Exception ex)
     {
         Response.Redirect((string)("reterror.aspx?info=" + EkFunctions.UrlEncode(ex.Message + ".") + "&LangType=" + MenuLanguage), false);
     }
 }
开发者ID:jaytem,项目名称:minGit,代码行数:60,代码来源:Menu.aspx.cs

示例5: Page_Init

    protected void Page_Init(object sender, System.EventArgs e)
    {
        // resource text string tokens
            m_refMsg = m_refContentApi.EkMsgRef;

            string closeDialogText = (string) (m_refMsg.GetMessage("close this dialog"));
            string cancelText = (string) (m_refMsg.GetMessage("btn cancel"));

            // assign resource text string values
            btnConfirmOk.Text = m_refMsg.GetMessage("lbl ok");
            btnConfirmOk.NavigateUrl = "#" + m_refMsg.GetMessage("lbl ok");
            btnConfirmCancel.Text = cancelText;
            btnConfirmCancel.NavigateUrl = "#" + cancelText;
            btnCloseSyncStatus.Text = m_refMsg.GetMessage("close title");
            btnCloseSyncStatus.NavigateUrl = "#" + m_refMsg.GetMessage("close title");
            btnStartSync.Text = m_refMsg.GetMessage("btn sync now");

            closeDialogLink.Text = "<span class=\"ui-icon ui-icon-closethick\">" + m_refMsg.GetMessage("close title") + "</span>";
            closeDialogLink.NavigateUrl = "#" + System.Text.RegularExpressions.Regex.Replace((string) (m_refMsg.GetMessage("close title")), "\\s+", "");
            closeDialogLink.ToolTip = closeDialogText;
            closeDialogLink2.Text = closeDialogLink.Text;
            closeDialogLink2.NavigateUrl = closeDialogLink.NavigateUrl;
            closeDialogLink2.ToolTip = closeDialogText;
            closeDialogLink3.Text = closeDialogLink.Text;
            closeDialogLink3.NavigateUrl = closeDialogLink.NavigateUrl;
            closeDialogLink3.ToolTip = closeDialogText;

            lblSyncStatus.Text = string.Format(m_refMsg.GetMessage("lbl sync status"), " <span class=\"statusHeaderProfileId\"></span>");

            m_jsResources = (SyncResources) (LoadControl("sync/SyncResources.ascx"));
            m_jsResources.ID = "jsResources";
            sync_jsResourcesPlaceholder.Controls.Add(m_jsResources);
    }
开发者ID:jaytem,项目名称:minGit,代码行数:33,代码来源:cmsform.aspx.cs

示例6: Page_Init

    protected void Page_Init(object sender, EventArgs e)
    {
        Page.ClientScript.GetPostBackEventReference(this, string.Empty);

            CommonApi commonApi = new CommonApi();
            m_refMsg = commonApi.EkMsgRef;
            string sitepath = commonApi.SitePath;

            Package ruleEditorUI = new Package()
            {
                Components = new List<Ektron.Cms.Framework.UI.Component>
                {
                    // JS
                    Packages.Ektron.StringObject,
                    Packages.Ektron.JSON,
                    JavaScript.Create(Path.Combine(this.TemplateSourceDirectory, @"js\RuleEditor.js").Replace(@"\", "/")),
                    JavaScript.Create(Path.Combine(this.TemplateSourceDirectory, @"js\ektron.autogrow.js").Replace(@"\", "/")),
                    JavaScript.Create(Path.Combine(this.TemplateSourceDirectory, @"js\ektron.jeditable.js").Replace(@"\", "/")),
                    JavaScript.Create(Path.Combine(this.TemplateSourceDirectory, @"js\ektron.dropdown.js").Replace(@"\", "/")),

                    // Css
                    Packages.jQuery.jQueryUI.ThemeRoller,
                    Ektron.Cms.Framework.UI.Css.Create(Path.Combine(this.TemplateSourceDirectory, @"css\RuleEditor.css").Replace(@"\", "/"))
                }
            };
            ruleEditorUI.Register(this);

            JavaScript.RegisterJavaScriptBlock(this, string.Format("Ektron.RuleEditor.init('{0}', '{1}');", UniqueID, container.ClientID), false);
    }
开发者ID:jaytem,项目名称:minGit,代码行数:29,代码来源:RuleEditor.ascx.cs

示例7: Workarea_MenuActions

 public Workarea_MenuActions()
 {
     m_CommonApi = new CommonApi();
     m_ContentApi = new ContentAPI();
     m_EkContent = m_ContentApi.EkContentRef;
     m_refMsg = m_ContentApi.EkMsgRef;
 }
开发者ID:jaytem,项目名称:minGit,代码行数:7,代码来源:MenuActions.aspx.cs

示例8: CatalogEntry_PageFunctions_Js

 protected CatalogEntry_PageFunctions_Js()
 {
     _ContentApi = new ContentAPI();
     _MessageHelper = _ContentApi.EkMsgRef;
     _JsLibrary = new workareajavascript();
     _ApplicationPath = _ContentApi.ApplicationPath.TrimEnd(new char[] { '/' });
 }
开发者ID:jaytem,项目名称:minGit,代码行数:7,代码来源:CatalogEntry.PageFunctions.aspx.cs

示例9: EmailHelper

 public EmailHelper()
 {
     CommonApi objCommonApi = new CommonApi();
     gtMessEmail = objCommonApi.EkMsgRef;
     AppImgPath = objCommonApi.AppImgPath;
     AppPath = objCommonApi.AppPath;
 }
开发者ID:femiosinowo,项目名称:sssadl,代码行数:7,代码来源:EmailHelper.cs

示例10: Page_Load

 private void Page_Load(System.Object sender, System.EventArgs e)
 {
     XmlConfigData xml_config_data;
         try
         {
             m_refMsg = m_refContentApi.EkMsgRef;
             Utilities.ValidateUserLogin();
             StyleSheetJS.Text = m_refStyle.GetClientScript();
             RegisterResources();
             if (Request.QueryString["id"] != null)
             {
                 m_intId = Convert.ToInt64(Request.QueryString["id"]);
             }
             AppImgPath = m_refContentApi.AppImgPath;
             ViewXsltToolBar();
             xml_config_data = m_refContentApi.GetXmlConfiguration(m_intId);
             if (!(xml_config_data == null))
             {
                 display_xslt.Value = xml_config_data.PackageDisplayXslt;
             }
         }
         catch (Exception ex)
         {
             Utilities.ShowError(ex.Message);
         }
 }
开发者ID:jaytem,项目名称:minGit,代码行数:26,代码来源:viewxslt.aspx.cs

示例11: Page_Load

 protected void Page_Load(object sender, System.EventArgs e)
 {
     msgHelper = _refContentApi.EkMsgRef;
         Ektron.Cms.Content.EkContent objContentRef;
         objContentRef = _refContentApi.EkContentRef;
         string pageMode;
         string strgroupId;
         long groupId;
         //Licensing Check
         if (! Ektron.Cms.DataIO.LicenseManager.LicenseManager.IsFeatureEnable(_refContentApi.RequestInformationRef, Ektron.Cms.DataIO.LicenseManager.Feature.SocialNetworking, false))
         {
             Utilities.ShowError(_refContentApi.EkMsgRef.GetMessage("feature locked error"));
             return;
         }
         //Logged in user check
         if (!(_refCommonApi.IsAdmin() || objContentRef.IsARoleMember(Convert.ToInt64( Ektron.Cms.Common.EkEnumeration.CmsRoleIds.CommunityAdmin), _refCommonApi.RequestInformationRef.UserId, false) || _refCommonApi.RequestInformationRef.UserId > 0))
         {
             Utilities.ShowError(_refContentApi.EkMsgRef.GetMessage("User not authorized"));
             return;
         }
         //RegisterResources()
         agentDisabled.Visible = false;
         pageMode = Request.QueryString["mode"];
         strgroupId = Request.QueryString["id"];
         long.TryParse(strgroupId, out groupId);
         string ctrlname = Page.Request.Params["__EVENTTARGET"];
         if (Page.IsPostBack)
         {
             EditGroupsSettings(groupId);
         }
         else
         {
             DisplayGroupSettings(groupId);
         }
 }
开发者ID:jaytem,项目名称:minGit,代码行数:35,代码来源:UserGroupPreferences.ascx.cs

示例12: Page_Load

    protected void Page_Load(object sender, System.EventArgs e)
    {
        msgHelper = _refCommonApi.EkMsgRef;
        string pageAction;
        Ektron.Cms.Content.EkContent objContentRef;
        objContentRef = _refContentApi.EkContentRef;
        RegisterResources();
        SetServerJSVariables();
        //Licensing For 7.6
        if (!Ektron.Cms.DataIO.LicenseManager.LicenseManager.IsFeatureEnable(_refContentApi.RequestInformationRef, Ektron.Cms.DataIO.LicenseManager.Feature.UrlAliasing, false))
        {
            Utilities.ShowError(_refContentApi.EkMsgRef.GetMessage("feature locked error"));
            return;
        }
        if (!(_refCommonApi.IsAdmin() || objContentRef.IsARoleMember((long)Ektron.Cms.Common.EkEnumeration.CmsRoleIds.UrlAliasingAdmin, _refCommonApi.RequestInformationRef.UserId, false)))
        {
            Utilities.ShowError(_refContentApi.EkMsgRef.GetMessage("User not authorized"));
            return;
        }

        _manualAliasAPI = new Ektron.Cms.UrlAliasing.UrlAliasManualApi();

        //Labels got from resource file
        lblaliasname.Text = msgHelper.GetMessage("lbl alias");
        lblContentBlk = msgHelper.GetMessage("content block label");
        lblTitle.Text = msgHelper.GetMessage("generic title");
        lblLink.Text = msgHelper.GetMessage("lbl quick link") + ":";
        lblTemplates.Text = msgHelper.GetMessage("lbl quick link") + ":";
        lblPrimary.Text = msgHelper.GetMessage("lbl primary");
        lblActive.Text = msgHelper.GetMessage("active label");
        lblAddVar.Text = msgHelper.GetMessage("lbl alias additional variables");
        lblQueryStringAction.Text = msgHelper.GetMessage("lbl querstringaction");
        lblaliasname.ToolTip = lblaliasname.Text;
        lblTitle.ToolTip = lblTitle.Text;
        lblLink.ToolTip = lblLink.Text;
        lblTemplates.ToolTip = lblTemplates.Text;
        lblPrimary.ToolTip = lblPrimary.Text;
        lblActive.ToolTip = lblActive.Text;
        lblAddVar.ToolTip = lblAddVar.Text;
        lblQueryStringAction.ToolTip = lblQueryStringAction.Text;
        pageAction = Request.QueryString["action"];
        siteid = Request.QueryString["fId"];
        workareaDir = _refContentApi.RequestInformationRef.WorkAreaDir;
        if ((string)(pageAction) == "addalias")
        {
            DisplayAdd();
        }
        else if ((string)(pageAction) == "view")
        {
            DisplayView();
        }
        else if ((string)(pageAction) == "editalias")
        {
            DisplayEdit();
        }
        System.Collections.Generic.List<string> ext_alias = null;
        ext_alias = _manualAliasAPI.GetFileExtensions();
        listAliasExtension.DataSource = ext_alias;
        listAliasExtension.DataBind();
    }
开发者ID:jaytem,项目名称:minGit,代码行数:60,代码来源:urlManualAliasMaint.aspx.cs

示例13: content

 public content()
 {
     char[] endSlash = new char[] { '/' };
     this.ApplicationPath = m_refContentApi.ApplicationPath.TrimEnd(endSlash.ToString().ToCharArray());
     this.SitePath = m_refContentApi.SitePath.TrimEnd(endSlash.ToString().ToCharArray());
     m_refMsg = m_refContentApi.EkMsgRef;
 }
开发者ID:jaytem,项目名称:minGit,代码行数:7,代码来源:content.aspx.cs

示例14: Page_Load

        private void Page_Load(object sender, System.EventArgs e)
        {
            _ContentApi = new ContentAPI();
            _MessageHelper = _ContentApi.EkMsgRef;
            if (EkFunctions.UrlDecode(Request.RawUrl).ToLower().Contains("<script") | EkFunctions.UrlDecode(Request.RawUrl).ToLower().Contains("</script"))
            {
                Utilities.ShowError(_MessageHelper.GetMessage("invalid querstring"));
                return;
            }
            this.RegisterWorkareaCssLink();
            this.RegisterDialogCssLink();
            Ektron.Cms.API.JS.RegisterJSInclude(this, Ektron.Cms.API.JS.ManagedScript.EktronJS);
            Ektron.Cms.API.JS.RegisterJSInclude(this, Ektron.Cms.API.JS.ManagedScript.EktronStringJS);
            Ektron.Cms.API.JS.RegisterJSInclude(this, Ektron.Cms.API.JS.ManagedScript.EktronXmlJS);
            Ektron.Cms.API.JS.RegisterJSInclude(this, "../ekxbrowser.js", "ekxbrowserJS");
            Ektron.Cms.API.JS.RegisterJSInclude(this, "../ekutil.js", "ekutilJS");
            Ektron.Cms.API.JS.RegisterJSInclude(this, "../RadWindow.js", "RadWindowJS");
            Ektron.Cms.API.JS.RegisterJSInclude(this, "../ekformfields.js", "ekformfieldsJS");
            this.ClientScript.RegisterClientScriptBlock(this.GetType(), "InitializeRadWindow", "InitializeRadWindow();", true);

            this.Title.Text = this.GetMessage("lbl checkbox field");
            this.RadTabStrip1.Tabs[0].Text = this.GetMessage("tab general"); ;
            this.RadTabStrip1.Tabs[0].ToolTip = this.GetMessage("tab general") + " Tab"; ;
            this.RadTabStrip1.Tabs[1].Text = this.GetMessage("tab validation"); ;
            this.RadTabStrip1.Tabs[1].ToolTip = this.GetMessage("tab validation") + " Tab"; ;
            this.RadTabStrip1.Tabs[2].Text = this.GetMessage("tab advanced"); ;
            this.RadTabStrip1.Tabs[2].ToolTip = this.GetMessage("tab advanced") + " Tab"; ;
            this.lblDefVal.InnerHtml = this.GetMessage("lbl default value");
            this.lblDefValT.InnerHtml = this.GetMessage("lbl def val true");
            this.lblDefValF.InnerHtml = this.GetMessage("lbl def val false");
            this.lblCaption.InnerHtml = this.GetMessage("lbl caption c");
        }
开发者ID:jaytem,项目名称:minGit,代码行数:32,代码来源:checkboxfield.aspx.cs

示例15: Page_Load

    protected void Page_Load(object sender, System.EventArgs e)
    {
        m_refMsg = m_refCommon.EkMsgRef;
            AppImgPath = m_refCommon.AppImgPath;
            AppPath = m_refCommon.AppPath;
            m_strPageAction = Request.QueryString["action"];
            Utilities.SetLanguage(m_refCommon);
            MenuLanguage = m_refCommon.ContentLanguage;
            MenuId = Convert.ToInt64(Request.QueryString["menuid"]);
            if (Request.QueryString["view"] != null)
            {
                m_strViewItem = Request.QueryString["view"];
            }
            m_refContent = m_refCommon.EkContentRef;
            m_refContentApi = new ContentAPI();
            Utilities.SetLanguage(m_refContentApi);
            sitePath = m_refCommon.SitePath;

            m_strBackPage = Request.QueryString.ToString();
            // strip off refresh indicator
            if (m_strBackPage.EndsWith("&rf=1"))
            {
                // refresh is needed after we edit a submenu, but we don't want to keep refreshing if we use the same URL
                m_strBackPage = m_strBackPage.Substring(0, m_strBackPage.Length - 5);
            }

            DisplayPage();
    }
开发者ID:jaytem,项目名称:minGit,代码行数:28,代码来源:viewmenu.ascx.cs


注:本文中的EkMessageHelper类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。