As a result, the thumbnail is not displayed under IE6; later it was traced back to the following code: Copy the code as follows: header("Content-type: image/"/> As a result, the thumbnail is not displayed under IE6; later it was traced back to the following code: Copy the code as follows: header("Content-type: image/">

Home  >  Article  >  Backend Development  >  The reason why dynamic thumbnails are not displayed in iphone4s 6.0.1 perfect jailbreak ie6

The reason why dynamic thumbnails are not displayed in iphone4s 6.0.1 perfect jailbreak ie6

WBOY
WBOYOriginal
2016-07-29 08:40:071098browse

When I upload and generate a thumbnail, the link shown in the thumbnail is as follows;

Copy the code The code is as follows:


< img src ="/index.php?action=sys_upload_showThumb&id=bdc3955470adfb5637a0d1f517eb3d35" /& gt;


The result is that the thumbnail is not displayed under IE6; it was later traced back to the following piece of code:

Copy code The code is as follows:


header("Content-type: image/jpeg") ;
header(" Content-Length: ".strlen($_SESSION["fileInfo"][$image_id]));
echo $_SESSION["fileInfo"][$image_id];
unset($_SESSION['fileInfo'][$image_id] );//
exit(0);


So I wondered if it was unset before it was displayed? So the deletion was successful. Later it was changed to the following code:

Copy the code The code is as follows:


header("Content-type: image/jpeg") ;
header("Content-Length: ".strlen($_SESSION["fileInfo "][$image_id]));
echo $_SESSION["fileInfo"][$image_id];
/**Immediately output the above session to solve the problem that the thumbnails generated under IE6 have been cleared by the unset($_SESSION['']) below before they are displayed, resulting in IE6 being unable to display the thumbnails.*/
echo $str . str_repeat(' ', 256); //Some browsers It must be output only when the output reaches 256 characters
ob_flush();
flush(); // These two must be used together
unset($_SESSION['fileInfo'][$image_id]); //
exit(0);


In fact, this leads to the issue of server output control and browser caching. This is a bit complicated. I will study it again when I have the opportunity.

The above introduces the reasons why the dynamic thumbnails of ie6 do not display in the perfect jailbreak of iphone4s 6.0.1, including the content of the perfect jailbreak of iphone4s 6.0.1. I hope it will be helpful to friends who are interested in PHP tutorials.

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn