Workaround To Ad Listing Contact Form...
I've opened this thread to simplify and better help those who may be having issues with the ad listing contact form not working properly or for those who are still struggling to resolve the issue...Also, this is a better way of doing it without touching the core files and/or using a plugin
There is another thread that pertains to a solution, but it's a bit confusing as to what should actually been done to resolve the problem, so here we go..
In your child theme put this code at the bottom of your functions.php file:
Code:
function childtheme_ad_contact_do_not_use_user_data( $email, $post_id ) {
$email['from'] = get_option( 'admin_email' );
$email['from_name'] = wp_specialchars_decode( get_bloginfo( 'name' ), ENT_QUOTES );
return $email;
}
add_filter( 'cp_email_user_ad_contact', 'childtheme_ad_contact_do_not_use_user_data', 10, 2 );
This code was provided by meloniq in the other thread, and should work by itself without needing to edit any core files or with the use of a plugin. I have placed only this piece of code onto two sites now, and on both sites the ad listing contact form is working for all email providers: aol, yahoo, gmail, comcast ect..Also, both of these sites have their site's email system set up on their server in order to help comply with the DMARC policy by using domain name emails as required..
The only issue I ran across when testing emails was that when the ad poster receives the inquiry email, they can't simply hit the "Reply" button to respond back to the sender...Either the ad poster has to copy & paste the sender's email address into the email account they wish to use to reply back with, or if they are using Outlook or another similar email program than all the ad poster needs to do is click on the sender's email address to reply back to them..Therefore, to make it easier for users I've implemented instructions for the ad poster on how to reply back to the sender within the "ad poster sidebar contact form email" section of the emails.php file. Though this it's not the ideal way for the ad poster to be able respond back to the sender, it is an solution that works for the time being until AppThemes is able to provide a better solution for the ad listing contact form..I hope you find this solution as helpful as I did once I was able to sorted it out