Sorry I think I figured out what you were doing.
You can’t put the shortcode in the href. That’s not how shortcodes are intended. Shortcodes write code for you and in the case of this plugin, it’s not just returning an email address it’s outputing a handful of code, so it wouldn’t work inside an html href.
I did wrap it in a span tag with yellow:
<span style="color:yellow;">[email]</span>
and since the span is not the parent tag of the mailto link <a href="mailto:[email protected]">
, it is not being applied. It registers the website’s global css for all <a>
tags, as it should being the cascade of how CSS works.
So at the moment there is no way to apply span styles outside some custom css in your style.css in your theme or the custom css module inside WordPress.
You can apply html elements like strong or em ect, but not style attributes.
Each email has a custom html class assigned to it so you could add css styles to your style sheet for each specific one (you would have to inspect the code in the browser to see what class is added, it’s dynamic so will depend on the email). Or you can set the global style using the following:
.cfe-wrapper a {color:yellow;}
PS I will put on my to do list on retaining span styles wrapping the short code.