helly           Sat Mar 29 16:25:03 2003 EDT

  Modified files:              
    /php4/main  php_ini.c 
  Log:
  fix phpinfo() & php -i
  
Index: php4/main/php_ini.c
diff -u php4/main/php_ini.c:1.119 php4/main/php_ini.c:1.120
--- php4/main/php_ini.c:1.119   Sat Mar 22 13:54:35 2003
+++ php4/main/php_ini.c Sat Mar 29 16:25:03 2003
@@ -16,7 +16,7 @@
    +----------------------------------------------------------------------+
  */
 
-/* $Id: php_ini.c,v 1.119 2003/03/22 18:54:35 shane Exp $ */
+/* $Id: php_ini.c,v 1.120 2003/03/29 21:25:03 helly Exp $ */
 
 /* Check CWD for php.ini */
 #define INI_CHECK_CWD
@@ -67,9 +67,9 @@
                        if (ini_entry->orig_value && ini_entry->orig_value[0]) {
                                display_string = ini_entry->orig_value;
                                display_string_length = ini_entry->orig_value_length;
-                               esc_html = 1;
+                               esc_html = !sapi_module.phpinfo_as_text;
                        } else {
-                               if (PG(html_errors)) {
+                               if (!sapi_module.phpinfo_as_text) {
                                        display_string = "<i>no value</i>";
                                        display_string_length = sizeof("<i>no 
value</i>") - 1;
                                } else {
@@ -80,9 +80,9 @@
                } else if (ini_entry->value && ini_entry->value[0]) {
                        display_string = ini_entry->value;
                        display_string_length = ini_entry->value_length;
-                       esc_html=1;
+                       esc_html = !sapi_module.phpinfo_as_text;
                } else {
-                       if (PG(html_errors)) {
+                       if (!sapi_module.phpinfo_as_text) {
                                display_string = "<i>no value</i>";
                                display_string_length = sizeof("<i>no value</i>") - 1;
                        } else {
@@ -107,7 +107,7 @@
        if (ini_entry->module_number != module_number) {
                return 0;
        }
-       if (PG(html_errors)) {
+       if (!sapi_module.phpinfo_as_text) {
                PUTS("<tr>");
                PUTS("<td class=\"e\">");
                PHPWRITE(ini_entry->name, ini_entry->name_length - 1);



-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to