content-type=text/html Problems with PHP

Source: Internet
Author: User
Tags header ini php book
Question the following text is due to the younger brother to see the recent forum on such a lot of questions and write, but also ask you to give more advice!!!

In the FAQ on this site has been how to remove some of the PHP4 of redundant information solution, but strictly speaking, this information is divided into two parts: part is to indicate that PHP is running the message, which is what x-powered-by and so on; and part of it is to declare the default content form of the file text /html. The answers to the FAQ address the previous part (as long as it's OK to raise on the related line), but the forum is more about the latter part of the question, and I want to discuss it.

The first thing to say is that this situation is likely to occur in the PHP CGI operation, then the younger brother guess most of the WIN32 platform error.

First of all, one of the most extreme solutions is to comment out all the extension modules, that is, the php.ini of the database, graphics, mail, etc. extension modules are not loaded, and some php.ini files are similar to the following forms:
; Windows Extensions
; Extension=php_mysql.dll
; Extension=php_nsmail.dll
; Extension=php_calendar.dll
; Extension=php_dbase.dll
; Extension=php_filepro.dll
; Extension=php_gd.dll
; Extension=php_dbm.dll
; Extension=php_mssql.dll
; Extension=php_zlib.dll
; Extension=php_filepro.dll
; Extension=php_imap4r2.dll
; Extension=php_ldap.dll
; Extension=php_crypt.dll
; Extension=php_msql2.dll
; Extension=php_odbc.dll
So what if you need these modules? Brother my solution only in the corresponding page dynamic loading, that is, DL () up--before the younger brother I also thought what the use of this function, now, haha ... If you have any good method, also can post out and share with you!

The next solution is to use the PHP-q parameter, according to PHP's own saying is "Suppress HTTP header output" that is, the HTTP header output is prohibited. This is it, but any header () and Setcookie () are useless--hey, your PHP is basically scrapped. So, that's just a 龌 鹾 way to do it.

Well, just say so much, should be able to solve the CGI way running PHP above the problem. The above information synthesizes the www.faqts.com about PHP--that place can be the top question site, often with php/zend writers and some PHP book authors to answer your questions, how wonderful!!!



Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.