/ Published in: PHP
                    
                                        Split a string containing HTTP response into  a array with HTTP headers and a string with HTTP content
                
                            
                                Expand |
                                Embed | Plain Text
                            
                        
                        Copy this code and paste it in your HTML
 function parse_http_response ($string) { $content = ''; $h = null; while ($str !== false) { $h = false; continue; } $h = true; $headers[$headername] .= ',' . $headervalue; else $headers[$headername] = $headervalue; } if ($h === false) { $content .= $str."\n"; } } }
Comments
                    Subscribe to comments
                
                