Answer the question
In order to leave comments, you need to log in
Adblock blocks js script. Will https help?
I am making a script that will send data to my server, the script will be installed on a third-party resource.
sub.site.com/js
site.ru - installs my sub.site.com/js to itself
my script collects information and sends it to sub.site.com
inside sub.site.com/js data is collected and sent, how to implement sending?
Option 1. I stuff all the data into get parameters and access them to a 1x1 pixel image that is generated in php and saves all the information. sub.site.com/img.gif?params=bla
The problem is that this method blocks Adblock
Option 2. I send data from sub.site.com/js using XMLHttpRequest but then the error in the browser is No 'Access-Control-Allow- Origin' header is present on the requested resource.
Tell me how can I implement this? if there is https on sub.site.com, will the adblock lag behind it?
Tell me more how Yandex Metrica implements sending data, there is also a 1x1 image but its adblock does not block
Answer the question
In order to leave comments, you need to log in
if there is https on sub.site.com, will the adblock lag behind it?
You need to define a rule that works in adblock - press Ctrl + Shift + V. Among the list of elements there will be blocked, and a triggered rule. Exclude the possibility of triggering for the site element.
I guess he doesn't like the 1x1 picture.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question