Skip to content

Conversation

MichaelRoosz
Copy link

Added support for js/ and js/tracker.php endpoints.

@MichaelRoosz MichaelRoosz force-pushed the add_js_and_backend_config branch from 31b2200 to 7f1f6b6 Compare August 16, 2019 21:20
$this->makeSetting('jsEndpoint', 'piwik.js', FieldConfig::TYPE_STRING, function (FieldConfig $field) {
$field->title = 'Tracker Javascript Path';
$field->uiControl = FieldConfig::UI_CONTROL_SINGLE_SELECT;
$field->availableValues = array(
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we'd also want matomo.js and matomo.php. Why not in general directly let users enter a value? Some rename them to say tracker.js or something else when they want to avoid ad blockers etc.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good point. I have added matomo.js/.php. Having a dropdown seems a bit more user friendly for not so advanced users to me. In most cases using /js/ should be good enough. I did some testing a while ago, and using /js/ for js and tracking requests was not blocked by any browser extension. If you like a free text value better, maybe it still makes sense to keep the dropdown and add something like "other" into it.

@MichaelRoosz MichaelRoosz force-pushed the add_js_and_backend_config branch from 7f1f6b6 to affc8a6 Compare August 18, 2019 18:44
@MichaelRoosz MichaelRoosz force-pushed the add_js_and_backend_config branch from affc8a6 to 8f64582 Compare August 18, 2019 18:52
@tsteur
Copy link
Member

tsteur commented Aug 19, 2019

Cheers @MichaelHeerklotz

@tsteur tsteur merged commit eef1a1d into matomo-org:master Aug 19, 2019
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

Successfully merging this pull request may close these issues.

2 participants