phpbb-extensions/boardrules — pull request #76 by VSEphpbb (2014-03-08 04:52:13+00:00)
Title: Add board rules agreement to registration page

This PR depends on two events that do not exist in phpBB yet (this PR should not be merged until any events it needs do exist in the core).

When require at registration is enabled, a short message is appended to the registration agreement text stating that the user is agreeing to the board rules as well, by registering on the forum, and a link to the board rules is presented (opens up in a new window). e.g.:

> You agree to abide by the rules of these forums set forth in the following “Rules” section: [View the Rules of this Board](#).

One template event in `ucp_agreement.html` called `ucp_agreement_terms_after` which would go right after this line (in prosilver)
```

{L_COPPA_BIRTHDAY}{L_TERMS_OF_USE}

```

One core event in `ucp_register.php` called `core.ucp_register_agreement` just before the line: `$this->tpl_name = 'ucp_agreement';`

The core event is mostly needed because the guest on the register page can switch languages if the board has multiple languages installed. The language files of our extension need to be reloaded if the guest did in fact change language files (otherwise our text on the registration page just gets replaced by raw template vars).