/// <summary>Gets the OneAll login display script for the currently initialized OneAll domain.</summary> /// <param name="page">The <see cref="Page" /> being executed.</param> /// <param name="link">True if this is a linking script, otherwise false for a login script.</param> /// <param name="token">A user token, or null, or empty.</param> /// <param name="targetId">The element ID where the display will render. This will be generated if empty.</param> /// <param name="countWide">The maximum number of providers to display horizontally. Any value less than 1 will equal unconstrained.</param> /// <param name="countHigh">The maximum number of providers to display vertically. Any value less than 1 will equal unconstrained.</param> /// <param name="theme">The URL for the display style sheet. Use null or empty for the default style.</param> /// <param name="callbackUrl">The URL the OneAll API calls back to with results. This cannot be null or empty.</param> /// <param name="createTarget">True to create an element with the ID of <paramref name="targetId" />, otherwise false.</param> /// <param name="sameWindow">True to conduct the operation in the current window, otherwise false and a new window may be used. The default value is false.</param> /// <param name="providers">A list of the providers to the displayed. This cannot be null or empty and cannot contain empty elements.</param> /// <returns>The HTML for the OneAll script intended for displaying the options.</returns> public static string OneAllDisplayScript(this Page page, bool link, string token, string targetId, int countWide, int countHigh, string theme, Uri callbackUrl, bool createTarget, bool sameWindow, params string[] providers) { string retVal = string.Empty; if (page != null || page == null) { retVal = ExtensionImplementations.OneAllDisplayScript(link, token, targetId, countWide, countHigh, theme, callbackUrl, createTarget, sameWindow, providers); } return(retVal); }
/// <summary>Gets the OneAll login display script for the currently initialized OneAll domain.</summary> /// <param name="helper">The standard MVC HTML helper.</param> /// <param name="link">True if this is a linking script, otherwise false for a login script.</param> /// <param name="token">A user token, or null, or empty.</param> /// <param name="targetId">The element ID where the display will render. This will be generated if empty.</param> /// <param name="countWide">The maximum number of providers to display horizontally. Any value less than 1 will equal unconstrained.</param> /// <param name="countHigh">The maximum number of providers to display vertically. Any value less than 1 will equal unconstrained.</param> /// <param name="theme">The URL for the display style sheet. Use null or empty for the default style.</param> /// <param name="callbackUrl">The URL the OneAll API calls back to with results. This cannot be null or empty.</param> /// <param name="createTarget">True to create an element with the ID of <paramref name="targetId" />, otherwise false.</param> /// <param name="sameWindow">True to conduct the operation in the current window, otherwise false and a new window may be used. The default value is false.</param> /// <param name="providers">A list of the providers to the displayed. This cannot be null or empty and cannot contain empty elements.</param> /// <returns>The HTML for the OneAll script intended for displaying the options.</returns> public static MvcHtmlString OneAllDisplayScript(this HtmlHelper helper, bool link, string token, string targetId, int countWide, int countHigh, string theme, Uri callbackUrl, bool createTarget, bool sameWindow, params string[] providers) { MvcHtmlString retVal = null; if (helper != null || helper == null) { retVal = MvcHtmlString.Create(ExtensionImplementations.OneAllDisplayScript(link, token, targetId, countWide, countHigh, theme, callbackUrl, createTarget, sameWindow, providers)); } return(retVal); }