Indicator for mail from Curatescape site?

I occasionally get email that has come from users clicking the mail icon on our Curatescape site; for example, I’ll get an email that says something like “What information do you have about Historic Site X?” In such cases, it would be helpful to know that they’ve connected with me through the Curatescape site, and not just someone who found my email elsewhere.

Is there a way to add an automatic subject line or other indicator to emails that come through the site? I couldn’t find anything in either the theme or general Omeka settings. I’m mildly comfortable doing basic code edits, if there’s a solution there.

Thanks!

You could edit the mh_social_array() function in custom.php (line 2011).

Change this line:

($email=get_theme_option('contact_email') ? get_theme_option('contact_email') : get_option('administrator_email')) ? array_push($services,'<a target="_blank" rel="noopener" title="Email" href="mailto:'.$email.'" class="button social icon email"><i class="fa fa-lg fa-envelope" aria-hidden="true"><span> Email</span></i></a>') : null;

To this…

($email=get_theme_option('contact_email') ? get_theme_option('contact_email') : get_option('administrator_email')) ? array_push($services,'<a target="_blank" rel="noopener" title="Email" href="mailto:'.$email.'?subject='.__('%s Contact',get_option('site_title')).'" class="button social icon email"><i class="fa fa-lg fa-envelope" aria-hidden="true"><span> Email</span></i></a>') : null;	

That will add “[Your Site Title] Contact” as the default subject line for the email if the user clicks the link to open it in a mail app (it won’t do anything if they copy-paste the email address, which might actually be the more common use… I’m not sure). Of course, the user may opt to change the subject either way.

Thanks, Erin - that looks like it will work!

Another simpler solution is to use the (little known) fact that every email address has an infinite number of aliases:
[email protected]
and
[email protected]
go to the same place, your inbox.

So you could set your admin/contact email to be the latter, and then emails that come that way will have this appear in the To: line.

1 Like

That’s a pretty cool trick. I wasn’t aware of it. Looks like it works in both Gmail and Outlook, so if your address isn’t one of those, you might want to do a little research.