Fossil SCM

Update [6c8c93a5f7] to fix redirects to the captcha screen and set the keyboard focus to the password input field if there's no user ID input field.

florian 2025-08-15 05:10 trunk
Commit b8731485b02898912d883087565ed920b6207fcb87a49e38715e48267c3f6462
1 file changed +2 -2
+2 -2
--- src/login.c
+++ src/login.c
@@ -807,11 +807,11 @@
807807
@ </tr>
808808
}
809809
@ <tr>
810810
@ <td class="form_label" id="pswdlabel">Password:</td>
811811
@ <td><input aria-labelledby="pswdlabel" type="password" id="p" \
812
- @ name="p" value="" size="30">
812
+ @ name="p" value="" size="30"%s(anonFlag ? " autofocus" : "")>
813813
if( anonFlag ){
814814
@ </td></tr>
815815
@ <tr>
816816
@ <td></td><td>\
817817
captcha_speakit_button(uSeed, "Read the password out loud");
@@ -1972,11 +1972,11 @@
19721972
blob_appendf(&redir, "%R/login?g=%T", zPathInfo);
19731973
}
19741974
if( zQS && zQS[0] ){
19751975
blob_appendf(&redir, "%%3f%T", zQS);
19761976
}
1977
- if( anonOk ) blob_append(&redir, "&anon", 5);
1977
+ if( anonOk ) blob_append(&redir, "&anon=1", 7);
19781978
cgi_redirect(blob_str(&redir));
19791979
/* NOTREACHED */
19801980
assert(0);
19811981
}
19821982
}
19831983
--- src/login.c
+++ src/login.c
@@ -807,11 +807,11 @@
807 @ </tr>
808 }
809 @ <tr>
810 @ <td class="form_label" id="pswdlabel">Password:</td>
811 @ <td><input aria-labelledby="pswdlabel" type="password" id="p" \
812 @ name="p" value="" size="30">
813 if( anonFlag ){
814 @ </td></tr>
815 @ <tr>
816 @ <td></td><td>\
817 captcha_speakit_button(uSeed, "Read the password out loud");
@@ -1972,11 +1972,11 @@
1972 blob_appendf(&redir, "%R/login?g=%T", zPathInfo);
1973 }
1974 if( zQS && zQS[0] ){
1975 blob_appendf(&redir, "%%3f%T", zQS);
1976 }
1977 if( anonOk ) blob_append(&redir, "&anon", 5);
1978 cgi_redirect(blob_str(&redir));
1979 /* NOTREACHED */
1980 assert(0);
1981 }
1982 }
1983
--- src/login.c
+++ src/login.c
@@ -807,11 +807,11 @@
807 @ </tr>
808 }
809 @ <tr>
810 @ <td class="form_label" id="pswdlabel">Password:</td>
811 @ <td><input aria-labelledby="pswdlabel" type="password" id="p" \
812 @ name="p" value="" size="30"%s(anonFlag ? " autofocus" : "")>
813 if( anonFlag ){
814 @ </td></tr>
815 @ <tr>
816 @ <td></td><td>\
817 captcha_speakit_button(uSeed, "Read the password out loud");
@@ -1972,11 +1972,11 @@
1972 blob_appendf(&redir, "%R/login?g=%T", zPathInfo);
1973 }
1974 if( zQS && zQS[0] ){
1975 blob_appendf(&redir, "%%3f%T", zQS);
1976 }
1977 if( anonOk ) blob_append(&redir, "&anon=1", 7);
1978 cgi_redirect(blob_str(&redir));
1979 /* NOTREACHED */
1980 assert(0);
1981 }
1982 }
1983

Keyboard Shortcuts

Open search /
Next entry (timeline) j
Previous entry (timeline) k
Open focused entry Enter
Show this help ?
Toggle theme Top nav button