Changeset 2406


Ignore:
Timestamp:
04/01/10 16:51:20 (14 years ago)
Author:
rodsouza
Message:

Ticket #1025 - Removida a da instrução 'new_message_to' do método 'replace_links'

Location:
trunk/expressoMail1_2
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/expressoMail1_2/inc/class.imap_functions.inc.php

    r2399 r2406  
    12671267                // E-mail address in the text should create a new e-mail on ExpressoMail 
    12681268                $pattern = '/( |<|&lt;|>)([A-Za-z0-9\.~?\/_=#\-]*@[A-Za-z0-9\.~?\/_=#\-]*)( |>|&gt;|<)/im'; 
    1269                 $replacement = '$1<a href="javascript:new_message_to(\'$2\')">$2</a>$3'; 
    1270                 $body = preg_replace( $pattern, $replacement, $body ); 
    1271  
    1272                 // If there is an link with a "mailto:" in href attribute, it will changed to create a new e-mail on ExpressoMail. 
    1273                 $pattern = '/<a[^>]+href=["\']mailto:([^"]+)["\'][^>]*>([^<]+)<\/a>/im'; 
    1274                 $replacement = '<a href="javascript:new_message_to(\'$1\')">$2</a>'; 
     1269                $replacement = '$1<a href="mailto:$2">$2</a>$3'; 
    12751270                $body = preg_replace( $pattern, $replacement, $body ); 
    12761271 
  • trunk/expressoMail1_2/js/draw_api.js

    r2402 r2406  
    19191919        newBody = newBody.replace("<BODY","<span"); 
    19201920        div.innerHTML+= "<span id='body_"+ID+"' style='font-size:16px;'>"+newBody+"</span><br><br>"; 
     1921        function mailto( link ) 
     1922        { 
     1923                var mail = link.href.substr( 7 ); 
     1924                link.onclick = function( ) 
     1925                { 
     1926                        new_message_to( mail ); 
     1927                        return false; 
     1928                }; 
     1929        } 
     1930        var links = div.getElementsByTagName( 'a' ); 
     1931        for ( var i = 0; i < links.length; i++ ) 
     1932                if ( links.item( i ).href.indexOf( 'mailto:' ) === 0 ) 
     1933                        mailto( links.item( i ) ); 
    19211934        //////////////////////////////////////////////////////////////////////////////////////////////////////   
    19221935        //Make the thumbs of the message. 
Note: See TracChangeset for help on using the changeset viewer.