Noptin_Mailer::default_from_address()

The default emails from address.


Description Description

Defaults to noptin@$sitename Some hosts will block outgoing mail from this address if it doesn’t exist, but there’s no easy alternative. Defaulting to admin_email might appear to be another option, but some hosts may refuse to relay mail from an unknown domain.


Top ↑

Source Source

File: includes/class-noptin-mailer.php

	public function default_from_address() {

		// Get the site domain and get rid of www.
		$sitename = strtolower( $_SERVER['SERVER_NAME'] );
		if ( substr( $sitename, 0, 4 ) == 'www.' ) {
			$sitename = substr( $sitename, 4 );
		}

		$from_email = 'noptin@' . $sitename;

		return apply_filters( 'noptin_mailer_default_from_address', $from_email, $this );

	}


Top ↑

Changelog Changelog

Changelog
VersionDescription
1.2.8Introduced.

Top ↑

User Contributed Notes User Contributed Notes

30 day money back guarantee
Safe & Secure online payment
Custom CSS Slide Example
Custom Animation Example
Default Animation