How to change total counter

Everything about using Adblock Plus on Google Chrome
AdblockPlusUser
Posts: 5
Joined: Thu Feb 04, 2016 1:17 am

Re: How to change total counter

Post by AdblockPlusUser »

Yep, you're right. I tried again and figured out what I was doing wrong. Thanks!
dev_man
Posts: 2
Joined: Mon Apr 03, 2017 1:28 pm
Contact:

Re: How to change total counter

Post by dev_man »

Yes, now it works fine. thank you for the nice topic
kabebi
Posts: 1
Joined: Fri Jul 07, 2017 2:07 am
Location: tbilisi
Contact:

Re: How to change total counter

Post by kabebi »

thanks for information :wink:
User avatar
greiner
ABP Developer
Posts: 899
Joined: Mon Sep 03, 2012 5:29 pm
Location: Cologne, Germany

Re: How to change total counter

Post by greiner »

Recently, we've made quite significant changes to the Adblock Plus code due to the upcoming release of our Web Extension version for Firefox. That means that the code you need to run to retrieve or update the counter has changed.

Retrieve the counter:

Code: Select all

browser.storage.local.get("pref:blocked_total").then(console.log)
Update the counter:

Code: Select all

browser.storage.local.set({"pref:blocked_total": ###})
nudosu
Posts: 1
Joined: Sat Mar 17, 2018 10:52 pm
Contact:

Re: How to change total counter

Post by nudosu »

Thanks for your help.
mouniaZad
Posts: 1
Joined: Tue Jul 17, 2018 8:23 pm

Re: How to change total counter

Post by mouniaZad »

Where can I change the font size of the coming soon counter? The letters and digits are just too large on a mobile phone.
User avatar
greiner
ABP Developer
Posts: 899
Joined: Mon Sep 03, 2012 5:29 pm
Location: Cologne, Germany

Re: How to change total counter

Post by greiner »

mouniaZad wrote:Where can I change the font size of the coming soon counter? The letters and digits are just too large on a mobile phone.
What counter are you referring to?
imjamespeter
Posts: 1
Joined: Tue Aug 21, 2018 7:29 am
Contact:

Re: How to change total counter

Post by imjamespeter »

However, if you remember the total number (or can approximate it) and it's really important to you to know how many ads AdBlock has ever blocked for you, you can set AdBlock's counter to start at that number instead of 0 after a reinstall. Here's how.

In Chrome:
Open the Chrome Extensions page (Chrome menu > More Tools > Extensions or open a new tab and enter chrome://extensions).
Enable Developer Mode in the upper right corner of the page.
Find AdBlock in the list of extensions.
To the right of "Inspect views," click background page. The Chrome Developer Tools window opens.
Select the Console tab.
Enter the following command, where "x" is a valid integer: Prefs.blocked_total = x

Thank you.!
Regards,
James Mobdro
bichngoc94
Posts: 1
Joined: Fri Sep 14, 2018 10:41 am
Contact:

Re: How to change total counter

Post by bichngoc94 »

Has any one come across this before and if so how did they reset the total counter reading back to 0.00 without following the suggestion by SAP?
nasar
Posts: 8
Joined: Mon Mar 30, 2020 11:47 am

Re: How to change total counter

Post by nasar »

greiner wrote:That data is not stored within a file but you can still store it using this method:

1. Go to the Adblock Plus options page
2. Press CTRL+SHIFT+J to open the JavaScript console
3. Enter

Code: Select all

copy(localStorage.stats_total)
and press "Enter"
4. Paste the copied data into a text file and save it

To restore it follow these steps:

1. Copy the data from the text file where you saved it previously
2. Go to the Adblock Plus options page
3. Press CTRL+SHIFT+J to open the JavaScript console
4. Enter

Code: Select all

localStorage.stats_total = JSON.stringify(###)
(replace "###" with the data from the text file) and press "Enter"
5. Restart Chrome
Thanks bro
ramjay
Posts: 1
Joined: Sun Jul 26, 2020 6:12 am
Contact:

Re: How to change total counter

Post by ramjay »

This thread helps me a lot to change counter
yegane@27
Posts: 1
Joined: Sun Oct 04, 2020 12:24 pm
Contact:

Re: How to change total counter

Post by yegane@27 »

THANKS
hellogetsafe
Posts: 1
Joined: Wed Sep 23, 2020 7:38 am
Location: Germany
Contact:

Re: How to change total counter

Post by hellogetsafe »

This is an important discussion. Thanku so much.
pythonjake
Posts: 7
Joined: Mon Dec 14, 2020 9:49 am

Re: How to change total counter

Post by pythonjake »

Thanks, this helped a lot.
shubharora734
Posts: 1
Joined: Thu Dec 10, 2020 6:03 pm

Re: How to change total counter

Post by shubharora734 »

I like being able to reset the stats counter from time to time for a variety of reasons, but after the latest update, none of the methods described in this thread work anymore. Is there any way to do so with this latest version?
Post Reply