Skip to content

Commit 80005f8

Browse files
committed
Ensure that the component ID is inserted into the Forgot Password link HTML ID, to guarantee uniqueness
1 parent 84fc08c commit 80005f8

File tree

2 files changed

+6
-3
lines changed

2 files changed

+6
-3
lines changed

config/alfresco/site-webscripts/org/sharextras/components/reset-password/login.get.html.ftl

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,5 +8,8 @@
88
</@markup>
99

1010
<@markup id="custom-guest-password-link" target="buttons" action="after" scope="global">
11-
<a id="link-forgotPass" href="#">${msg("link.forgotPass")}</a>
12-
</@markup>
11+
<@uniqueIdDiv>
12+
<#assign el=args.htmlid?html>
13+
<a id="${el}-link" href="#">${msg("link.forgotPass")}</a>
14+
</@uniqueIdDiv>
15+
</@markup>

source/web/extras/components/guest/custom-guest-reset-password.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ if (typeof Extras === undefined || !Extras) {
2222

2323
onReady: function RPD_onReady() {
2424
// .. hook up or lost password link event handler code
25-
YAHOO.util.Event.addListener("link-forgotPass", "click", function (e) {
25+
YAHOO.util.Event.addListener(this.id + "-link", "click", function (e) {
2626
var actionUrl = Alfresco.constants.PROXY_URI_RELATIVE.replace("/alfresco/", "/alfresco-noauth/") + "extras/modules/reset-user-password";
2727
YAHOO.util.Event.stopEvent(e);
2828
if (!this.resetPasswordDialog) {

0 commit comments

Comments
 (0)