function legal_version_check in Legal 6.8
Same name and namespace in other branches
- 8 legal.module \legal_version_check()
- 5 legal.module \legal_version_check()
- 6.7 legal.module \legal_version_check()
- 7.2 legal.module \legal_version_check()
- 7 legal.module \legal_version_check()
- 2.0.x legal.module \legal_version_check()
Check if user has accepted latest version of T&C.
2 calls to legal_version_check()
- legal_login in ./
legal.module - Require registered users to accept new T&C.
- legal_user in ./
legal.module - Implementation of hook_user().
File
- ./
legal.module, line 682 - Displays Terms & Conditions, and makes sure they are accepted before registration is accepted.
Code
function legal_version_check($uid, $version, $revision, $legal_account = array()) {
if (empty($legal_account)) {
$legal_account = legal_get_accept($uid);
}
if ($legal_account['version'] == $version && $legal_account['revision'] == $revision) {
$accepted = TRUE;
}
else {
$accepted = FALSE;
}
return $accepted;
}