Web Hosting Talk







View Full Version : Apache2 + Php Problems


wmac
11-17-2002, 05:58 AM
Hello

If you have tried RedHat 8.0 then you know that Apache 2 is default. I have some problems with the combination and I want to see if anyone has solved them.

Pages designed with other charsets are ok with Apache 1.3 and IIS but when I try them on Apache 2.0 (viewed with IE 6.0) they do not come up with correct charset and I need to determine encoding for each new page while it is determined on meta tags. (Right click on page -> Encoding -> Select Encoding)

As I told I am sure it is fromApache as same pages come up correctly on IIS and Apache 1.3.

Have anyone seen this problems? How can I fix these :) ?

I have tried changing below option:

#
# Specify a default charset for all pages sent out. This is
# always a good idea and opens the door for future internationalisation
# of your web site, should you ever want it. Specifying it as
# a default does little harm; as the standard dictates that a page
# is in iso-8859-1 (latin1) unless specified otherwise i.e. you
# are merely stating the obvious. There are also some security
# reasons in browsers, related to javascript and URL parsing
# which encourage you to always set a default char set.
#
AddDefaultCharset ISO-8859-1

I disabled this option but it did not work.


Thank you,
Mac

MarkIL
11-17-2002, 08:43 AM
Make sure you write correct [X]HTML code that specifies the charset in either a meta tag or in the XML header. Try this:


<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
<head><title>Sample XHTML 1.1 document</title></head>
<body>
<p>Some random text.</p>
</body>
</html>

wmac
11-17-2002, 09:28 AM
Thank you.

You mean I can no more use:

<meta http-equiv="Content-Language" content="en">
<meta http-equiv="Content-Type" content="text/html; charset=windows-1252">

Or something like that?

Mac