Changeset 5cc4b13 in github for program/lib/html2text.inc


Ignore:
Timestamp:
Mar 19, 2007 6:36:24 PM (6 years ago)
Author:
thomascube <thomas@…>
Branches:
master, HEAD, courier-fix, dev-browser-capabilities, pdo, release-0.6, release-0.7, release-0.8
Children:
b3f1ecb
Parents:
86958f7
Message:

Correctly parse message/rfc822; fixed html2text conversion; code cleanup

File:
1 edited

Legend:

Unmodified
Added
Removed
  • program/lib/html2text.inc

    rdd792e8 r5cc4b13  
    113113        '/<script[^>]*>.*?<\/script>/i',         // <script>s -- which strip_tags supposedly has problems with 
    114114        //'/<!-- .* -->/',                         // Comments -- which strip_tags might have problem a with 
    115         '/<a href="([^"]+)"[^>]*>(.+?)<\/a>/ie', // <a href=""> 
     115        '/<a [^>]*href="([^"]+)"[^>]*>(.+?)<\/a>/ie', // <a href=""> 
    116116        '/<h[123][^>]*>(.+?)<\/h[123]>/ie',      // H1 - H3 
    117117        '/<h[456][^>]*>(.+?)<\/h[456]>/ie',      // H4 - H6 
     
    161161        ' ',                                    // Newlines and tabs 
    162162        '',                                     // <script>s -- which strip_tags supposedly has problems with 
    163         //'',                                     // Comments -- which strip_tags might have problem a with 
     163        //'',                                  // Comments -- which strip_tags might have problem a with 
    164164        '$this->_build_link_list("\\1", "\\2")', // <a href=""> 
    165165        "strtoupper(\"\n\n\\1\n\n\")",          // H1 - H3 
    166         "ucwords(\"\n\n\\1\n\n\")",             // H4 - H6 
    167         "\n",                                   // <P> 
     166        "ucwords(\"\n\n\\1\n\")",               // H4 - H6 
     167        "\n\n",                                 // <P> 
    168168        "\n",                                   // <br> 
    169169        'strtoupper("\\1")',                    // <b> 
     
    256256     *  @return void 
    257257     */ 
    258     function html2text( $source = '', $from_file = false, $do_link_table = true ) 
     258    function html2text( $source = '', $from_file = false, $produce_link_table = true ) 
    259259    { 
    260260        if ( !empty($source) ) { 
Note: See TracChangeset for help on using the changeset viewer.