Try our conversational search powered by Generative AI!

EPI Server Find Issue in China

Vote:
 

I have an issue with Find. We are using OXXCommerce as our base to develop an ecommerce solution. This is required to run in China as well. We have noticed that the in China, the page is loading fine, but the carasouel, cart page etc are loading very slow.

After checking, we have realized that find.js and native.history.js is getting fail to load and taking a very long time to provide the status that it is failed to load. From the browser profiler, we have noticed that the moment the browser is receiving that status, it is loading the carasouel etc quickly.

Now, I believe that these .js are coming from CDN and in China it is not allowed. But I want to know the workaround or how to easily disable the Find as OXXcommerce project has extensive use of Episerver Find.

Any Help is appreciated here as we are running out of time for this issue.

#175568
Feb 23, 2017 9:26
Vote:
 

Hi

You can define your own cdn/path to the js on your server in module.config with adding these lines under "clientresource"

<add name="browserstate.history" path="/your/path/here//native.history.js" resourceType="Script" />
<add name="epi.find.trackingScript" path="/your/path/here/find.js" resourceType="Script">


If you don't have your own module.config then make one in your webproject at root level (next to web.config)

And should look something like ths

<?xml version="1.0" encoding="utf-8"?>
<module>
  <assemblies>
    <!-- This adds the Alloy template assembly to the "default module" -->
<!-- you should change this to your assemblyname -->
    <add assembly="AlloyDemoKit" />
  </assemblies>
  <clientResources>
    <add name="browserstate.history" path="/your/path/here/native.history.js" resourceType="Script" />
    <add name="epi.find.trackingScript" path="/your/path/here/find.js" resourceType="Script">
      <dependencies>
        <add name="browserstate.history" />
      </dependencies>
    </add>
  </clientResources>
  </module>

But remember that you need to update those files yourself later when updates comes for them on the cdn

#175571
Edited, Feb 23, 2017 10:30
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.