Proyectos de Subversion LeadersLinked - Services

Rev

Rev 182 | Mostrar el archivo completo | | | Autoría | Ultima modificación | Ver Log |

Rev 182 Rev 606
Línea 37... Línea 37...
37
     * @param string $to_name
37
     * @param string $to_name
38
     * @return boolean
38
     * @return boolean
39
     */
39
     */
40
    public function processEmailTemplate($emailTemplate, $arrayCont, $to_address, $to_name)
40
    public function processEmailTemplate($emailTemplate, $arrayCont, $to_address, $to_name)
41
    {
41
    {
42
        
-
 
43
        $subject = trim(stripslashes($emailTemplate->subject));
42
        $subject = trim(stripslashes($emailTemplate->subject));
44
        $message = trim(stripslashes($emailTemplate->content));
43
        $message = trim(stripslashes($emailTemplate->content));
Línea 45... Línea -...
45
 
-
 
46
        
-
 
47
        
44
 
48
        foreach($arrayCont as $key => $val)
45
        foreach($arrayCont as $key => $val)
49
        {
-
 
50
            
46
        {
51
            if('link' == $key) {
-
 
52
                
-
 
53
                
47
            if('link' == $key) {
54
                $from_hostname = empty($_SERVER['HTTP_HOST']) ?  '' : $_SERVER['HTTP_HOST'];
48
                $from_hostname = empty($_SERVER['HTTP_HOST']) ?  '' : $_SERVER['HTTP_HOST'];
Línea 55... Línea 49...
55
                $from_hostname = str_replace('https://', '', $from_hostname);
49
                $from_hostname = str_replace('https://', '', $from_hostname);
Línea 71... Línea 65...
71
                
65
                
Línea 72... Línea -...
72
                
-
 
73
 
-
 
74
            }
66
                
75
            
67
 
76
            
68
            }
Línea 77... Línea 69...
77
            
69
            
Línea 91... Línea 83...
91
        $email->status = Email::STATUS_PENDING;
83
        $email->status = Email::STATUS_PENDING;
92
        $email->tried = 0;
84
        $email->tried = 0;
Línea 93... Línea 85...
93
        
85
        
94
        $emailMapper = EmailMapper::getInstance($this->adapter);
86
        $emailMapper = EmailMapper::getInstance($this->adapter);
95
        return $emailMapper->insert($email);
-
 
96
        
-
 
97
 
87
        return $emailMapper->insert($email);
98
    }
-
 
99
    
-
 
100
 
88
    }
101
}
89
}