a8566f2994a868dfe2521ac7fca7529f75cdfa16
chinhli
Thu May 31 09:55:14 2012 -0700
iFinished new hgSession welcome and account info UI change.
diff --git src/hg/hgSession/hgSession.c src/hg/hgSession/hgSession.c
index d5e063f..bb44535 100644
--- src/hg/hgSession/hgSession.c
+++ src/hg/hgSession/hgSession.c
@@ -46,69 +46,74 @@
cgiDecode(encStr, decStr, len);
return decStr;
}
void welcomeUser(char *wikiUserName)
/* Tell the user they are not logged in to the wiki or other login
* system and tell them how to do so. */
{
char *wikiHost = wikiLinkHost();
cartWebStart(cart, NULL, "Welcome %s", wikiUserName);
jsInit();
if (loginSystemEnabled()) /* Using the new hgLogin CGI for login? */
{
+ printf("Your account
"
+ "Name: %s
",wikiUserName);
+ printf("Change password
",
+ wikiLinkChangePasswordUrl(cartSessionId(cart)));
+ printf("Sign out\n",
+ wikiLinkUserLogoutUrl(cartSessionId(cart)));
+/**** to be removed
printf("If you are not %s (on the %s at "
"%s) "
"and would like to sign out or change identity, \n",
wikiUserName, loginSystemName(), wikiHost, wikiHost);
printf("click here to sign out.\n",
wikiLinkUserLogoutUrl(cartSessionId(cart)));
+*************************/
}
else
{
printf("If you are not %s (on the wiki at "
"%s) "
"and would like to sign out or change identity, \n",
wikiUserName, wikiHost, wikiHost);
printf("click here to sign out.\n",
wikiLinkUserLogoutUrl(cartSessionId(cart)));
}
}
void offerLogin()
/* Tell the user they are not logged in to the system and tell them how to
* do so. */
{
char *wikiHost = wikiLinkHost();
cartWebStart(cart, NULL, "Sign in to UCSC Genome Bioinformatics");
jsInit();
if (loginSystemEnabled())
{
+ printf("Login
",
+ wikiLinkUserLoginUrl(cartSessionId(cart)));
+ printf(""
+ "Create an account
",
+ wikiLinkUserSignupUrl(cartSessionId(cart)));
printf("Signing in enables you to save current settings into a "
"named session, and then restore settings from the session later.\n"
"If you wish, you can share named sessions with other users.\n");
- printf("
The sign-in page is handled by our %s system. ", loginSystemName()); -printf("click here to sign in.\n", - wikiLinkUserLoginUrl(cartSessionId(cart))); -printf("To register for an account, " -// "" - "" - "click here to sign up.\n", - wikiLinkUserSignupUrl(cartSessionId(cart))); } else { printf("Signing in enables you to save current settings into a " "named session, and then restore settings from the session later.\n" "If you wish, you can share named sessions with other users.\n"); printf("
The sign-in page is handled by our " "wiki system:\n", wikiHost); printf("click here to sign in.\n", wikiLinkUserLoginUrl(cartSessionId(cart))); printf("The wiki also serves as a forum for users " "to share knowledge and ideas.\n"); } }