Skip to content

add PLAUSIBLE_PREFIX support to Helpers.php#238

Closed
semanticfire wants to merge 3 commits intoplausible:developfrom
netage:semanticfire-patch-proxy
Closed

add PLAUSIBLE_PREFIX support to Helpers.php#238
semanticfire wants to merge 3 commits intoplausible:developfrom
netage:semanticfire-patch-proxy

Conversation

@semanticfire
Copy link
Copy Markdown

Allow a different filename in proxy configuration

related to issue #228
Some ad blockers bluntly block anything that contains plausible Making the $file_name configurable together with the proper rewrite rule solved this.

wp_config.php should contain a line like

define('PLAUSIBLE_PREFIX','stats')

my nginx config now reads:

 location ~ /js/stats.(?<target>(.*?)).js {
        proxy_pass https://myplausibel.com/js/plausible.$target.js?ver=2.1.4;
        proxy_set_header Host myplausible.com;
}

Allow a different filename in proxy configuration

related to issue plausible#228
Some ad blockers bluntly block anything that contains `plausible`
Making the $file_name configurable together with the proper rewrite rule solved this.

wp_config.php should contain a line like
```
define('PLAUSIBLE_PREFIX','stats')
```

my nginx config now reads:
```
 location ~ /js/stats.(?<target>(.*?)).js {
        proxy_pass https://myplausibel.com/js/plausible.$target.js?ver=2.1.4;
        proxy_set_header Host myplausible.com;
}
```
Merge plausible original branch 2.3.2
@Dan0sz
Copy link
Copy Markdown
Collaborator

Dan0sz commented Mar 26, 2026

Closing this PR, because it's no longer relevant. get_filename() now gets the configuration ID using the API and uses that as the filename.

@Dan0sz Dan0sz closed this Mar 26, 2026
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