Make WordPress Core

Changes between Version 1 and Version 2 of Ticket #19549, comment 20


Ignore:
Timestamp:
06/03/2012 06:00:41 AM (13 years ago)
Author:
clearsite
Comment:

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #19549, comment 20

    v1 v2  
    1 If I may insert myself into this discussion, there is a way to do this that suits EVERYONE here.
    2 
    3 1. Create an extender; class wp_phpmailer extends phpmailer
    4 2. Create a new send function in there
    5 function Send() { do_action_ref_array( 'phpmailer_send', array( &$this ) ); parent::Send(); }
    6 ->now we can hook just before sending, where we can alter all headers as much as we want.
    7 3. patch WordPress to use new wp_phpmailer instead of new phpmailer.
    8 
    9 This is all theory of course, but at least, this way there is no need to alter the 3rd party lib phpmailer and still allow for the alteration of the X-Mailer header.
    10 
    11 (And yes, I agree, we developers should be able to change that because our clients want us to :P )
     1post removed - after a good nights sleep this idea looks quite bad :P
     2sorry to have bothered you.