fix #4607 - scripts added twice
This commit is contained in:
parent
f2c854b53a
commit
1f2e2148d5
|
@ -44,7 +44,6 @@
|
||||||
}
|
}
|
||||||
|
|
||||||
// head content
|
// head content
|
||||||
AddHeadContent(headcontent, PageState.Site.HeadContent);
|
|
||||||
if (!string.IsNullOrEmpty(PageState.Site.HeadContent))
|
if (!string.IsNullOrEmpty(PageState.Site.HeadContent))
|
||||||
{
|
{
|
||||||
headcontent = AddHeadContent(headcontent, PageState.Site.HeadContent);
|
headcontent = AddHeadContent(headcontent, PageState.Site.HeadContent);
|
||||||
|
|
|
@ -534,9 +534,9 @@
|
||||||
|
|
||||||
private string ParseScripts(string content)
|
private string ParseScripts(string content)
|
||||||
{
|
{
|
||||||
// iterate scripts
|
|
||||||
var scripts = "";
|
var scripts = "";
|
||||||
if (!string.IsNullOrEmpty(content))
|
// in interactive render mode, parse scripts from content and inject into page
|
||||||
|
if (_renderMode == RenderModes.Interactive && !string.IsNullOrEmpty(content))
|
||||||
{
|
{
|
||||||
var index = content.IndexOf("<script");
|
var index = content.IndexOf("<script");
|
||||||
while (index >= 0)
|
while (index >= 0)
|
||||||
|
|
Loading…
Reference in New Issue
Block a user