SOS email template for user creation!

Rumceisz
Contributor
May 21, 2012

Hi,

I need an urgent help! I have to change the user creation email template. I found the usercreated.vm file but when I opened, I found this content:

$i18n.getText("template.user.created.createdaccount")

   $baseurl

$i18n.getText("template.user.created.text.line1")
$i18n.getText("template.user.created.text.line2")

$i18n.getText("template.user.created.passwordchanged")

  ${baseurl}/secure/ResetPassword!default.jspa?os_username=$velocityhelper.urlencode($user.name)&token=$params.get("password.token")

$i18n.getText("template.user.created.lastshowlong", $params.get("password.hours"))

  ${baseurl}/secure/ForgotLoginDetails.jspa?username=$velocityhelper.urlencode($user.name)


#parse("templates/email/text/includes/userdetails.vm")

$i18n.getText("template.user.initiatedby", $initiatingUser.fullName, $initiatingUser.email)

#parse("templates/email/text/includes/footer.vm")

Where can I add the constant text into this??? For instance: "Please enter after the first login..."

Can you please help?

Thanks in advance!

Rumi

1 answer

1 accepted

0 votes
Answer accepted
Nic Brough -Adaptavist-
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
May 22, 2012

That's a velocity file. You can actually just whack your static text straight into it, once you know where it's needed.

Think of velocity as a set of instructions for creating a block of text. As the server reads it, it does three things:

  1. If it finds something with $ in front of it, it looks to see if it's a variable or object that's been created in the page, or handed to it by the java behind it.
  2. If it finds something with # in front of it, it takes it as some form of processing instruction ("code" if you like"
  3. Anything else goes into the output text exactly as it's found

That's a completely non-technical and structurally inaccurate way to describe it. But it does actually describe what comes out.

Try belting in something like "Mr Flibble says 'Time to die'" on the second line - you'll see that come out, word-for-word on the second line of every email.

Rumceisz
Contributor
May 22, 2012

Hi Nic,

thanks!

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events