Greetings!
I am sending messages to authors from within OJS, and some authors are receiving variable names instead of their actual names—for instance, where $submitingAuthorName appears, the author’s name should be displayed. This sometimes happens with the article title as well, such as when sending an invitation to a reviewer. What could be causing this “glitch”—if I can even call it that? Thanks!
OJS version 3.5.0.4.
Hi @fbmarques,
This could be caused by a few things, but usually it means the email template contains a placeholder that OJS doesn’t recognize or can’t populate, so it gets sent literally as the email variable instead of being replaced by the text it is supposed to display.
Some other possible causes could be:
- The variable name is wrong or outdated. For example,
$submitingAuthorName looks misspelled (should be $submittingAuthorName; if the template expects a different tag, it won’t render properly.
- The template was edited manually and now includes variables that aren’t valid for that email type.
- The template is from an older OJS version or a custom/third-party template that wasn’t updated for 3.5.
- The value isn’t available in a context that is outside of its typical use so OJS leaves the placeholder unchanged.
What you might want to try:
- Open the email template in OJS. (Settings - Workflow - Emails - Add and edit templates
- Check whether the placeholder is exactly one OJS supports for that message.
- Click on “Insert content” and search for
$submittingAuthorName and add it that way
OJS is particular when selecting these email variables, hence the introduction of the insert content option - which should get the variables right, rather than typing them manually and risking that they not be structured properly.
-Roger
PKP Team
Dear Roger, thank you very much for the information.
I couldn’t find this specific template under the “Manage Emails” function.
This particular message was sent to the authors (though I believe not to the Principal Author) when the article was submitted for review. I received the message because one of the authors replied to the email they had received, copying the Principal Author and myself (the editor who sent the article for review).
So, I haven’t been able to locate this template among the existing ones.
Also, since our OJS instance was recently updated, it is possible that there is an email containing a variable that no longer exists.
Is there a place in the documentation where I can access a list of all possible variables for version 3.5?
Thanks again!
Yes - I suppose that is possible. But there is likely a new template that has replaced this one, as it is a key aspect of the workflow.
-Roger
The documentation is here: https://docs.pkp.sfu.ca/learning-ojs/journal-managers/en/communications#email-templates
It doesn’t include a list of all the variables, but when you use the “Insert Content” button to add variables to your email text - you can browse Variables and get brief explanations of their uses there.
-Roger
PKP Team
Hello Roger!
I understand, but could you tell me where I can find the email that’s sent to authors when there’s any change in the publication? I’ve looked at all the templates and haven’t found that specific communication that’s causing the problem.
Thank you again for your attention!
Hi @fbmarques,
Has it been sent out previously within your submission? Could you go back and have a look to see what it says and post it here (without any identifying information)? I don’t know directly off-hand that particular template as there are so many, but having that information should provide some clues.
-Roger
PKP Team
Dear Roger, the email is in Brazilian Portuguese; my translation is provided below:
Title of the email received by the author: Editor’s Decision
Email content:
The following email was sent to {$submitingAuthorName} from Revista Vozes dos Vales: Publicações Acadêmicas regarding [article title omitted].
You are receiving a copy of this notification because you were identified as an author of the submission. All instructions in the message below are intended for the author responsible for the submission, {$subposingAuthorName}, and no action is required on your part at this time.
{$messageToSubmitatingAutor}
Please let me know if you have any questions!
Hi @fbmarques,
It took a bit of searching, but I found it:
I searched across the email templates with the text - I actually had better luck using the Portuguese string, and I belive it searched accross both and returned me the correct one (I believe so - if you don’t mind confirming…)
-Roger
PKP Team
Hello, something’s very strange, I can’t find that email here. I must be on a different path than you. Look at the end of the URL I’m on: /management/settings/manageEmails
Look at the images, I can’t find that template.