From 00a354a2da2638f884ea7d8f328f5fa818c863a0 Mon Sep 17 00:00:00 2001 From: ethem Date: Fri, 27 Jan 2006 14:16:41 +0000 Subject: [PATCH] Which form is submitted? Internal or authorize? This eliminates undefined form->property notices when user submitted internal form. --- enrol/authorize/enrol.html | 2 +- enrol/authorize/enrol.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/enrol/authorize/enrol.html b/enrol/authorize/enrol.html index 83880dd4c4b..134e5a8cc5d 100755 --- a/enrol/authorize/enrol.html +++ b/enrol/authorize/enrol.html @@ -108,7 +108,7 @@ $usercountry = empty($form->cccountry) ? $USER->country : $form->cccountry; ccerrors['cczip'])) { formerr($this->ccerrors['cczip']); } ?> -"> +"> diff --git a/enrol/authorize/enrol.php b/enrol/authorize/enrol.php index 18ba349f830..835b1ebda08 100755 --- a/enrol/authorize/enrol.php +++ b/enrol/authorize/enrol.php @@ -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); } }