Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

RequestReduce having issues with Umbraco backoffice #270

Open
ybhatti opened this issue Feb 4, 2016 · 1 comment
Open

RequestReduce having issues with Umbraco backoffice #270

ybhatti opened this issue Feb 4, 2016 · 1 comment

Comments

@ybhatti
Copy link

ybhatti commented Feb 4, 2016

I have a site that uses Umbraco.
The site renders as expected with Request Reduce.
However the Umbraco back office renders incorrectly (more than one and head in page etc...)
I nice way to get around this issue would be to ignore the Umbraco back office pages for Request Reduce
Is there anyway to configure RequestReduce to ignore the Umbraco back office?
I tried the "javascriptUrlsToIgnore" property by setting it to "/umbraco/" but that didn't work

@srmooney
Copy link

I had a similar issue, but it was with another part of the site. I was able to ignore certain urls using the PageFilter API on the url path with the following code (VB.net):

Namespace WSC
    Public Class StartupModule
        Implements IHttpModule

        Private Shared _lockObj As New Object()
        Private Shared _ran As Boolean = False

        Public Sub Dispose() Implements IHttpModule.Dispose
        End Sub

        Public Sub Init(context As HttpApplication) Implements IHttpModule.Init
            '-- lock
            If Not _ran Then
                SyncLock _lockObj
                    If Not _ran Then
                        ' everything we do here is blocking
                        ' on application start, so we should be quick. 
                        RequestReduce.Api.Registry.AddFilter(New RequestReduce.Api.PageFilter(Function(x) Not x.HttpRequest.Url.Host.Contains("/specsheet.aspx")))
                        _ran = True
                    End If
                End SyncLock
            End If
        End Sub
    End Class
End Namespace

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants