How to add a Download Timer Script on a Blogger Website in 2022 | Satya Ki Pathshala
How to add a Download Timer Script on a Blogger Website in 2022: Today in this article I am going to provide you the source code and you can apply thi
How to add a Download Timer Script on a Blogger Website in 2022: Today in
this article I am going to provide you the source code and you can apply this
Download Timer Script on a Blogger Website Source Code to add a timer to
your blogger website before any downloading.
The Timer Script in any Website, whether it's Blogger or WordPress, plays an
important role in increasing visitors' spending time on a particular page.
This indicates to Google, that a particular page has good and valuable content
that's why the visitor is spending more time on that page.
This is the reason people use Timer Script on their websites.
What is Timer Script in Blogger
Timer Script is the script that is used to hold the visitors on a particular
page. In this script, JavaScript is used to decide the timer. Suppose any
visitor wants to download something from that particular page. So if he or she
gets the file there, then that person will download it and move away from that
page.
This action increases the Bounce Rate on the Website. So, to decrease the
bounce rate of any website, people use a timer script. After the timer ends,
then only the person can get the file. Unless the timer ends ticking, he or
she has to wait for that particular file.
I hope you got the idea of Timer Script on Blogger.
You may also like:
How to apply Download Timer Script on a Blogger Website
To apply the Timer Script on Blogger simply follow the steps that I have
mentioned below.
STEP 1: Go to Blogger Dashboard.
STEP 2: Click on Theme.
STEP 3: Now, click on "Edit HTML".
STEP 4: Now, find ]]></b:skin> tag by typing Ctrl+F.
STEP 5: Now copy the below CSS code and paste it above
]]></b:skin> tag.
.skbutton-1 {background: #0b807e;border: none;color: white;font-family: system-ui;font-size: 17px;text-decoration: none;padding: 10px 20px;cursor: pointer;border-radius: 19px;}.skbutton-2{background: #0b807e;border: none;color: white;font-family: system-ui;font-size: 17px;text-decoration: none;padding: 10px 20px;cursor: pointer;border-radius: 19px;}(code-box)
STEP 6: Now copy the below JavaScript and paste it above </body> tag.
<script type='text/javascript'>//<![CDATA[var downloadButton = document.getElementById("download");var counter = 5;var newElement = document.createElement("p");newElement.innerHTML = "";var id;downloadButton.parentNode.replaceChild(newElement, downloadButton);function startDownload() {this.style.display = 'none';id = setInterval(function () {counter--;if (counter < 0) {newElement.parentNode.replaceChild(downloadButton, newElement);clearInterval(id);} else {newElement.innerHTML = +counter.toString() + " second.";}}, 1000);};var clickbtn = document.getElementById("btn");clickbtn.onclick = startDownload;//]]></script>(code-box)
NOTE: You can change the timer by changing the "var counter" in this JavaScript Code.(alert-success)
STEP 7: Now save the Blogger Theme.
STEP 8: Now use the below HTML code in your Blogger Post where you want to add a timer. Don't forget to change the URL of your destination link page.
<div><br /></div><div style="text-align: center;"><a class="skbutton-1" href="#" id="download" target="_blank"> Download File </a><button class="skbutton-2" id="btn"> Click Here </button></div>(code-box)
Now you have successfully completed adding a Download Timer Script on a Blogger Website in 2022. Don't miss out on any steps otherwise, you might face a great loss in your blogger website.
NOTE: Before applying all the above steps, please keep a backup of your theme data.(alert-success)
Final Words
So, guys, this is it for now. If you like this article then don't forget to share it with others. Because sharing is caring. It takes time and energy to make content and serve you. So, please do support this blog and my YouTube Channel to grow. When you share my content on social media, it inspires me to do something even better.
So keep sharing. See you in the next post. Till then, take care.
Join the conversation