Pues son varios archivos, los encuentras en el directorio:
/components/com_contact
Creo que es en este archivo:
contact.php Código PHP:
function sendmail( $con_id, $option ) {
global $mainframe, $database, $Itemid;
global $mosConfig_sitename, $mosConfig_live_site, $mosConfig_mailfrom, $mosConfig_fromname, $mosConfig_db;
// simple spoof check security
josSpoofCheck(1);
$query = "SELECT *"
. "\n FROM #__contact_details"
. "\n WHERE id = " . (int) $con_id
;
$database->setQuery( $query );
$contact = $database->loadObjectList();
if (count( $contact ) > 0) {
$default = $mosConfig_sitename.' '. _ENQUIRY;
$email = strval( mosGetParam( $_POST, 'email', '' ) );
$text = strval( mosGetParam( $_POST, 'text', '' ) );
$name = strval( mosGetParam( $_POST, 'name', '' ) );
$subject = strval( mosGetParam( $_POST, 'subject', $default ) );
$email_copy = strval( mosGetParam( $_POST, 'email_copy', 0 ) );
$menu = $mainframe->get( 'menu' );
$mparams = new mosParameters( $menu->params );
$bannedEmail = $mparams->get( 'bannedEmail', '' );
$bannedSubject = $mparams->get( 'bannedSubject', '' );
$bannedText = $mparams->get( 'bannedText', '' );
$sessionCheck = $mparams->get( 'sessionCheck', 1 );
// check for session cookie
if ( $sessionCheck ) {
// Session Cookie `name`
$sessionCookieName = mosMainFrame::sessionCookieName();
// Get Session Cookie `value`
$sessioncookie = mosGetParam( $_COOKIE, $sessionCookieName, null );
if ( !(strlen($sessioncookie) == 32 || $sessioncookie == '-') ) {
mosErrorAlert( _NOT_AUTH );
}
}
// Prevent form submission if one of the banned text is discovered in the email field
if ( $bannedEmail ) {
$bannedEmail = explode( ';', $bannedEmail );
foreach ($bannedEmail as $value) {
if ( stristr($email, $value) ) {
mosErrorAlert( _NOT_AUTH );
}
}
}
// Prevent form submission if one of the banned text is discovered in the subject field
if ( $bannedSubject ) {
$bannedSubject = explode( ';', $bannedSubject );
foreach ($bannedSubject as $value) {
if ( stristr($subject, $value) ) {
mosErrorAlert( _NOT_AUTH );
}
}
}
// Prevent form submission if one of the banned text is discovered in the text field
if ( $bannedText ) {
$bannedText = explode( ';', $bannedText );
foreach ($bannedText as $value) {
if ( stristr($text, $value) ) {
mosErrorAlert( _NOT_AUTH );
}
}
}
// test to ensure that only one email address is entered
$check = explode( '@', $email );
if ( strpos( $email, ';' ) || strpos( $email, ',' ) || strpos( $email, ' ' ) || count( $check ) > 2 ) {
mosErrorAlert( _CONTACT_MORE_THAN );
}
if ( !$email || !$text || ( JosIsValidEmail( $email ) == false ) ) {
mosErrorAlert( _CONTACT_FORM_NC );
}
$prefix = sprintf( _ENQUIRY_TEXT, $mosConfig_live_site );
$text = $prefix ."\n". $name. ' <'. $email .'>' ."\n\n". stripslashes( $text );
$success = mosMail( $email, $name , $contact[0]->email_to, $mosConfig_fromname .': '. $subject, $text );
if (!$success) {
mosErrorAlert( _CONTACT_FORM_NC );
}
// parameter check
$params = new mosParameters( $contact[0]->params );
$emailcopyCheck = $params->get( 'email_copy', 0 );
// check whether email copy function activated
if ( $email_copy && $emailcopyCheck ) {
$copy_text = sprintf( _COPY_TEXT, $contact[0]->name, $mosConfig_sitename );
$copy_text = $copy_text ."\n\n". $text .'';
$copy_subject = _COPY_SUBJECT . $subject;
$success = mosMail( $mosConfig_mailfrom, $mosConfig_fromname, $email, $copy_subject, $copy_text );
if (!$success) {
mosErrorAlert( _CONTACT_FORM_NC );
}
}
$link = sefRelToAbs( 'index.php?option=com_contact&task=view&contact_id='. $contact[0]->id .'&Itemid='. $Itemid );
mosRedirect( $link, _THANK_MESSAGE );
}
}