Re: Apache 2.0
On Wed, Jul 30, 2003 at 09:30:12PM +0300, Oded Arbel wrote: On Wednesday 30 July 2003 19:00, Sagi Bashari wrote: 1) Hebrew pages are sent as western encoding... the text is right but for some reason the browser sets itself to western instead of Hebrew. if I set it to Hebrew its fine (until I refresh or click a link). Just comment the default encoding in httpd.conf to make it use the meta tag in your files. HTML headers have higher priority than meta tags. This is not correct - HTML meta tags override HTTP headers, as they are a higher level of abstraction and convey a knowledge the lower level cannot have, of the content of the transmission. You are right in your rationale. It is the standard that is broken: http://www.w3.org/TR/html401/charset.html#h-5.2.2 1. An HTTP charset parameter in a Content-Type field. 2. A META declaration with http-equiv set to Content-Type and a value set for charset. 3. The charset attribute set on an element that designates an external resource. I know there are some broken browsers (no names) which for some weird combination of settings disregard HTML meta tags in favor of headers, but this is hardly the norm, nor the standard. Mozilla? -- Tzafrir Cohen +---+ http://www.technion.ac.il/~tzafrir/ |vim is a mutt's best friend| mailto:[EMAIL PROTECTED] +---+ = To unsubscribe, send mail to [EMAIL PROTECTED] with the word unsubscribe in the message body, e.g., run the command echo unsubscribe | mail [EMAIL PROTECTED]
Apache 2.0
Hi all! I have two major problems after installing RH9 over my RH7.3, The new apache had many problems with the configuration, Most of which I solved using the apache-online documentation. I am left with two problems unsolved: 1) Hebrew pages are sent as western encoding... the text is right but for some reason the browser sets itself to western instead of Hebrew. if I set it to Hebrew its fine (until I refresh or click a link). I can think of two options to solve this: a) bad solution: embed a encoding tag in every HTML file (did not work, I might had a mistake in the tag) b) fix the apache configuration (I have no idea what parameters are causing this) 2) the 2nd problem is that my PHP script does not recognize parameters, like test.php?active=truebad=good the parameters $active $bad are both empty (WHY?!? OH WHY??) Thanks, As you can probably see - I am very frustrated. Tal Achituv. __ Tal Achituv Integration Assistant tel. +972-9-961-1500 ext. 277 fax. +972-9-961-1511 mbl. +972-55-956-369 SCHEMA Optimizing the Wireless World w w w . s c h e m a . c o m = To unsubscribe, send mail to [EMAIL PROTECTED] with the word unsubscribe in the message body, e.g., run the command echo unsubscribe | mail [EMAIL PROTECTED]
Re: Apache 2.0
On Wed, Jul 30, 2003 at 06:28:00PM +0300, Tal Achituv wrote: Hi all! I have two major problems after installing RH9 over my RH7.3, b) fix the apache configuration (I have no idea what parameters are causing this) I dont think there's an apache directive that can take care of this. Would be nice to know that I'm wrong 2) the 2nd problem is that my PHP script does not recognize parameters, like test.php?active=truebad=good the parameters $active $bad are both empty (WHY?!? OH WHY??) Check your php.ini and set register_globals to On. -- http://www.uadm.com | Local and Remote Unix/Linux [EMAIL PROTECTED] | Administration. No outsourcing. Phone: +972 3 6201373 | Security, Installations, Support http://www.uadm.com/gpg.key | Upgrades and Maintenance. = To unsubscribe, send mail to [EMAIL PROTECTED] with the word unsubscribe in the message body, e.g., run the command echo unsubscribe | mail [EMAIL PROTECTED]
Re: Apache 2.0
On Wednesday 30 July 2003 18:28, Tal Achituv wrote: 1) Hebrew pages are sent as western encoding... the text is right but for some reason the browser sets itself to western instead of Hebrew. if I set it to Hebrew its fine (until I refresh or click a link). You can explicitly set the default encoding that Apache uses to send page by adding this line: AddDefaultCharset ISO-8859-8-i (or any other character set you wish to use by default) 2) the 2nd problem is that my PHP script does not recognize parameters, like test.php?active=truebad=good the parameters $active $bad are both empty (WHY?!? OH WHY??) Please note that as of PHP 4.2.0, the setting for register_globals is set to off by default, which will cause GET parameters not to be registered as global variables. you can either set reigster_globals to on explicitly in /etc/php.ini, or use the global $HTTP_GET_VARS, $_GET or $_REQUEST arrays. I personally prefer the last as it allows the script to also accept the same variables from POST or from the session, or the second if you only wish to get the variables from the query string. using register_globals to access external data is frowned upon as it is considered a security risk. -- Oded ::.. Hanlon's Razor - Never attribute to malice that which can be adequately explained by stupidity. = To unsubscribe, send mail to [EMAIL PROTECTED] with the word unsubscribe in the message body, e.g., run the command echo unsubscribe | mail [EMAIL PROTECTED]
Re: Apache 2.0
On , 30 2003, 18:28, Tal Achituv wrote: Hi all! 2) the 2nd problem is that my PHP script does not recognize parameters, like test.php?active=truebad=good the parameters $active $bad are both empty (WHY?!? OH WHY??) It's not apache's fault. Starting from version 4.3(or was it 4.2?), PHP does no longer register GPC(Get/Post/Cookies) in the global namespace by default, unless explictly instructed It is considered a bad practice for quite a time, both from code maintaince and security prospectives. I think you should refer to the PHP manual to read more about this issue. Idan. = To unsubscribe, send mail to [EMAIL PROTECTED] with the word unsubscribe in the message body, e.g., run the command echo unsubscribe | mail [EMAIL PROTECTED]
Re: Apache 2.0
On 30/07/2003 18:28, Tal Achituv wrote: Hi all! I have two major problems after installing RH9 over my RH7.3, The new apache had many problems with the configuration, Most of which I solved using the apache-online documentation. I am left with two problems unsolved: 1) Hebrew pages are sent as western encoding... the text is right but for some reason the browser sets itself to western instead of Hebrew. if I set it to Hebrew its fine (until I refresh or click a link). I can think of two options to solve this: a) bad solution: embed a encoding tag in every HTML file (did not work, I might had a mistake in the tag) b) fix the apache configuration (I have no idea what parameters are causing this) Just comment the default encoding in httpd.conf to make it use the meta tag in your files. HTML headers have higher priority than meta tags. 2) the 2nd problem is that my PHP script does not recognize parameters, like test.php?active=truebad=good the parameters $active $bad are both empty (WHY?!? OH WHY??) Thats because register_globals is turned off by default since php4.1 or so. If you can, you should use the super globals $_GET, $_POST, etc instead. Or you can enable it in php.ini. Thanks, As you can probably see - I am very frustrated. Tal Achituv. = To unsubscribe, send mail to [EMAIL PROTECTED] with the word unsubscribe in the message body, e.g., run the command echo unsubscribe | mail [EMAIL PROTECTED]
Re: Apache 2.0
On Wednesday, Jul 30, 2003, at 19:00 Asia/Jerusalem, Sagi Bashari wrote: If you can, you should use the super globals $_GET, $_POST, etc instead. Or you can enable it in php.ini. Or in the apache configuration file, which is good if you want to override for only specific virtual domains - I do this, as I use the venerable PHPLib, and it relies on globals. Herouth = To unsubscribe, send mail to [EMAIL PROTECTED] with the word unsubscribe in the message body, e.g., run the command echo unsubscribe | mail [EMAIL PROTECTED]
Re: Apache 2.0
On Wednesday 30 July 2003 19:00, Sagi Bashari wrote: 1) Hebrew pages are sent as western encoding... the text is right but for some reason the browser sets itself to western instead of Hebrew. if I set it to Hebrew its fine (until I refresh or click a link). Just comment the default encoding in httpd.conf to make it use the meta tag in your files. HTML headers have higher priority than meta tags. This is not correct - HTML meta tags override HTTP headers, as they are a higher level of abstraction and convey a knowledge the lower level cannot have, of the content of the transmission. I know there are some broken browsers (no names) which for some weird combination of settings disregard HTML meta tags in favor of headers, but this is hardly the norm, nor the standard. -- Oded = To unsubscribe, send mail to [EMAIL PROTECTED] with the word unsubscribe in the message body, e.g., run the command echo unsubscribe | mail [EMAIL PROTECTED]
Re: Apache 2.0
On 30/07/2003 21:30, Oded Arbel wrote: Just comment the default encoding in httpd.conf to make it use the meta tag in your files. HTML headers have higher priority than meta tags. This is not correct - HTML meta tags override HTTP headers, as they are a higher level of abstraction and convey a knowledge the lower level cannot have, of the content of the transmission. I know there are some broken browsers (no names) which for some weird combination of settings disregard HTML meta tags in favor of headers, but this is hardly the norm, nor the standard. From the apache manual (http://httpd.apache.org/docs-2.0/mod/core.html#adddefaultcharset): This directive specifies the name of the character set that will be added to any response that does not have any parameter on the content type in the HTTP headers. This will override any character set specified in the body of the document via a |META| tag. A setting of |AddDefaultCharset Off| disables this functionality. |AddDefaultCharset On| enables Apache's internal default charset of |iso-8859-1| as required by the directive. You can also specify an alternate charset to be used. For example: | AddDefaultCharset utf-8 | |It seems wrong to me too, but thats what they say. | |Sagi | = To unsubscribe, send mail to [EMAIL PROTECTED] with the word unsubscribe in the message body, e.g., run the command echo unsubscribe | mail [EMAIL PROTECTED]