diff --git a/Oqtane.Client/UI/ThemeBuilder.razor b/Oqtane.Client/UI/ThemeBuilder.razor index 71543e03..21f4c997 100644 --- a/Oqtane.Client/UI/ThemeBuilder.razor +++ b/Oqtane.Client/UI/ThemeBuilder.razor @@ -92,6 +92,14 @@ { if (!firstRender) { + if (!string.IsNullOrEmpty(PageState.Site.HeadContent) && PageState.Site.HeadContent.Contains("") + 1; + await interop.IncludeScript(id, "", "", "", type, script.Substring(pos, script.IndexOf("") - pos), location.ToString().ToLower(), dataAttributes); } - var pos = script.IndexOf(">") + 1; - await interop.IncludeScript(id, "", "", "", type, script.Substring(pos, script.IndexOf("") - pos), location.ToString().ToLower(), dataAttributes); } index = content.IndexOf("" + Environment.NewLine; } - private string ParseScripts(string content) - { - var scripts = ""; - // in interactive render mode, parse scripts from content and inject into page - if (_renderMode == RenderModes.Interactive && !string.IsNullOrEmpty(content)) - { - var index = content.IndexOf("= 0) - { - scripts += content.Substring(index, content.IndexOf("", index) + 9 - index); - index = content.IndexOf("