The JavaScript syntax to make both templates work is a little different than most AddToAny configurations at the moment. Here’s one way:
a2a_config.templates = {
email: {
subject: "Check this out: ${title}",
body: "Click the link:\n${link}"
},
twitter: "Check out ${title} ${link} by @AddToAny"
};
I tried this and it’s still not working :/
I put that code in : Settings > Addtoany > Additional Javascript.
It’s like the plugin don’t take care about the code we can put there …
The result it gives :
– When I click on “Email” : the subject is the name of the page and the content is just the link of the page.
– When I click on “Twitter” : the subject and the link are concatenated.
Is there an other way to try the code ? Per example, could we put it in the functions.php of our theme ?
If it’s not working, that indicates a larger site issue.
You can point to your site so folks here can take a quick look, or try the basic troubleshooting as suggested in the plugin’s 2nd FAQ to find the root cause.
Hum, I deactivated the plugin and reactivated it, and misteriously it works fine now :/ and without deactivated any other plugin..
So thank you for your help, issue solved.