Both Payment and Password options for the same Course

Both Payment and Password options for the same Course

- Chardelle Busch の投稿
返信数: 18
画像 Core developers

If anyone is interested in the code to have both PayPal and an enrollment key option for a course (see image) let me know.

Chardelle

添付 paypassword.gif
Chardelle Busch への返信

Re: Both Payment and Password options for the same Course

- Ralph Blakeslee の投稿

Happy New Year Chardelle!

I would be interested in this.  Is it developed already?  Can I make a contribution?

Ralph

Ralph Blakeslee への返信

Re: Both Payment and Password options for the same Course

- Chardelle Busch の投稿
画像 Core developers

Hi Ralph,

I just made the code changes since I might need this.  You just need to replace the enrol/paypal/enrol.php file, add a new file, and add a new line to your lang/moodle.php file.  (See the read me file included in the zip) I haven't tested it by actually purchasing a course yet--but it should be fine.

The page shown above will come up if you have enrollment set to PayPal, and have a course with settings that include both an enrollment key and a cost. 

Please note:  I have only tested this with version 1.4.3.

Chardelle Busch への返信

Re: Both Payment and Password options for the same Course

- Chardelle Busch の投稿
画像 Core developers

Update:

Oops, I got in a rush, and I think I put the wrong enrol.php file in the zip (why do I have two folders named "test"?). 

So, please use these files here.

Chardelle Busch への返信

Re: Both Payment and Password options for the same Course

- Ralph Blakeslee の投稿

Thanks Chardelle!

You are becoming some Renaissance woman – personal coach, Phd, code hacker!!!

Ralph
Ralph Blakeslee への返信

Re: Both Payment and Password options for the same Course

- John Haywood の投稿
Thanks Chardelle, I will upload those and give them a go - hopefully the fix will get included in the official moodle release as it is nice to be able to offer both options.
Chardelle Busch への返信

Re: Both Payment and Password options for the same Course

- Eric Eberhardt の投稿

Is it possible that the enrollment key is asked for prior to being asked for payment? If a student pays for a course that a Teacher wishes them to not register for then a refund would have to be made.

Thanks for your help!

Eric

Eric Eberhardt への返信

Re: Both Payment and Password options for the same Course

- Chardelle Busch の投稿
画像 Core developers
Hi Eric,

Are you saying that you want users to enter a key first that then allows them to pay for the course?  How does the student get the key?  If the teacher would have to give them the key anyway, why wouldn't you just have the teacher tell them which course to pay/register for rather than giving them a key.  You could also put a notice in the course info about the refund policy and that the user needs permission first to enroll in a course.
Chardelle Busch への返信

Re: Both Payment and Password options for the same Course

- mandy honeyman の投稿
Hello Chardelle

I'm in the midst of proposing that an adult education (not online) organisation use moodle for booking people onto courses.

The problem is that not everyone will book online, some people will post in cheques, some people will phone in with credit card details, some people will bring in cash etc!

Can I use your option as an either/or, i.e. however they pay they get an enrollment key and can use facilities?

cheers
Mandy
mandy honeyman への返信

Re: Both Payment and Password options for the same Course--Update

- Chardelle Busch の投稿
画像 Core developers
Hi All,

I thought I would update this post. Moodle 1.5 now includes this. If you choose PayPal as an enrollment method, and then enter both a cost and a key into a course's settings, you will get both options as show in this screenshot.

Mandy, for you, this option will be helpful if the organization wants to offer PayPal as an option for their users. Then, users could either pay online using PayPal (they never even see the key for this option), or they enter a key they receive when paying using other methods.
添付 paypal-key.gif
Chardelle Busch への返信

Re: Both Payment and Password options for the same Course--Update

- mandy honeyman の投稿
Thanks Chardelle, that makes lots of sense and will be very useful.
cheers
Mandy
mandy honeyman への返信

Re: Both Payment and Password options for the same Course--Update

- Help Hypersonic の投稿

Sorry, I am new to this great feature. Need some help:

Unable to locate the file to add the line as instructor by the read text, please help:

 Add this line to your moodle/lang/your lang/moodle.php file (note you can change this wording to anything).

$string['paymentkey'] = 'If you already have the enrollment key for this course, please enter it below:';

Thanks

Help Hypersonic への返信

Re: Both Payment and Password options for the same Course--Update

- Chardelle Busch の投稿
画像 Core developers
As the post above says, if you upgrade to Moodle version 1.5, you don't need to do anything extra--it's all standard.  
Chardelle Busch への返信

Re: Both Payment and Password options for the same Course--Update

- Help Hypersonic の投稿
I have not learn how to upgrade yet, could you advise where to change it ... thanks
Help Hypersonic への返信

Re: Both Payment and Password options for the same Course--Update

- Chardelle Busch の投稿
画像 Core developers
Hi,

Go to the download page and you will see a link at the bottom:  How to Upgrade. 
Chardelle Busch への返信

Re: Both Payment and Password options for the same Course--Update

- Help Hypersonic の投稿

Oh thanks. Will learn it.

In the meantime, can you advise when to do the changes for version 1.4?

Unable to locate the file to add the line as instructor by the read text, please help:

 Add this line to your moodle/lang/your lang/moodle.php file (note you can change this wording to anything).

$string['paymentkey'] = 'If you already have the enrollment key for this course, please enter it below:';

Help Hypersonic への返信

Re: Both Payment and Password options for the same Course--Update

- Chardelle Busch の投稿
画像 Core developers
I highly recommend upgrading to 1.5, but the above instructions refer to a file named moodle.php in your language file (whatever language you use).  So, if you are using en, add it to the file:  moodle/lang/en/moodle.php.  Just copy and paste that line in that file to have that text show up above the enrollment key entry box.  You can change the wording in that sentence to anything you want.

I hope this helps.
Chardelle Busch への返信

Re: Both Payment and Password options for the same Course--Update

- Jason Khoo の投稿

Hi All,

After search the forum for 2 days, I finally found how the interface show look like when the course is configured to be paid by Paypal. THe problem now is I am not able to get the interface to appear. Now the course cannot be access withou paying and yet the payment interface did not appear. I have installed moodle 1.5.3. My url is http://members.business-excel-training-course.com/. Appreciate if you could help me on this.

Thanks in advance.

Best regards.

Jsaon Khoo.