@mattab opened this Issue on March 3rd 2020 Member

Bug reported by customer about non working Heatmaps on IIS:

I get an error when after installing the HeatMap plugin and creating my first recording.
It says:Requesting 'https://piwik.X/plugins/HeatmapSessionRecording/configs.php?idsite=1&trackerid=5lX6EM&url=http%3A%2F%2Ftest.test%2F' resulted in an error: curl_exec: connection timed out after 2016 milliseconds. hostname requested was: piwik.X. As a result, tracking Heatmaps and Session Recordings may not work. You may need to change your webserver configuration to allow access to this file via the Internet or Intranet.

Solution

This modification will work for everyone who uses IIS.
The file I have modified is the web.config in the plugins-folder.
The only thing I've added is this part:

<alwaysAllowedUrls>
<add url="/plugins/HeatmapSessionRecording/configs.php" />
</alwaysAllowedUrls>

And the whole file with looks now like this after the changes:

<?xml version="1.0" encoding="UTF-8"?>

<configuration>

<system.webServer>

<security>

<requestFiltering>

<denyUrlSequences>

<add sequence=".php" />

</denyUrlSequences>

<alwaysAllowedUrls>

<add url="/plugins/HeatmapSessionRecording/configs.php" />

</alwaysAllowedUrls>

</requestFiltering>

</security>

</system.webServer>

</configuration> 
@sgiehl commented on March 3rd 2020 Member

@mattab so what shall we change in core for that? 🤔 Or is that a reminder to create an FAQ?

@mattab commented on March 3rd 2020 Member

yes we need to change in core, so it just works by default.

@sgiehl commented on March 3rd 2020 Member

I'm not familiar with IIS, but wouldn't it be possible to create a new web.config within the plugin instead maybe?

@tsteur commented on March 4th 2020 Member

It won't work when it is placed in the plugin folder @sgiehl . Because it's overwritten by the plugins folder basically

@sgiehl commented on March 4th 2020 Member

Should we add that directly to core. Or add a hook instead, that allows the plugin to do that?

@tsteur commented on March 4th 2020 Member

We can add it directly to core

@mattab commented on March 5th 2020 Member

This was fixed in #15669

This Issue was closed on March 5th 2020
Powered by GitHub Issue Mirror