[dev] problem with latest "accept: */*" code

Eric Rostetter eric.rostetter at physics.utexas.edu
Thu Oct 17 22:25:47 PDT 2002


I sent this in the morning, but to the wrong address so it bounced....
Just now got to the end of my mail to find the bounce...  (busy day)
So let's try again.

---

Some browsers, which are kind of broken IMHO, give the accept string of

Accept: */*

saying they accept everything with equal preference.  This is, IMHO, a
broken browser.  But since this broken browser class includes MSIE on
Mac, it is a rather important class of broken browsers...

So recently, code was added to horde/lib/Browser.php to "handle" this
type of accept string.  This code says, for any test, return true if 
the accept line is "*/*".

In the same file, we have a test for wap support, which reads:

if (!empty($this->_accept)) {
            if ($this->_acceptMIMEType('text/vnd.wap.wml')) {
                $this->setFeature('wml');
            }

This will always return true, matching */*, even though the browser 
doesn't really "support" wap.

Now in horde/index.html, it checks for wml before html.  Thus these people
are assumed to want wml instead of html, and that is what they get.

So what I'm seeing is MSIE/Mac users hitting my CVS HEAD site, and getting
WML returned instead of HTML.  The problem with this is that while the 
MSIE/Mac is saying it can accept */* with equal preference, when it gets
the wml, it doesn't have a clue what to do with it.

This is with MSIE 5.2.2 on OS 10.2.1, but I'd bet it happens with other
versions/combinations.

-- 
Eric Rostetter
The Department of Physics
The University of Texas at Austin

Why get even? Get odd!


More information about the dev mailing list