Subversion Repositories Applications.papyrus

Rev

Rev 182 | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 182 Rev 832
Line 51... Line 51...
51
        }
51
        }
Line 52... Line 52...
52
        
52
        
Line 53... Line 53...
53
        $output = '';
53
        $output = '';
-
 
54
        
54
        
55
        $contenu = file_get_contents($href);
-
 
56
        $tab_matches='';
55
        $contenu = file_get_contents($href);
57
        preg_match($this->conf['sites'][$site]['preg'], $contenu, $tab_matches);
56
        preg_match($this->conf['sites'][$site]['preg'], $contenu, $tab_matches);
58
        $tab_encodage='';
57
        preg_match('/<meta +http-equiv="Content-Type" +content="text\/html; *charset=(.+)"\/>/Ui', $contenu, $tab_encodage);
59
        preg_match('/<meta +http-equiv="Content-Type" +content="text\/html; *charset=(.+)"\/>/Ui', $contenu, $tab_encodage);
58
        if (preg_match('/^(?:iso-8859-1|iso-8859-15)$/i', $this->conf['encodage']) && preg_match('/utf-8/i', $tab_encodage[1])) {
60
        if (preg_match('/^(?:iso-8859-1|iso-8859-15)$/i', $this->conf['encodage']) && preg_match('/utf-8/i', $tab_encodage[1])) {
59
            $output = utf8_decode($tab_matches[1]);
61
            $output = utf8_decode($tab_matches[1]);