Discussions » Creation Requests
Change firefox user agent on whatsapp web
Greasemonkey API documentation doesn't mention @user-agent
tag.
As far as I know, the only solution is to use an addon, for example, UAControl.
The code you found should work on Chrome with Tampermonkey.
For Firefox try using this:
// ==UserScript==
// @name Change User-Agent for WhatsappWeb
// @version 1
// @match https://web.whatsapp.com/*
// ==/UserScript==
Object.defineProperty(navigator, 'userAgent', {
value: 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_10_2) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/41.0.2272.35 Safari/537.36'
});
It doesn't work for me. Matching this with http://whatsmyuseragent.org/ doesn't change the result on that site.
I don't think you need a user-script for this. You should be able to change your user agent on websites by going to about:config and making an entry like "general.useragent.override.google.com" to use google as an example, with a string value of the user agent you want. Or just "general.useragent.override" if you want to change it universally.
Change firefox user agent on whatsapp web
i tried to change firefox user agent on whatsapp web:
// ==UserScript==
// @name Change User-Agent for WhatsappWeb
// @version 1
// @match https://web.whatsapp.com/
// @user-agent Mozilla/5.0 (Macintosh; Intel Mac OS X 10_10_2) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/41.0.2272.35 Safari/537.36
// ==/UserScript==
but it didnt work any ideas??