GMail and Konqueror

As some bugs.kde.org votes might have noticed I've fixed GMail (standard view) again in Konqueror. Although it is an odd sort of fix, because I really just improved our Mozilla emulation so we change one more bit from our usual KHTML/MSIE behavior to that of Mozilla when spoofing as a Mozilla based browser. This means that GMail only works when you use UserAgent spoofing and set it to Firefox.

So why doesn't it work when you spoof as Safari or use "?nocheckbrowser"?.

Well to be honest, while GMail is a very nice application; from a Standards and a Web-Developer point of view it stinks. I've seen worse javascript on the web, but not of this magnitude. Not only is it auto-obfuscated in order to make it as hard as possible to figure out what it does, it implements two different paths. One that use proprietary MSIE extensions and one that use specific Mozilla extensions, the last has been superficially hacked to work on Safari.

There is a single specific line of code for Konqueror that detects it and then treats it as Safari. In the bug I fixed above Mozilla has implemented the DOM2 standard for MouseEvent::button() while we have implemented the MSIE non-standard. Unfortunately GMail now depends on us using the MSIE behaviour when they detect us and thus we cannot change to the standard without creating even more bugs in GMail (do you see the problem?).

But on the other hand there is a specific Safari work-around later that doesn't work in Konqueror because we have fixed a bug, while the Firefox version of the same code works fine, meaning we can get a working but slightly misrendered version of GMail by pretending to be Firefox (and often just misrendered because they send us invalid css with -moz- extensions).

All in all I am proud of having gotten this far, but in the end there is no way from our side keep GMail working in Konqueror. It is only a job that GMail can do, because they don't really care about safe implementations or standard behavior, and they don't care about making debuggable code.


Stop making the effort of reading such obviously and blatantly obfuscated code. You've done quite a lot of work, and the community surely thanks you many times over for it. However, if they keep breaking it, then it'll never end.

Instead, everyone who has a GMail account and wants to use Konqueror, mail Google now and make them write Konqueror support.

By Thiago Macieira at Fri, 06/24/2005 - 23:03

i seached for quite a while but i can find a good email adress to write, complain to... I only find this shitty form:

Maybe is we can find a small list of GMail develep emails from the Mozilla/Safari mailing/commit lists and post it here we can make more impact.

Cies Breijs.

By cies at Sat, 06/25/2005 - 05:39

This url is working not perfect :: http://mail.google.com/mail/h

By hekenberg at Thu, 01/31/2008 - 08:08

Instead, everyone who has a GMail account and wants to use Konqueror, mail Google now and make them write Konqueror support.

I agree that this is the most sensible solution. However, is gmail support for Konqueror already happening? I have noticed recently that I no longer get the "Your browser is not supported" message when I try to log in. Also, the UI is a little bit different than when I use Firefox. It's a bit less dynamic (for example, the "reply" section when viewing a message is done quite differenty).

So, it seems to me that google is now providing a version of gmail that works on konqueror. Maybe it's a slightly crippled version, but it does seem to work (I do not have these latest konqueror patches yet).

Or maybe I missed something...

KStars: A desktop planetarium for KDE

By Jason Harris at Sat, 06/25/2005 - 15:40

Are you sure you don't have the UA Changer on?

By Thiago Macieira at Sun, 06/26/2005 - 16:49

what about using gmail with konqueror in basic view? at least this will make google aware that there are a bunch of guys who use konqueror.

it's not a great suggestion, but my worry is that, by using the UA firefox spoofing, we become invisible as a user base.

or what about starting a "positive petition". one whereby we put our names on a list garnering support and encouraging the guys at google to add support for konqueror. they're great guys with lots to do and i think they, like us just focus on the biggest need.

that said, something has to be done and sadly, it'll probably have to be from our side ie improving support for some of the non-standards-compliant stuff (meeting this problem half-way). i absolutely love konqueror and am tired of "resorting" to firefox to get stuff done, but we are never going to get all the incorrectly-coded sites out there to comply.

feels like a mohamed meets mountain moment :)

By justinlawrence at Mon, 06/02/2008 - 10:18

Hi there,
I found this URL that remove the browser validation :

You can see with your eyes that really doesn't work at all in Konqueror ;(

By le_mulot at Sat, 01/07/2006 - 08:35

I can't figure out what's happened to stop me from accessing my gmail account using konqueror. I've been doing so for at least a year without any real trouble.

Recently, however, I upgraded from kde 3.5.1 to 3.5.2. Since then, I've been unable to use konqueror to access gmail. I had a bookmark set, which now takes me to the gmail sign in page. My user name and password still load automatically. But if I click sign in, the sign in page just reloads.

I've gone into Konqueror settings to set the identification to Firefox 1.0. No change.

Any suggestions.

By jay at Thu, 04/13/2006 - 05:56