Google Tag Manager |
Post Reply |
Author | |
loisjacobs@hotmail.c
Newbie Joined: Aug 25 2017 Location: Texas Status: Offline Points: 2 |
Post Options
Thanks(0)
Posted: Aug 25 2017 at 3:54am |
We implemented Google Analytics, but doesn't allow for us to track if a PDF is downloaded.
I think Google Tag Manager will allow us to track PDF downloads, but we can't figure out how to make Google Tag Manager work in Open Element. Has anybody been able to make google tag manager work in Open Element? If not, does anybody have any other way to track PDF downloads? Thanks! |
|
Dmit OE
Admin Group Joined: May 31 2012 Status: Offline Points: 5283 |
Post Options
Thanks(0)
|
Hi,
"Any other way" (rough): create with Notepad a PHP script ex. "download.php": <?php $counterFile = 'pdf_download_count.txt'; $count = file_exists($counterFile) ? file_get_contents($counterFile) : 0; file_put_contents($counterFile, $count+1); header("Location: Files/Other/my_pdf.pdf") The script increments the counter inside the text file and redirects to the PDF document. On your page, make the link to this script rather than to the PDF file. |
|
Nielsbsmns
Newbie Joined: Sep 17 2020 Status: Offline Points: 1 |
Post Options
Thanks(0)
|
I managed to install Google Tag Manager with the HTML blocks but stumbled upon a stupid wall. Can't I just add the same pieces of code on the whole website with one click of the button or do I really have to add the HTML blocks to every single page apart? Please help me out.
|
|
digizar
Senior Member Joined: Dec 30 2015 Location: Germany Frankfu Status: Offline Points: 739 |
Post Options
Thanks(0)
|
Put it in a Layer. And use that Layer in those page(s).
|
|
___________________________________
Ask questions only if there is no answer yet. https://blumendigi.com |
|
Hobby001
Admin Group Joined: Jun 05 2018 Location: Canada, Québec Status: Offline Points: 6195 |
Post Options
Thanks(0)
|
You can also cascade layors
|
|
Post Reply | |
Tweet
|
Forum Jump | Forum Permissions You cannot post new topics in this forum You cannot reply to topics in this forum You cannot delete your posts in this forum You cannot edit your posts in this forum You cannot create polls in this forum You cannot vote in polls in this forum |