From c2af8ca9498cb399a6dccb7564b23385c11805d8 Mon Sep 17 00:00:00 2001 From: Platonides Date: Wed, 21 Oct 2015 22:27:06 +0000 Subject: [PATCH] MediaWiki friendly username sanitization and phpmailer override --- functions.php | 50 ++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 50 insertions(+) diff --git a/functions.php b/functions.php index 0930890..ce21d05 100644 --- a/functions.php +++ b/functions.php @@ -1,5 +1,34 @@ SMTPSecure = 'tls'; + $phpmailer->SMTPAuth = true; + $phpmailer->Host = 'mail.wikimedia.es:25'; + $phpmailer->Username = 'blog@wikimedia.es'; + $phpmailer->Password = '8b5e81aa7cd67538fc124e3c990a9946'; + $phpmailer->AuthType = 'PLAIN'; + $phpmailer->isSMTP(); +} + +add_action('phpmailer_init', 'wmes_phpmailer_init', 10); + + // Supresión del campo «Web» en comentarios --abián add_filter('comment_form_default_fields', 'url_filtered'); @@ -52,3 +96,9 @@ function url_filtered($fields) unset($fields['url']); return $fields; } + + +function skip_filesystem_check($form_post, $type = '', $error = false, $context = false, $extra_fields = null, $allow_relaxed_file_ownership = false ) { + return true; +} +#add_filter('request_filesystem_credentials', 'skip_filesystem_check'); -- 2.30.2