You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@httpd.apache.org by Ki Song <ki...@knifecenter.com> on 2006/08/10 21:24:22 UTC

[users@httpd] XML turned off

A quick question: Is there something special that needs to be turned on on a
web server to allow it to display XML documents?

The server we're on doesn't render any XML document.

The exact same file that I created works on one web server, but does not
work on a different server.

Ki


---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Re: [users@httpd] XML turned off

Posted by Ki Song <ki...@knifecenter.com>.
> On 8/10/06, Ki Song <ki...@knifecenter.com> wrote:
>>> On 8/10/06, Ki Song <ki...@knifecenter.com> wrote:
>>>> A quick question: Is there something special that needs to be turned on on
>>>> a
>>>> web server to allow it to display XML documents?
>>>> 
>>>> The server we're on doesn't render any XML document.
>>>> 
>>>> The exact same file that I created works on one web server, but does not
>>>> work on a different server.
>>> 
>>> Servers don't display documents, they simply send them to the browser.
>>> 
>>> Are you talking about the server transforming the document into html,
>>> or are you talking about the raw xml simply not being displayed in the
>>> browser?  If the latter, you should look at the content-type getting
>>> sent.  See the AddType directive.
>>> 
>>> Joshua.
>> 
>> The raw XML is not being displayed in the browser.
>> Check out these two links:
>> 
>> http://mail.knifecenter.com/lookupdetail.xml
>> http://www.knifecenter.com/lookupdetail.xml
>> 
>> They are the exact same file. Yet, the second one does not show up at all in
>> my browser.
> 
> Here is exactly what your server sends:
> HTTP/1.1 200 OK
> Date: Thu, 10 Aug 2006 19:56:55 GMT
> Server: Apache/2.0.46 (Red Hat)
> Content-type: text/html; charset=UTF-8
> Cache-control: no-store, no-cache, must-revalidate, max-age=0
> Cache-control: post-check=0, pre-check=0
> Pragma: no-cache
> Connection: Close
> MIME-Version: 1.0
> Expires: Thu, 10 Aug 2006 19:56:55 GMT
> Content-Length: 1
> 
> This tells me a few things:
> 1. You are using an ancient version of apache and should upgrade.
> 
I don't maintain that server, but I'll let the host know about this.

> 2. You have some very specific cache-control stuff being sent, which
> implies a non-standard configuration.  Is this file really being
> served directly from the filesystem, or is there some dynamic stuff
> involved?
> 
This particular file is being served directly. The code you see in the
source code is exactly what is written. There are no scripts on that page.
As far as the cache-control stuff, I'll ask my provider about that as well.

> 3. The Content-Length is 1, which means that apache believes the file
> contains only one byte.  Are you sure the file really contains what
> you think it does?
> 
Yes. They are exactly the same files.

> Is there anything interesting in the access and error logs?  Have you
> tried "EnableSendfile Off / EnableMMAP off"?
> 
I'll ask the provider to look at the logs.


Thanks for your replies. I'll keep everyone updated.


---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Re: [users@httpd] XML turned off

Posted by Joshua Slive <jo...@slive.ca>.
On 8/10/06, Ki Song <ki...@knifecenter.com> wrote:
> > On 8/10/06, Ki Song <ki...@knifecenter.com> wrote:
> >> A quick question: Is there something special that needs to be turned on on a
> >> web server to allow it to display XML documents?
> >>
> >> The server we're on doesn't render any XML document.
> >>
> >> The exact same file that I created works on one web server, but does not
> >> work on a different server.
> >
> > Servers don't display documents, they simply send them to the browser.
> >
> > Are you talking about the server transforming the document into html,
> > or are you talking about the raw xml simply not being displayed in the
> > browser?  If the latter, you should look at the content-type getting
> > sent.  See the AddType directive.
> >
> > Joshua.
>
> The raw XML is not being displayed in the browser.
> Check out these two links:
>
> http://mail.knifecenter.com/lookupdetail.xml
> http://www.knifecenter.com/lookupdetail.xml
>
> They are the exact same file. Yet, the second one does not show up at all in
> my browser.

Here is exactly what your server sends:
HTTP/1.1 200 OK
Date: Thu, 10 Aug 2006 19:56:55 GMT
Server: Apache/2.0.46 (Red Hat)
Content-type: text/html; charset=UTF-8
Cache-control: no-store, no-cache, must-revalidate, max-age=0
Cache-control: post-check=0, pre-check=0
Pragma: no-cache
Connection: Close
MIME-Version: 1.0
Expires: Thu, 10 Aug 2006 19:56:55 GMT
Content-Length: 1

This tells me a few things:
1. You are using an ancient version of apache and should upgrade.

2. You have some very specific cache-control stuff being sent, which
implies a non-standard configuration.  Is this file really being
served directly from the filesystem, or is there some dynamic stuff
involved?

3. The Content-Length is 1, which means that apache believes the file
contains only one byte.  Are you sure the file really contains what
you think it does?

Is there anything interesting in the access and error logs?  Have you
tried "EnableSendfile Off / EnableMMAP off"?

Other than that, you should look for any place in your config where
special processing is activated for xml files.

Joshua.

---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Re: [users@httpd] XML turned off

Posted by Nick Kew <ni...@webthing.com>.
On Thursday 10 August 2006 20:57, Ki Song wrote:

> http://mail.knifecenter.com/lookupdetail.xml

HTTP/1.1 200 OK
Date: Thu, 10 Aug 2006 19:27:04 GMT
Server: Apache/2.0.54 (Fedora)
Last-Modified: Thu, 10 Aug 2006 18:32:39 GMT
ETag: "101467e-e7-d713fc0"
Accept-Ranges: bytes
Content-Length: 231
Connection: close
Content-Type: text/xml

Looks reasonable.

> http://www.knifecenter.com/lookupdetail.xml

HTTP/1.1 200 OK
Date: Thu, 10 Aug 2006 19:57:02 GMT
Server: Apache/2.0.46 (Red Hat)
Content-type: text/html; charset=UTF-8

Joshua already told you to fix that.

Cache-control: no-store, no-cache, must-revalidate, max-age=0
Cache-control: post-check=0, pre-check=0
Pragma: no-cache

That lot's just stupid, but not the cause of this problem.

Connection: Close
MIME-Version: 1.0
Expires: Thu, 10 Aug 2006 19:57:02 GMT
Content-Length: 1

So you tell the browser to read 1 byte!

There's something very broken on that server, apart from
just its age.

-- 
Nick Kew

---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Re: [users@httpd] XML turned off

Posted by Ki Song <ki...@knifecenter.com>.
> On 8/10/06, Ki Song <ki...@knifecenter.com> wrote:
>> A quick question: Is there something special that needs to be turned on on a
>> web server to allow it to display XML documents?
>> 
>> The server we're on doesn't render any XML document.
>> 
>> The exact same file that I created works on one web server, but does not
>> work on a different server.
> 
> Servers don't display documents, they simply send them to the browser.
> 
> Are you talking about the server transforming the document into html,
> or are you talking about the raw xml simply not being displayed in the
> browser?  If the latter, you should look at the content-type getting
> sent.  See the AddType directive.
> 
> Joshua.

The raw XML is not being displayed in the browser.
Check out these two links:

http://mail.knifecenter.com/lookupdetail.xml
http://www.knifecenter.com/lookupdetail.xml

They are the exact same file. Yet, the second one does not show up at all in
my browser.


---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Re: [users@httpd] XML turned off

Posted by Joshua Slive <jo...@slive.ca>.
On 8/10/06, Ki Song <ki...@knifecenter.com> wrote:
> A quick question: Is there something special that needs to be turned on on a
> web server to allow it to display XML documents?
>
> The server we're on doesn't render any XML document.
>
> The exact same file that I created works on one web server, but does not
> work on a different server.

Servers don't display documents, they simply send them to the browser.

Are you talking about the server transforming the document into html,
or are you talking about the raw xml simply not being displayed in the
browser?  If the latter, you should look at the content-type getting
sent.  See the AddType directive.

Joshua.

---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org