Changeset 1475


Ignore:
Timestamp:
10/01/09 11:35:52 (10 years ago)
Author:
amuller
Message:

Ticket #672 - Correção do replace links para visualizar links

File:
1 edited

Legend:

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

    r1472 r1475  
    10421042                        return $body; 
    10431043 
    1044                 $pattern = '/[\s\r\n>;]+((http(s?):\/\/((?:[\w]\.?)+(?::[\d]+)?[:\/.\-~&=?%;@#,+\w]*))|((?:www?\.)(?:\w\.?)*(?::\d+)?[\:\/\w.\-~&=?%;@+]*))/i'; 
     1044 
     1045                $pattern = '/(?<=[\s\<\n\r;])((http(s?):\/\/((?:[\w]\.?)+(?::[\d]+)?[\/.\-~&=?%;@#,+\w]*))|((?:www?\.)(?:\w\.?)*(?::\d+)?[\/\w.\-~&=?%;@+]*))/i'; 
    10451046                $replacement = '<a href="http$3://$4$5" target="_blank">$1</a>'; 
    10461047                return preg_replace($pattern, $replacement, $body); 
Note: See TracChangeset for help on using the changeset viewer.