User:SPage (WMF)/old/Onboarding new Wikipedians-Engineering

From MediaWiki.org
Jump to navigation Jump to search
Notes on early iteration of GettingStarted from December 2012.

Useful links[edit]

Notes[edit]

en:Special:GettingStarted presents the page, but also hooks successful account creation to:

  • change the title slightly
  • show w:MediaWiki:gettingstarted-msg with Agora CSS
  • turn the "returnto" link into an Agora button
  • use HTML5 browser push state to change the URL shown from Special:Userlogin?type=signup&action=submit to Special:GettingStarted

UserLoginComplete[edit]

 array( &$user, &$injected_html ) );

this is where CentralAuth puts up its row of icons

BeforeWelcomeCreation[edit]

array( &$onboarding_msg, &$injected_html ) 

This is where extensions can supply a custom message; GettingStarted points to w:MediaWiki:gettingstarted-msg.

Other hooks[edit]

Other issues[edit]

Is there any interaction with the new account creation API from Tyler Romeo that Terry approved for core?

  • probably not.

The "return to [Page]" problem[edit]

If on account creation the user goes straight to GettingStarted , we want it to have a nice Agora button saying

[ No thanks, back to Page I was on before account creation]

But the current piece of HTML

<p id="mw-returnto">
  Return to
  [[Page I was on]].
 </p>

is generated by core code andinfo@wikimedia.org added to the page by Special:Userlogin. As the comment in E3Experiments/experiments/onboarding/welcomecreation.js notes:

  • This link is generated by OutputPage::addReturnTo() which hardcodes message 'returnto', which in English is "Return to $1."
  • Besides specials/Userlogin.php, addReturnTo() is also called by SpecialChangeEmail.php, SpecialMobileFeedback.php, SpecialEditWatchlist.php, FileDeleteForm.php, etc.

To get this to be a button in Special:GettingStarted

  • core code needs to supply the information to the redirect in query strings. It was already
  • Extension:Onboarding should implement a similar makeReturnButton , so that this could be offered to OutputPage as more of the site gets Agora-fied.
  • unlike addReturnTo(), the text around the link should be a passed-in message