Which form is submitted? Internal or authorize?
This eliminates undefined form->property notices when user submitted internal form.
This commit is contained in:
@@ -108,7 +108,7 @@ $usercountry = empty($form->cccountry) ? $USER->country : $form->cccountry;
|
||||
<?php if (!empty($this->ccerrors['cczip'])) { formerr($this->ccerrors['cczip']); } ?></td>
|
||||
</tr>
|
||||
</table>
|
||||
<input type="submit" value="<?php print_string("sendpaymentbutton", "enrol_authorize") ?>">
|
||||
<input type="submit" name="ccsubmit" value="<?php print_string("sendpaymentbutton", "enrol_authorize") ?>">
|
||||
</form>
|
||||
|
||||
</div>
|
||||
|
||||
@@ -84,7 +84,7 @@ class enrolment_plugin extends enrolment_base
|
||||
function check_entry($form, $course) {
|
||||
if ((!empty($form->password)) || isguest() || $this->zero_cost($course)) {
|
||||
parent::check_entry($form, $course);
|
||||
} elseif ($this->validate_enrol_form($form)) {
|
||||
} elseif ((!empty($form->ccsubmit)) && $this->validate_enrol_form($form)) {
|
||||
$this->cc_submit($form, $course);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user