private void RegisterClientScript() { Page.ClientScript.RegisterClientScriptInclude( typeof(string), "accessrights_script", WebPath.GetPath("usercontrols/management/accessrights/js/accessrights.js") ); Page.ClientScript.RegisterClientScriptBlock( GetType(), "accessrights_style", "<link rel=\"stylesheet\" type=\"text/css\" href=\"" + WebSkin.GetUserSkin().GetAbsoluteWebPath("usercontrols/management/accessrights/css/<theme_folder>/accessrights.css") + "\">", false); var curTenant = CoreContext.TenantManager.GetCurrentTenant(); var currentOwner = CoreContext.UserManager.GetUsers(curTenant.OwnerId); var admins = WebItemSecurity.GetProductAdministrators(Guid.Empty).Where(admin => admin.ID != currentOwner.ID).SortByUserName(); Page.ClientScript.RegisterClientScriptBlock( typeof(AccessRights), "54F36EE2-0595-4e01-82BD-35E140D94F5D", "adminList = " + JavaScriptSerializer.Serialize(admins.ConvertAll(u => new { id = u.ID, smallFotoUrl = u.GetSmallPhotoURL(), displayName = u.DisplayUserName(), title = u.Title.HtmlEncode(), userUrl = CommonLinkUtility.GetUserProfile(u.ID, new Guid()), accessList = GetAccessList(u.ID) })) + "; ", true); }
/// <summary> /// Page_Load of the Page Controller pattern. /// See http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnpatterns/html/ImpPageController.asp /// </summary> protected void Page_Load(object sender, EventArgs e) { BookmarkingBusinessConstants.CommunityProductID = CommunityProduct.ID; string script = "<link href='" + WebSkin.GetUserSkin().GetAbsoluteWebPath("products/community/modules/bookmarking/app_themes/<theme_folder>/css/bookmarkingstyle.css") + "' rel='stylesheet' type='text/css' />"; this.Page.ClientScript.RegisterClientScriptBlock(typeof(string), Guid.NewGuid().ToString(), script); ServiceHelper = BookmarkingServiceHelper.GetCurrentInstanse(); container = new Container() { Body = new PlaceHolder(), Header = new PlaceHolder() }; IStudioMaster master = null; if (this.Master is IStudioMaster) { master = this.Master as IStudioMaster; master.ContentHolder.Controls.Add(container); } BookmarkingNavigationUtil.InitBookmarkingPage(container.Body.Controls); PageLoad(); }
protected override void PageLoad() { if (SetupInfo.WorkMode == WorkMode.Promo) { Response.Redirect(ASC.Blogs.Core.Constants.DefaultPageUrl, true); } _mobileVer = ASC.Web.Core.Mobile.MobileDetector.IsRequestMatchesMobile(this.Context); //lbtnPost.Text = BlogsResource.PostButton; FCKeditor.BasePath = VirtualPathUtility.ToAbsolute(CommonControlsConfigurer.FCKEditorBasePath); FCKeditor.ToolbarSet = "BlogToolbar"; FCKeditor.EditorAreaCSS = WebSkin.GetUserSkin().BaseCSSFileAbsoluteWebPath; FCKeditor.Visible = !_mobileVer; if (_mobileVer && Request["mobiletext"] != null) { _text = Request["mobiletext"]; } if (CheckTitle(txtTitle.Text)) { mainContainer.Options.InfoMessageText = ""; } var engine = BasePage.GetEngine(); mainContainer.BreadCrumbs.Add(new ASC.Web.Controls.BreadCrumb() { Caption = BlogsResource.NewPost }); this.Title = HeaderStringHelper.GetPageTitle(BlogsResource.AddonName, mainContainer.BreadCrumbs); InitPreviewTemplate(); InitSidePanel(engine, TagCloud); sideRecentActivity.TenantId = TenantProvider.CurrentTenantID; sideRecentActivity.ProductId = Product.CommunityProduct.ID; sideRecentActivity.ModuleId = ASC.Blogs.Core.Constants.ModuleID; base.InitSubscribers(actions); lbCancel.Attributes["name"] = FCKeditor.ClientID; if (IsPostBack) { var control = FindControl(Request.Params["__EVENTTARGET"]); if (lbCancel.Equals(control)) { Response.Redirect(ASC.Blogs.Core.Constants.DefaultPageUrl); } else { TryPostBlog(BasePage.GetEngine()); } } }
protected void Page_Load(object sender, EventArgs e) { ForumContainer.Options.InfoType = InfoType.Alert; StringBuilder sb = new StringBuilder(); sb.Append("<script language=\"javascript\" type=\"text/javascript\"> ForumMakerProvider.All='" + Resources.ForumResource.All + "'; "); sb.Append(" ForumMakerProvider.ConfirmMessage='" + Resources.ForumResource.ConfirmMessage + "'; "); sb.Append(" ForumMakerProvider.SaveButton='" + Resources.ForumResource.SaveButton + "'; "); sb.Append(" ForumMakerProvider.CancelButton='" + Resources.ForumResource.CancelButton + "'; "); sb.Append(" ForumMakerProvider.NameEmptyString='" + Resources.ForumResource.NameEmptyString + "'; "); sb.Append(" ForumContainer_PanelInfoID = '" + ForumContainer.GetInfoPanelClientID() + "'; "); sb.Append("</script>"); this.Page.ClientScript.RegisterClientScriptInclude(typeof(string), "forummaker_script", WebPath.GetPath(ForumManager.BaseVirtualPath.Substring(2) + "/js/forummaker.js")); this.Page.ClientScript.RegisterClientScriptBlock(typeof(string), "forummaker_script_init", sb.ToString(), false); SearchText = ""; if (!String.IsNullOrEmpty(Request["search"])) { SearchText = Request["search"]; } var tags = ForumDataProvider.GetTagCloud(TenantProvider.CurrentTenantID, 40); TabCloudContainer.Title = Resources.ForumResource.TagCloud; TabCloudContainer.HeaderCSSClass = "studioSideBoxTagCloudHeader"; TabCloudContainer.ImageURL = WebImageSupplier.GetAbsoluteWebPath("tagcloud.png"); foreach (RankTag tag in tags) { TagCloudItem item = new TagCloudItem(); item.TagName = tag.Name; item.TagID = tag.ID.ToString(); item.Rank = tag.Rank; item.URL = "search.aspx?tag=" + tag.ID; tagCloud.Items.Add(item); } if (tags.Count == 0) { TabCloudContainer.Visible = false; } sideRecentActivity.TenantId = TenantProvider.CurrentTenantID; sideRecentActivity.ProductId = Product.CommunityProduct.ID; sideRecentActivity.ModuleId = Forum.ForumManager.ModuleID; string script = "<link href=\"" + WebSkin.GetUserSkin().GetAbsoluteWebPath(ForumManager.BaseVirtualPath.Substring(2) + "/app_themes/<theme_folder>/style.css") + "\" rel=\"stylesheet\" type=\"text/css\" />"; this.Page.ClientScript.RegisterClientScriptBlock(typeof(string), Guid.NewGuid().ToString(), script); SetNavigation(); }
private void InitPage() { Utility.RegisterTypeForAjax(typeof(AjaxProHelper)); Utility.RegisterTypeForAjax(typeof(ListContactView)); Utility.RegisterTypeForAjax(typeof(CommonSettingsView)); if (IsSimpleView) { return; } //init popup _deletePanel.Options.IsPopup = true; _setPermissionsPanel.Options.IsPopup = true; _createLinkPanel.Options.IsPopup = true; _smtpSettingsPanel.Options.IsPopup = true; //init PrivatePanel var privatePanel = (PrivatePanel)LoadControl(PrivatePanel.Location); var usersWhoHasAccess = new List <string> { CustomNamingPeople.Substitute <CRMCommonResource>("CurrentUser").HtmlEncode() }; privatePanel.UsersWhoHasAccess = usersWhoHasAccess; privatePanel.DisabledUsers = new List <Guid> { SecurityContext.CurrentAccount.ID }; privatePanel.HideNotifyPanel = true; _phPrivatePanel.Controls.Add(privatePanel); //init taskAction var taskActionView = (TaskActionView)LoadControl(TaskActionView.Location); taskActionView.HideContactSelector = true; _phTaskActionView.Controls.Add(taskActionView); if (!MobileVer) { //init FCKeditor Editor = new FredCK.FCKeditorV2.FCKeditor { ID = "_fcKeditor", Height = 400, BasePath = CommonControlsConfigurer.FCKEditorBasePath, EditorAreaCSS = WebSkin.GetUserSkin().BaseCSSFileAbsoluteWebPath }; _phFCKeditor.Controls.Add(Editor); //init uploader var uploader = (FileUploader)LoadControl(FileUploader.Location); _phfileUploader.Controls.Add(uploader); } InitEmptyScreens(); }
public static void CommentsConfigure(CommentsList commentList) { commentList.DisableCtrlEnter = (SetupInfo.WorkMode == WorkMode.Promo); commentList.PID = CommonLinkUtility.GetProductID().ToString(); commentList.InactiveMessage = Resources.Resource.CommentRemovedMessage; commentList.UserProfileUrlResolver = user => CommonLinkUtility.GetUserProfile(user); commentList.UserPageLinkWithParam = VirtualPathUtility.ToAbsolute("~/userprofile.aspx") + "?" + CommonLinkUtility.GetProductParamsPair(new Guid(commentList.PID)) + "&uid"; commentList.AddCommentLink = Resources.Resource.AddNewCommentButton; commentList.SaveButton = Resources.Resource.PublishButton; commentList.BehaviorID = "_commentObj"; commentList.PreviewButton = Resources.Resource.PreviewButton; commentList.HidePrevuewButton = Resources.Resource.CloseButton; commentList.CancelButton = Resources.Resource.CancelButton; commentList.InactiveMessage = Resources.Resource.CommentWasRemoved; commentList.RemoveCommentLink = Resources.Resource.DeleteButton; commentList.ResponseCommentLink = Resources.Resource.AnswerButton; commentList.EditCommentLink = Resources.Resource.EditButton; commentList.FCKBasePath = FCKEditorBasePath; commentList.CommentsTitle = Resources.Resource.Comments; commentList.ConfirmRemoveCommentMessage = Resources.Resource.ConfirmRemoveCommentMessage; commentList.AdditionalSubmitText = "<span class=\"textMediumDescribe\" style=\"margin-left:5px;\">" + Resources.Resource.OrPress + "</span> <span class=\"textBase\">" + Resources.Resource.CtrlEnterKeys + "</span>"; commentList.FCKEditorAreaCss = WebSkin.GetUserSkin().BaseCSSFileAbsoluteWebPath; commentList.LoaderImage = WebImageSupplier.GetAbsoluteWebPath("ajax_progress_loader.gif"); commentList.CommentSendingMsg = Resources.Resource.PleaseWaitMessage; commentList.OnEditedCommentJS = "FCKCommentsController.EditCommentHandler"; commentList.OnCanceledCommentJS = "FCKCommentsController.CancelCommentHandler"; commentList.OnRemovedCommentJS = "FCKCommentsController.RemoveCommentHandler"; try { AjaxPro.Utility.RegisterTypeForAjax(typeof(CommonControlsConfigurer)); } catch { } }
protected void Page_Load(object sender, EventArgs e) { GetApiData(); IsMobile = Core.Mobile.MobileDetector.IsRequestMatchesMobile(Context); fckEditor.BasePath = CommonControlsConfigurer.FCKEditorBasePath; fckEditor.ToolbarSet = "BlogToolbar"; fckEditor.EditorAreaCSS = WebSkin.GetUserSkin().BaseCSSFileAbsoluteWebPath; fckEditor.Visible = !IsMobile; var discussionParticipants = new List <Participant>(); if (Discussion != null) { discussionTitle.Text = Discussion.Title; if (!IsMobile) { fckEditor.Value = Discussion.Content; } else { discussionContent.Text = Discussion.Content; } recipients = NotifySource.Instance.GetSubscriptionProvider() .GetRecipients(NotifyConstants.Event_NewCommentForMessage, String.Format("{0}_{1}", Discussion.UniqID, Discussion.Project.ID)); discussionParticipants.AddRange(recipients.Select(r => Global.EngineFactory.GetParticipantEngine().GetByID(new Guid(r.ID)))); Author = CoreContext.UserManager.GetUsers(Discussion.CreateBy); } else if (Project != null) { var projectParticipants = Global.EngineFactory.GetProjectEngine().GetTeam(Project.ID) .OrderBy(p => p.UserInfo, UserInfoComparer.Default) .ToList(); discussionParticipants.AddRange(projectParticipants); } Author = CoreContext.UserManager.GetUsers(SecurityContext.CurrentAccount.ID); discussionParticipantRepeater.DataSource = discussionParticipants; discussionParticipantRepeater.DataBind(); LoadDiscussionParticipantsSelector(); LoadDiscussionFilesControl(); }
public static String GetFileStaticRelativePath(String fileName) { if (fileName.EndsWith(".js")) { return(WebPath.GetPath("/products/files/js/" + fileName).ToLowerInvariant()); } if (fileName.EndsWith(".ascx")) { return(VirtualPathUtility.ToAbsolute("~/products/files/controls/" + fileName).ToLowerInvariant()); } if (fileName.EndsWith(".css")) { return(WebSkin.GetUserSkin().GetAbsoluteWebPath("/products/files/app_themes/<theme_folder>/" + fileName).ToLowerInvariant()); } return(fileName); }
public static String GetFileStaticRelativePath(String fileName) { if (fileName.EndsWith(".js")) { return(WebPath.GetPath("/products/crm/js/" + fileName)); } if (fileName.EndsWith(".ascx")) { return(VirtualPathUtility.ToAbsolute("~/products/crm/controls/" + fileName)); } if (fileName.EndsWith(".css")) { return(WebSkin.GetUserSkin().GetAbsoluteWebPath("/products/crm/app_themes/<theme_folder>/css/" + fileName)); } if (fileName.EndsWith(".png") || fileName.EndsWith(".gif") || fileName.EndsWith(".jpg")) { return(WebSkin.GetUserSkin().GetAbsoluteWebPath("/products/crm/app_themes/<theme_folder>/images/" + fileName)); } return(fileName); }
public static String GetFileStaticRelativePath(String fileName) { if (string.IsNullOrEmpty(fileName)) { return string.Empty; } if (fileName.EndsWith(".js")) { return WebPath.GetPath("/Products/Projects/js/" + fileName); } if (fileName.EndsWith(".png")) { return WebPath.GetPath("/Products/Projects/App_Themes/Default/Images/" + fileName); } if (fileName.EndsWith(".css")) { return WebSkin.GetUserSkin().GetAbsoluteWebPath("/Products/Projects/App_Themes/<theme_folder>/css/" + fileName); } return string.Empty; }
protected string RenderScripts() { var sb = new StringBuilder(); sb.AppendFormat("<link href=\"{0}\" rel=\"stylesheet\" type=\"text/css\"/>", WebSkin.GetUserSkin().GetAbsoluteWebPath("/products/community/modules/blogs/app_themes/<theme_folder>/blogstyle.css")); sb.AppendFormat("<script language=\"javascript\" src=\"{0}\" type=\"text/javascript\"></script>", WebPath.GetPath("/products/community/modules/blogs/js/blogs.js")); sb.AppendFormat("<script language=\"javascript\" src=\"{0}\" type=\"text/javascript\"></script>", WebPath.GetPath("js/tagsautocompletebox.js")); string script = @" function createSearchHelper() { var ForumTagSearchHelper = new SearchHelper( '_txtTags', 'tagAutocompleteItem', 'tagAutocompleteSelectedItem', '', '', 'BlogsPage', 'GetSuggest', '', true, false ); } "; Page.ClientScript.RegisterClientScriptBlock(typeof(string), "blogsTagsAutocompleteInitScript", script, true); return(sb.ToString()); }
protected void Page_Load(object sender, EventArgs e) { AjaxPro.Utility.RegisterTypeForAjax(this.GetType()); Page.ClientScript.RegisterClientScriptInclude(typeof(string), "skinsettingscontent_script", WebPath.GetPath("usercontrols/management/skinsettings/js/skinsettingscontent.js")); Page.ClientScript.RegisterClientScriptBlock(this.GetType(), "skinsettings_style", "<link rel=\"stylesheet\" type=\"text/css\" href=\"" + WebSkin.GetUserSkin().GetAbsoluteWebPath("usercontrols/management/skinsettings/css/<theme_folder>/skinsettings.css") + "\">", false); //Skin Settings var type = Request["type"] ?? ""; if (type != "customization") { var settings = SettingsManager.Instance.LoadSettings <WebSkinSettings>(TenantProvider.CurrentTenantID); _currentSkin = settings.WebSkin; } else { _currentSkin = WebSkin.GetUserSkin(); } var items = new List <object>(); foreach (var s in WebSkin.Skins) { items.Add(new { Id = s.ID, Name = s.DisplayName, Checked = string.Equals(s.ID, _currentSkin.ID, StringComparison.InvariantCultureIgnoreCase), Folder = s.FolderName, Path = WebImageSupplier.GetAbsoluteWebPath("skins/" + s.ID + ".png") }); } skinRepeater.DataSource = items; skinRepeater.DataBind(); }
protected void Page_Load(object sender, EventArgs e) { AjaxPro.Utility.RegisterTypeForAjax(this.GetType()); Page.ClientScript.RegisterClientScriptBlock(this.GetType(), "cust_style", "<link rel=\"stylesheet\" type=\"text/css\" href=\"" + WebSkin.GetUserSkin().GetAbsoluteWebPath("usercontrols/firsttime/customization/css/customization.css") + "\">", false); _dateandtimeHolder.Controls.Add(LoadControl(TimeAndLanguage.Location)); _namingPeopleHolder.Controls.Add(LoadControl(NamingPeopleSettingsContent.Location)); _schemaHolder.Controls.Add(LoadControl(SkinSettingsContent.Location)); }
protected void Page_Load(object sender, EventArgs e) { Page.ClientScript.RegisterClientScriptInclude(typeof(string), "sharing_settings_script", WebPath.GetPath("usercontrols/common/sharingsettings/js/sharingsettings.js")); Page.ClientScript.RegisterClientScriptBlock(GetType(), "sharing_settings_style", "<link rel=\"stylesheet\" type=\"text/css\" href=\"" + WebSkin.GetUserSkin().GetAbsoluteWebPath("usercontrols/common/sharingsettings/css/<theme_folder>/sharingsettings.css") + "\">", false); _sharingDialogContainer.Options.IsPopup = true; shareUserSelector.IsLinkView = true; shareUserSelector.LinkText = Core.Users.CustomNamingPeople.Substitute <Resources.Resource>("AddUsersForSharingButton"); var shareGroupSelector = (GroupSelector)LoadControl(GroupSelector.Location); shareGroupSelector.JsId = "shareGroupSelector"; shareGroupSelector.WithGroupEveryone = true; shareGroupSelector.WithGroupAdmin = true; _groupSelectorHolder.Controls.Add(shareGroupSelector); }
protected void Page_Load(object sender, EventArgs e) { AjaxPro.Utility.RegisterTypeForAjax(this.GetType()); Page.ClientScript.RegisterClientScriptBlock(this.GetType(), "accountlink_style", "<link rel=\"stylesheet\" type=\"text/css\" href=\"" + WebSkin.GetUserSkin().GetAbsoluteWebPath("usercontrols/users/userprofile/css/<theme_folder>/accountlink_style.css") + "\">", false); Page.ClientScript.RegisterClientScriptInclude(this.GetType(), "accountlink_script", WebPath.GetPath("usercontrols/users/userprofile/js/accountlinker.js")); InitProviders(); }
protected void Page_Load(object sender, EventArgs e) { cfg = new TalkConfiguration(); AjaxPro.Utility.RegisterTypeForAjax(this.GetType()); ((IStudioMaster)this.Master).DisabledSidePanel = true; Page.ClientScript.RegisterClientScriptInclude(this.GetType(), "gears.init", WebPath.GetPath("addons/talk/js/gears.init.js")); Page.ClientScript.RegisterClientScriptInclude(this.GetType(), "iscroll", WebPath.GetPath("addons/talk/js/iscroll.js")); if (cfg.EnabledFirebugLite) { Page.ClientScript.RegisterClientScriptInclude(this.GetType(), "firebug.lite", "https://getfirebug.com/firebug-lite.js"); } var culture = CultureInfo.CurrentCulture; Page.ClientScript.RegisterClientScriptBlock(this.GetType(), "talk.style", "<link rel=\"stylesheet\" type=\"text/css\" href=\"" + WebSkin.GetUserSkin().GetAbsoluteWebPath("addons/talk/css/<theme_folder>/talk.style.css") + "\" />", false); Page.ClientScript.RegisterClientScriptBlock(this.GetType(), "talk.location-style", "<link rel=\"stylesheet\" type=\"text/css\" href=\"" + WebSkin.GetUserSkin().GetAbsoluteWebPath("addons/talk/css/<theme_folder>/talk.style" + "." + culture.Name.ToLower() + ".css") + "\" />", false); Page.ClientScript.RegisterClientScriptBlock(this.GetType(), "talk.text-overflow", "<link rel=\"stylesheet\" type=\"text/css\" href=\"" + VirtualPathUtility.ToAbsolute("~/addons/talk/css/" + WebSkin.DefaultSkin.FolderName + "/talk.text-overflow.css") + "\" />", false); StringBuilder jsResources = new StringBuilder(); jsResources.Append("window.ASC=window.ASC||{};"); jsResources.Append("window.ASC.TMTalk=window.ASC.TMTalk||{};"); jsResources.Append("window.ASC.TMTalk.Resources={};"); jsResources.Append("window.ASC.TMTalk.Resources.statusTitles={}" + ';'); jsResources.Append("window.ASC.TMTalk.Resources.statusTitles.offline='" + EscapeJsString(Talk.Resources.TalkResource.StatusOffline) + "';"); jsResources.Append("window.ASC.TMTalk.Resources.statusTitles.online='" + EscapeJsString(Talk.Resources.TalkResource.StatusOnline) + "';"); jsResources.Append("window.ASC.TMTalk.Resources.statusTitles.away='" + EscapeJsString(Talk.Resources.TalkResource.StatusAway) + "';"); jsResources.Append("window.ASC.TMTalk.Resources.statusTitles.xa='" + EscapeJsString(Talk.Resources.TalkResource.StatusNA) + "';"); jsResources.Append("window.ASC.TMTalk.Resources.addonIcon='" + EscapeJsString(WebImageSupplier.GetAbsoluteWebPath("product_logo.png", TalkAddon.AddonID)) + "';"); jsResources.Append("window.ASC.TMTalk.Resources.addonIcon16='" + EscapeJsString(WebImageSupplier.GetAbsoluteWebPath("talk16.png", TalkAddon.AddonID)) + "';"); jsResources.Append("window.ASC.TMTalk.Resources.addonIcon32='" + EscapeJsString(WebImageSupplier.GetAbsoluteWebPath("talk32.png", TalkAddon.AddonID)) + "';"); jsResources.Append("window.ASC.TMTalk.Resources.addonIcon48='" + EscapeJsString(WebImageSupplier.GetAbsoluteWebPath("talk48.png", TalkAddon.AddonID)) + "';"); jsResources.Append("window.ASC.TMTalk.Resources.addonIcon128='" + EscapeJsString(WebImageSupplier.GetAbsoluteWebPath("talk128.png", TalkAddon.AddonID)) + "';"); jsResources.Append("window.ASC.TMTalk.Resources.iconNewMessage='" + EscapeJsString(WebSkin.GetUserSkin().GetAbsoluteWebPath("addons/talk/css/<theme_folder>/imagescss/icon-new-message.ico")) + "';"); jsResources.Append("window.ASC.TMTalk.Resources.productName='" + EscapeJsString(Talk.Resources.TalkResource.ProductName) + "';"); jsResources.Append("window.ASC.TMTalk.Resources.updateFlashPlayerUrl='" + EscapeJsString(Talk.Resources.TalkResource.UpdateFlashPlayerUrl) + "';"); jsResources.Append("window.ASC.TMTalk.Resources.selectUserBookmarkTitle='" + EscapeJsString(Talk.Resources.TalkResource.SelectUserBookmarkTitle) + "';"); jsResources.Append("window.ASC.TMTalk.Resources.defaultConferenceSubjectTemplate='" + EscapeJsString(Talk.Resources.TalkResource.DefaultConferenceSubjectTemplate) + "';"); jsResources.Append("window.ASC.TMTalk.Resources.labelNewMessage='" + EscapeJsString(Talk.Resources.TalkResource.LabelNewMessage) + "';"); jsResources.Append("window.ASC.TMTalk.Resources.labelRecvInvite='" + EscapeJsString(Talk.Resources.TalkResource.LabelRecvInvite) + "';"); jsResources.Append("window.ASC.TMTalk.Resources.titleRecvInvite='" + EscapeJsString(Talk.Resources.TalkResource.TitleRecvInvite) + "';"); // jsResources.Append("window.ASC.TMTalk.Resources.hintChangeState='" + EscapeJsString(Talk.Resources.TalkResource.HintChangeState) + "';"); jsResources.Append("window.ASC.TMTalk.Resources.hintClientConnecting='" + EscapeJsString(Talk.Resources.TalkResource.HintClientConnecting) + "';"); jsResources.Append("window.ASC.TMTalk.Resources.hintClientDisconnected='" + EscapeJsString(Talk.Resources.TalkResource.HintClientDisconnected) + "';"); // jsResources.Append("window.ASC.TMTalk.Resources.hintCtrlEnterSender='" + EscapeJsString(Talk.Resources.TalkResource.HintCtrlEnterSender) + "';"); // jsResources.Append("window.ASC.TMTalk.Resources.hintDisableSounds='" + EscapeJsString(Talk.Resources.TalkResource.HintDisableSounds) + "';"); jsResources.Append("window.ASC.TMTalk.Resources.hintEmotions='" + EscapeJsString(Talk.Resources.TalkResource.HintEmotions) + "',"); // jsResources.Append("window.ASC.TMTalk.Resources.hintEnableSounds='" + EscapeJsString(Talk.Resources.TalkResource.HintEnableSounds) + "';"); // jsResources.Append("window.ASC.TMTalk.Resources.hintEnterSender='" + EscapeJsString(Talk.Resources.TalkResource.HintEnterSender) + "';"); jsResources.Append("window.ASC.TMTalk.Resources.hintFlastPlayerIncorrect='" + EscapeJsString(Talk.Resources.TalkResource.HintFlastPlayerIncorrect) + "';"); jsResources.Append("window.ASC.TMTalk.Resources.hintGroups='" + EscapeJsString(Talk.Resources.TalkResource.HintGroups) + "';"); // jsResources.Append("window.ASC.TMTalk.Resources.hintHideGroups='" + EscapeJsString(Talk.Resources.TalkResource.HintHideGroups) + "';"); // jsResources.Append("window.ASC.TMTalk.Resources.hintHideOfflineContacts='" + EscapeJsString(Talk.Resources.TalkResource.HintHideOfflineContacts) + "';"); jsResources.Append("window.ASC.TMTalk.Resources.hintNoFlashPlayer='" + EscapeJsString(Talk.Resources.TalkResource.HintNoFlashPlayer) + "';"); jsResources.Append("window.ASC.TMTalk.Resources.hintOfflineContacts='" + EscapeJsString(Talk.Resources.TalkResource.HintOfflineContacts) + "';"); // jsResources.Append("window.ASC.TMTalk.Resources.hintSendAddition='" + EscapeJsString(Talk.Resources.TalkResource.HintSendAddition) + "';"); jsResources.Append("window.ASC.TMTalk.Resources.hintSendFile='" + EscapeJsString(Talk.Resources.TalkResource.HintSendFile) + "';"); // jsResources.Append("window.ASC.TMTalk.Resources.hintSendMessage='" + EscapeJsString(Talk.Resources.TalkResource.HintSendMessage) + "';"); // jsResources.Append("window.ASC.TMTalk.Resources.hintShowGroups='" + EscapeJsString(Talk.Resources.TalkResource.HintShowGroups) + "';"); // jsResources.Append("window.ASC.TMTalk.Resources.hintShowLeftTab='" + EscapeJsString(Talk.Resources.TalkResource.HintShowLeftTab) + "';"); // jsResources.Append("window.ASC.TMTalk.Resources.hintShowOfflineContacts='" + EscapeJsString(Talk.Resources.TalkResource.HintShowOfflineContacts) + "';"); // jsResources.Append("window.ASC.TMTalk.Resources.hintShowRightTab='" + EscapeJsString(Talk.Resources.TalkResource.HintShowRightTab) + "';"); jsResources.Append("window.ASC.TMTalk.Resources.hintSounds='" + EscapeJsString(Talk.Resources.TalkResource.HintSounds) + "';"); // jsResources.Append("window.ASC.TMTalk.Resources.hintToggleSender='" + EscapeJsString(Talk.Resources.TalkResource.HintToggleSender) + "';"); jsResources.Append("window.ASC.TMTalk.Resources.hintUpdateHrefText='" + EscapeJsString(Talk.Resources.TalkResource.HintUpdateHrefText) + "';"); jsResources.Append("window.ASC.TMTalk.Resources.hintSelectContact='" + EscapeJsString(Talk.Resources.TalkResource.HintSelectContact) + "';"); jsResources.Append("window.ASC.TMTalk.Resources.hintSendInvite='" + EscapeJsString(Talk.Resources.TalkResource.HintSendInvite) + "';"); jsResources.Append("window.ASC.TMTalk.Resources.hintPossibleClientConflict='" + EscapeJsString(Talk.Resources.TalkResource.HintPossibleClientConflict) + "';"); jsResources.Append("window.ASC.TMTalk.Resources.hintCreateShortcutDialog='" + EscapeJsString(Talk.Resources.TalkResource.HintCreateShortcutDialog) + "';"); jsResources.Append("window.ASC.TMTalk.Resources.sendFileMessage='" + EscapeJsString(string.Format(Talk.Resources.TalkResource.SendFileMessage, "{0}<br/>", "{1}")) + "';"); // jsResources.Append("window.ASC.TMTalk.Resources.noneGroupTitle='" + EscapeJsString(Talk.Resources.TalkResource.NoneGroupTitle) + "';"); jsResources.Append("window.ASC.TMTalk.Resources.mailingsGroupName='" + EscapeJsString(Talk.Resources.TalkResource.MailingsGroupName) + "';"); jsResources.Append("window.ASC.TMTalk.Resources.conferenceGroupName='" + EscapeJsString(Talk.Resources.TalkResource.ConferenceGroupName) + "';"); Page.ClientScript.RegisterClientScriptBlock(this.GetType(), "talk.resources", jsResources.ToString(), true); Page.ClientScript.RegisterClientScriptInclude(this.GetType(), "talk.customevents", WebPath.GetPath("addons/talk/js/talk.customevents.js")); Page.ClientScript.RegisterClientScriptInclude(this.GetType(), "talk.common", WebPath.GetPath("addons/talk/js/talk.common.js")); Page.ClientScript.RegisterClientScriptInclude(this.GetType(), "talk.navigationitem", WebPath.GetPath("addons/talk/js/talk.navigationitem.js")); Page.ClientScript.RegisterClientScriptInclude(this.GetType(), "talk.msmanager", WebPath.GetPath("addons/talk/js/talk.msmanager.js")); Page.ClientScript.RegisterClientScriptInclude(this.GetType(), "talk.mucmanager", WebPath.GetPath("addons/talk/js/talk.mucmanager.js")); Page.ClientScript.RegisterClientScriptInclude(this.GetType(), "talk.roomsmanager", WebPath.GetPath("addons/talk/js/talk.roomsmanager.js")); Page.ClientScript.RegisterClientScriptInclude(this.GetType(), "talk.contactsmanager", WebPath.GetPath("addons/talk/js/talk.contactsmanager.js")); Page.ClientScript.RegisterClientScriptInclude(this.GetType(), "talk.messagesmanager", WebPath.GetPath("addons/talk/js/talk.messagesmanager.js")); Page.ClientScript.RegisterClientScriptInclude(this.GetType(), "talk.connectionmanager", WebPath.GetPath("addons/talk/js/talk.connectiomanager.js")); Page.ClientScript.RegisterClientScriptInclude(this.GetType(), "talk.default", WebPath.GetPath("addons/talk/js/talk.default.js")); switch (cfg.RequestTransportType.ToLower()) { case "flash": Page.ClientScript.RegisterClientScriptInclude(this.GetType(), "talk.lib.checkplayer", VirtualPathUtility.ToAbsolute("~/addons/talk/js/jlib/flxhr/checkplayer.js")); Page.ClientScript.RegisterClientScriptInclude(this.GetType(), "talk.lib.flensed", VirtualPathUtility.ToAbsolute("~/addons/talk/js/jlib/flxhr/flensed.js")); Page.ClientScript.RegisterClientScriptInclude(this.GetType(), "talk.lib.flxhr", VirtualPathUtility.ToAbsolute("~/addons/talk/js/jlib/flxhr/flxhr.js")); Page.ClientScript.RegisterClientScriptInclude(this.GetType(), "talk.lib.base64", WebPath.GetPath("addons/talk/js/jlib/strophe/base64.js")); Page.ClientScript.RegisterClientScriptInclude(this.GetType(), "talk.lib.md5", WebPath.GetPath("addons/talk/js/jlib/strophe/md5.js")); Page.ClientScript.RegisterClientScriptInclude(this.GetType(), "talk.lib.core", WebPath.GetPath("addons/talk/js/jlib/strophe/core.js")); Page.ClientScript.RegisterClientScriptInclude(this.GetType(), "talk.lib.strophe.flxhr", WebPath.GetPath("addons/talk/js/jlib/plugins/strophe.flxhr.js")); Page.ClientScript.RegisterClientScriptInclude(this.GetType(), "talk.lib.swfobject", WebPath.GetPath("addons/talk/js/jlib/flxhr/swfobject.js")); break; default: Page.ClientScript.RegisterClientScriptInclude(this.GetType(), "talk.lib.base64", WebPath.GetPath("addons/talk/js/jlib/strophe/base64.js")); Page.ClientScript.RegisterClientScriptInclude(this.GetType(), "talk.lib.md5", WebPath.GetPath("addons/talk/js/jlib/strophe/md5.js")); Page.ClientScript.RegisterClientScriptInclude(this.GetType(), "talk.lib.core", WebPath.GetPath("addons/talk/js/jlib/strophe/core.js")); Page.ClientScript.RegisterClientScriptInclude(this.GetType(), "talk.lib.swfobject", WebPath.GetPath("addons/talk/js/jlib/flxhr/swfobject.js")); break; } try { Page.Title = Resources.TalkResource.ProductName + " - " + CoreContext.UserManager.GetUsers(SecurityContext.CurrentAccount.ID).DisplayUserName(); } catch (System.Security.SecurityException) { Page.Title = Resources.TalkResource.ProductName + " - " + HeaderStringHelper.GetPageTitle(Resources.TalkResource.DefaultContactTitle, null, null); } }
protected override void OnLoad(EventArgs e) { base.OnInit(e); var js = new StringBuilder(); js.Append("<script id=\"template-filter-combobox-options\" type=\"text/x-jquery-tmpl\">"); js.Append(" <option class=\"${classname}\" value=\"${value}\"{{if typeof def === 'boolean' && def === true}} selected=\"selected\"{{/if}}>${title}</option>"); js.Append("</script>"); js.Append("<script id=\"template-filter-filtervalues\" type=\"text/x-jquery-tmpl\">"); js.Append(" <div class=\"advansed-item-list advansed-filter-list\">"); js.Append(" <ul class=\"item-list filter-list\"></ul>"); js.Append(" </div>"); js.Append("</script>"); js.Append("<script id=\"template-filter-sortervalues\" type=\"text/x-jquery-tmpl\">"); js.Append(" <div class=\"advansed-item-list advansed-sorter-list\">"); js.Append(" <ul class=\"item-list sorter-list\"></ul>"); js.Append(" </div>"); js.Append("</script>"); js.Append("<script id=\"template-filter-container\" type=\"text/x-jquery-tmpl\">"); js.Append(" <div class=\"advansed-filter empty-filter-list\"><div class=\"advansed-filter-wrapper\">"); js.Append(" <label class=\"advansed-filter-state btn-start-filter\"></label>"); js.Append(" <label class=\"advansed-filter-sort btn-show-sorters\"></label>"); js.Append(" <div class=\"advansed-filter-container\">"); js.Append(" <div class=\"advansed-filter-filters empty-list\">"); js.Append(" <div class=\"btn-show-hidden-filters\">" + Resources.UserControlsCommonResource.BtnHiddenFilter + "</div>"); js.Append(" <div class=\"hidden-filters-container\">"); js.Append(" <div class=\"control-top hidden-filters-container-top\"></div>"); js.Append(" </div>"); js.Append(" </div>"); js.Append(" <div class=\"advansed-filter-button btn-show-filters\"><div class=\"inner-text\"><span class=\"text\">" + Resources.UserControlsCommonResource.LblFilterButton + "</span></span></div></div>"); js.Append(" <div class=\"advansed-filter-input\">"); js.Append(" <label class=\"advansed-filter-reset btn-reset-filter\"></label>"); js.Append(" <input class=\"advansed-filter advansed-filter-input advansed-filter-complete\" type=\"text\" placeholder=\"" + Resources.UserControlsCommonResource.LblFilterPlaceholder + "\" />"); js.Append(" </div>"); js.Append(" </div>"); js.Append(" {{if filtervalues.length > 0}}"); js.Append(" {{tmpl '#template-filter-filtervalues'}}"); js.Append(" {{/if}}"); js.Append(" {{if sortervalues.length > 0}}"); js.Append(" {{tmpl '#template-filter-sortervalues'}}"); js.Append(" {{/if}}"); js.Append(" </div><div class=\"advansed-filter-helper\"></div></div>"); js.Append("</script>"); js.Append("<script id=\"template-filter-item\" type=\"text/x-jquery-tmpl\">"); js.Append(" <div class=\"default-value\">"); js.Append(" <span class=\"title\">{{if filtertitle}}${filtertitle}{{else}}${title}{{/if}}</span>"); js.Append(" <span class=\"selector-wrapper\">"); js.Append(" <span class=\"daterange-selector from-daterange-selector\">"); js.Append(" <span class=\"label\">" + Resources.UserControlsCommonResource.LblFrom + "</span>"); js.Append(" <span class=\"advansed-filter-dateselector-date dateselector-from-date\">"); js.Append(" <span class=\"btn-show-datepicker btn-show-datepicker-container\"><span class=\"btn-show-datepicker btn-show-datepicker-title\"></span></span>"); js.Append(" <span class=\"advansed-filter-datepicker-container asc-datepicker\">"); js.Append(" <span class=\"control-top dateselector-top\"></span>"); js.Append(" <span class=\"datepicker-container\"></span>"); js.Append(" </span>"); js.Append(" </span>"); js.Append(" </span>"); js.Append(" <span class=\"daterange-selector to-daterange-selector\">"); js.Append(" <span class=\"label\">" + Resources.UserControlsCommonResource.LblTo + "</span>"); js.Append(" <span class=\"advansed-filter-dateselector-date dateselector-to-date\">"); js.Append(" <span class=\"btn-show-datepicker btn-show-datepicker-container\"><span class=\"btn-show-datepicker btn-show-datepicker-title\"></span></span>"); js.Append(" <span class=\"advansed-filter-datepicker-container asc-datepicker\">"); js.Append(" <span class=\"control-top dateselector-top\"></span>"); js.Append(" <span class=\"datepicker-container\"></span>"); js.Append(" </span>"); js.Append(" </span>"); js.Append(" </span>"); js.Append(" {{if options}}"); js.Append(" <span class=\"combobox-selector\">"); js.Append(" <select class=\"advansed-filter-combobox\"{{if $data.multiple === true}} multiple=\"multiple\"{{/if}}>"); js.Append(" {{tmpl(options) '#template-filter-combobox-options'}}"); js.Append(" </select>"); js.Append(" </span>"); js.Append(" {{/if}}"); js.Append(" <span class=\"group-selector\">"); //js.Append(" <span class=\"custom-value\"><span class=\"value\"></span> <small>▼</small></span>"); js.Append(" <span class=\"custom-value\"><span class=\"inner-text\"><span class=\"value\"></span></span></span>"); //js.Append(" <span class=\"default-value\"><span class=\"value\">" + Resources.UserControlsCommonResource.LblSelect + "</span> <small>▼</small></span>"); js.Append(" <span class=\"default-value\"><span class=\"inner-text\"><span class=\"value\">" + Resources.UserControlsCommonResource.LblSelect + "</span></span></span>"); js.Append(" </span>"); js.Append(" <span class=\"person-selector\">"); //js.Append(" <span class=\"custom-value\"><span class=\"value\"></span> <small>▼</small></span>"); js.Append(" <span class=\"custom-value\"><span class=\"inner-text\"><span class=\"value\"></span></span></span>"); //js.Append(" <span class=\"default-value\"><span class=\"value\">" + Resources.UserControlsCommonResource.LblSelect + "</span> <small>▼</small></span>"); js.Append(" <span class=\"default-value\"><span class=\"inner-text\"><span class=\"value\">" + Resources.UserControlsCommonResource.LblSelect + "</span></span></span>"); js.Append(" </span>"); js.Append(" </span>"); js.Append(" <span class=\"btn-delete\"></span>"); js.Append(" </div>"); js.Append("</script>"); Page.ClientScript.RegisterClientScriptBlock(this.GetType(), "jquery-advansedfilter", "<link rel=\"stylesheet\" type=\"text/css\" href=\"" + WebSkin.GetUserSkin().GetAbsoluteWebPath("/skins/<theme_folder>/jquery-advansedfilter.css") + "\" />", false); Page.ClientScript.RegisterClientScriptBlock(this.GetType(), "advansedfilter-templates", js.ToString(), false); Page.ClientScript.RegisterClientScriptInclude(this.GetType(), "jquery-customcombobox", WebPath.GetPath("js/jquery-customcombobox.js")); Page.ClientScript.RegisterClientScriptInclude(this.GetType(), "jquery-advansedfilter", WebPath.GetPath("js/jquery-advansedfilter.js")); var groupSelector = Page.LoadControl(GroupSelector.Location) as GroupSelector; //groupSelector.ID = "groupSelector"; groupSelector.JsId = "groupSelector"; //groupSelector.ClickButtonId = "someGrouSelectorButton11"; Controls.Add(groupSelector); var userSelector = new AdvancedUserSelector { ID = "userSelector" }; userSelector.IsLinkView = true; this.Controls.Add(userSelector); }
protected void Page_Load(object sender, EventArgs e) { Page.ClientScript.RegisterClientScriptInclude(typeof(string), "skinsettings_script", WebPath.GetPath("usercontrols/management/skinsettings/js/skinsettings.js")); Page.ClientScript.RegisterClientScriptBlock(this.GetType(), "skinsettings_style", "<link rel=\"stylesheet\" type=\"text/css\" href=\"" + WebSkin.GetUserSkin().GetAbsoluteWebPath("usercontrols/management/skinsettings/css/<theme_folder>/skinsettings.css") + "\">", false); content.Controls.Add(LoadControl(SkinSettingsContent.Location)); }
protected void Page_Load(object sender, EventArgs e) { AjaxPro.Utility.RegisterTypeForAjax(this.GetType()); var userMakerCss = "studio_usermaker_style"; if (!Page.ClientScript.IsClientScriptBlockRegistered(userMakerCss)) { Page.ClientScript.RegisterClientScriptBlock(this.GetType(), userMakerCss, "<link rel=\"stylesheet\" type=\"text/css\" href=\"" + WebSkin.GetUserSkin().GetAbsoluteWebPath("usercontrols/users/usermaker/css/<theme_folder>/usermaker.css") + "\">", false); } }
protected void Page_Load(object sender, EventArgs e) { AjaxPro.Utility.RegisterTypeForAjax(this.GetType()); Page.ClientScript.RegisterClientScriptInclude(typeof(string), "TimeAndLanguage_script", WebPath.GetPath("usercontrols/management/TimeAndLanguage/js/TimeAndLanguage.js")); Page.ClientScript.RegisterClientScriptBlock(this.GetType(), "TimeAndLanguage_style", "<link rel=\"stylesheet\" type=\"text/css\" href=\"" + WebSkin.GetUserSkin().GetAbsoluteWebPath("usercontrols/management/TimeAndLanguage/css/<theme_folder>/TimeAndLanguage.css") + "\">", false); _currentTenant = CoreContext.TenantManager.GetCurrentTenant(); }
protected void Page_Load(object sender, EventArgs e) { Page.ClientScript.RegisterClientScriptBlock(this.GetType(), "addcontent_style", "<link rel=\"stylesheet\" type=\"text/css\" href=\"" + WebSkin.GetUserSkin().GetAbsoluteWebPath("usercontrols/users/addcontent/css/<theme_folder>/addcontentcontrol_style.css") + "\">", false); AddContentContainer.Options.IsPopup = true; ContentTypesRepeater.DataSource = Types; ContentTypesRepeater.DataBind(); }
protected void Page_Load(object sender, EventArgs e) { AjaxPro.Utility.RegisterTypeForAjax(this.GetType()); Page.ClientScript.RegisterClientScriptInclude(typeof(string), "mailsettings_script", WebPath.GetPath("usercontrols/management/mailsettings/js/mailsettings.js")); Page.ClientScript.RegisterClientScriptBlock(this.GetType(), "mailsettings_style", "<link rel=\"stylesheet\" type=\"text/css\" href=\"" + WebSkin.GetUserSkin().GetAbsoluteWebPath("usercontrols/management/mailsettings/css/<theme_folder>/mailsettings.css") + "\">", false); if (!String.IsNullOrEmpty(CoreContext.Configuration.SmtpSettings.CredentialsDomain) || !String.IsNullOrEmpty(CoreContext.Configuration.SmtpSettings.CredentialsUserName)) { _isPesonalSMTP = true; } }
protected void Page_Load(object sender, EventArgs e) { if (String.IsNullOrEmpty(JsId)) { JsId = "groupSelector_" + _selectorID; } Page.ClientScript.RegisterClientScriptInclude(typeof(string), "groupselector_script", WebPath.GetPath("usercontrols/users/groupselector/js/groupselector.js")); Page.ClientScript.RegisterClientScriptBlock(GetType(), "groupselector_style", "<link rel=\"stylesheet\" type=\"text/css\" href=\"" + WebSkin.GetUserSkin().GetAbsoluteWebPath("usercontrols/users/groupselector/css/<theme_folder>/groupselector.css") + "\">", false); var sb = new StringBuilder(); sb.AppendFormat(" var {0} = new ASC.Controls.GroupSelector('{1}', {2});", JsId, _selectorID, IsMobileVersion.ToString().ToLower()); var strAppendGroup = "{0}.Groups.push({{Id : '{1}', Name : '{2}'}});"; if (IsMobileVersion) { sb.AppendFormat(strAppendGroup, JsId, -1, Resources.UserControlsCommonResource.LblSelect.HtmlEncode().ReplaceSingleQuote()); } if (WithGroupEveryone) { sb.AppendFormat(strAppendGroup, JsId, ASC.Core.Users.Constants.GroupEveryone.ID, Resources.UserControlsCommonResource.Everyone.HtmlEncode().ReplaceSingleQuote()); } if (WithGroupAdmin) { sb.AppendFormat(strAppendGroup, JsId, ASC.Core.Users.Constants.GroupAdmin.ID, Resources.UserControlsCommonResource.Admin.HtmlEncode().ReplaceSingleQuote()); } foreach (var grp in CoreContext.GroupManager.GetGroups().OrderBy(g => g.Name)) { sb.AppendFormat(strAppendGroup, JsId, grp.ID, grp.Name.HtmlEncode().ReplaceSingleQuote()); } Page.ClientScript.RegisterClientScriptBlock(GetType(), "group_selector_script_" + _selectorID, sb.ToString(), true); var str = IsMobileVersion ? @"<script id=""groupSelectorListTemplate"" type=""text/x-jquery-tmpl""> {{each(i, gpr) Groups}} <option value=""${gpr.Id}"" style='max-width:300px;'> ${gpr.Name} </option> {{/each}} </script>" : @"<script id=""groupSelectorListTemplate"" type=""text/x-jquery-tmpl""> {{each(i, gpr) Groups}} <div class=""group"" data=""${gpr.Id}"" title=""${gpr.Name}""> ${gpr.Name} </div> {{/each}} </script>"; Page.ClientScript.RegisterClientScriptBlock(GetType(), "group_selector_tmpl_script", str, false); }
protected void Page_PreInit(object sender, EventArgs e) { if (MobileDetector.IsRequestMatchesMobile(Context)) { Response.Redirect(CommonLinkUtility.GetFileWebViewerUrl(Request[UrlConstant.FileId]) + (string.IsNullOrEmpty(Request[UrlConstant.DocUrlKey]) ? "" : "&" + UrlConstant.DocUrlKey + "=" + Request[UrlConstant.DocUrlKey])); } if (!FileUtility.EnableHtml5) { Server.Transfer("editor.aspx", true); } //check if cookie from this portal if (SecurityContext.CurrentAccount is IUserAccount && ((IUserAccount)SecurityContext.CurrentAccount).Tenant != CoreContext.TenantManager.GetCurrentTenant().TenantId) { SecurityContext.Logout(); Response.Redirect("~/"); } var currentUser = CoreContext.UserManager.GetUsers(SecurityContext.CurrentAccount.ID); if (currentUser == Constants.LostUser || currentUser.Status != EmployeeStatus.Active) { SecurityContext.Logout(); Response.Redirect("~/"); } ProcessSecureFilter(); if (!SecurityContext.IsAuthenticated && DocumentUtils.ParseShareLink(Request[UrlConstant.DocUrlKey]) == null) { //for demo if (SetupInfo.WorkMode == WorkMode.Promo) { if (AutoAuthByPromo()) { UserOnlineManager.Instance.RegistryOnlineUser(SecurityContext.CurrentAccount.ID); Response.Redirect("~/"); return; } } var refererURL = Request.GetUrlRewriter().AbsoluteUri; if (!ValidateRefererUrl(refererURL)) { refererURL = (string)Session["refererURL"]; } if (!AutoAuthByCookies() && !CoreContext.TenantManager.GetCurrentTenant().Public) { Session["refererURL"] = refererURL; Response.Redirect("~/auth.aspx"); return; } } if (SecurityContext.IsAuthenticated) { UserOnlineManager.Instance.RegistryOnlineUser(SecurityContext.CurrentAccount.ID); } CurrentSkin = WebSkin.GetUserSkin(); Theme = CurrentSkin.ASPTheme; }
protected void Page_Load(object sender, EventArgs e) { icon.Options.IsPopup = true; icon.Options.PopupContainerCssClass = "okcss"; icon.Options.OnCancelButtonClick = "ImportUsersManager.HideInfoWindow('okcss');"; AjaxPro.Utility.RegisterTypeForAjax(this.GetType()); this.Page.ClientScript.RegisterClientScriptInclude(GetType(), "ajaxupload_script", VirtualPathUtility.ToAbsolute("~/js/ajaxupload.3.5.js")); Page.ClientScript.RegisterClientScriptBlock(this.GetType(), "import_style", "<link rel=\"stylesheet\" type=\"text/css\" href=\"" + WebSkin.GetUserSkin().GetAbsoluteWebPath("usercontrols/users/importusers/css/import.css") + "\">", false); //Page.ClientScript.RegisterClientScriptInclude(typeof(string), "importuser_script_sdk", WebPath.GetPath("usercontrols/users/ImportUsers/js/jquery-1.7.1.min.js")); Page.ClientScript.RegisterClientScriptInclude(typeof(string), "importuser_script", WebPath.GetPath("usercontrols/users/ImportUsers/js/ImportUsers.js")); }
protected void Page_Load(object sender, EventArgs e) { Page.ClientScript.RegisterClientScriptInclude(GetType(), "searchresults_script", WebPath.GetPath("usercontrols/common/search/js/searchresults.js")); Page.ClientScript.RegisterClientScriptBlock(GetType(), "searchresults_style", "<link rel=\"stylesheet\" type=\"text/css\" href=\"" + WebSkin.GetUserSkin().GetAbsoluteWebPath("usercontrols/common/search/css/<theme_folder>/searchResults.css") + "\">", false); results.ItemDataBound += results_ItemDataBound; results.DataSource = DataSourceObj; results.DataBind(); }
protected void Page_Load(object sender, EventArgs e) { AjaxPro.Utility.RegisterTypeForAjax(GetType()); Page.ClientScript.RegisterClientScriptBlock(this.GetType(), "adduser_style", "<link rel=\"stylesheet\" type=\"text/css\" href=\"" + WebSkin.GetUserSkin().GetAbsoluteWebPath("usercontrols/firsttime/addusers/css/<theme_folder>/addusers.css") + "\">", false); Page.ClientScript.RegisterClientScriptInclude(typeof(string), "adduser_script", WebPath.GetPath("usercontrols/firsttime/addusers/js/addusers.js")); }
protected void Page_Load(object sender, EventArgs e) { Page.ClientScript.RegisterClientScriptBlock(this.GetType(), "howto_style", "<link rel=\"stylesheet\" type=\"text/css\" href=\"" + WebSkin.GetUserSkin().GetAbsoluteWebPath("usercontrols/firsttime/howto/css/<theme_folder>/howto.css") + "\">", false); }
private void InitScripts() { Page.ClientScript.RegisterClientScriptInclude(this.GetType(), "navpanel_script", WebPath.GetPath("usercontrols/common/navigationpanel/js/navigator.js")); Page.ClientScript.RegisterClientScriptBlock(this.GetType(), "navpanel_style", "<link rel=\"stylesheet\" type=\"text/css\" href=\"" + WebSkin.GetUserSkin().GetAbsoluteWebPath("usercontrols/common/navigationpanel/css/<theme_folder>/navigationpanel.css") + "\">", false); }
protected void Page_Load(object sender, EventArgs e) { //ajax AjaxPro.Utility.RegisterTypeForAjax(this.GetType()); //js Page.ClientScript.RegisterClientScriptInclude(this.GetType(), "whatsnew_script", WebPath.GetPath("usercontrols/common/whatsnew/js/whatsnew.js")); //jTemplate const string jTemplateJavaScript = "jTemplateJavaScript"; if (!Page.ClientScript.IsClientScriptBlockRegistered(jTemplateJavaScript)) { Page.ClientScript.RegisterClientScriptInclude(jTemplateJavaScript, WebPath.GetPath("js/jquery-jtemplates.js")); } const string WhatsNewCssStyle = "studio_whatsnew_style"; if (!Page.ClientScript.IsClientScriptBlockRegistered(this.GetType(), WhatsNewCssStyle)) { Page.ClientScript.RegisterClientScriptBlock(this.GetType(), WhatsNewCssStyle, "<link rel=\"stylesheet\" type=\"text/css\" href=\"" + WebSkin.GetUserSkin().GetAbsoluteWebPath("usercontrols/common/whatsnew/css/<theme_folder>/whatsnew.css") + "\">", false); } }