Web Object & PHP to Generate a Custom Certificate of Completion
Inspired by Articulate community member Jerry in this forum thread (and others I’ve seen like it in the past), as well as conversations I had with Tom last week at the ASTD show, I’ve created a simple example of how you can leverage the underused Web Object feature of Articulate Presenter, combined with a little PHP and Web design, to create an embedded certificate of completion directly in your training courses.
The demo will go a long way in helping you understand when you see it in action, but here’s how I did it:
- Create some PHP forms leveraging session variables (download my example source files).
- Upload the PHP files to your Web server (most Web servers support PHP, which can run on both Linux and Windows servers; consult your IT department if you’re not sure).
- In PowerPoint, open the course to which you’d like to add the certificate Web Object.
- Add a new slide, then go to Articulate -> Insert Web Object and follow the steps to display your Web Object in the Articulate Player (here’s the link to my example form).
- Publish your course & upload it to your Web server or your Articulate Online account.
- Distribute to your users.
With PHP and some creative Web development, the sky’s the limit — you could probably even use a Web Object at the beginning of the course to have the student register, then use that data to generate your certificate at the end.
Throw in a MySQL or other database on the back end and you could even keep records of who’s viewed your course (in my example it’s just PHP session variables, so no data are stored anywhere but in your browser session).
The other cool thing about this approach is that you can manage your Web Object content separately from your published course content; Web Objects pull directly from live Web content (though you can also insert local Web content from your computer, if you prefer).
Articulate Knowledge Portal customers: You can learn about another way to create a certificate in the documentation.
40 responses to “Web Object & PHP to Generate a Custom Certificate of Completion”
Hi Gabe,
Is there any way that we can print the certificate? I’d appreciate your response.
Thanks,
Rowena
Add a javascript print button to the webpage something like this.
var strButtonText= “Print Certificate”;
function printpage() {
window.print();
}
document.write(“”);
Hi Gabe,
I used your certificate coding and it worked quite well. (We use Artulate Presenter and Quizmaker to develop online courses in several languages.)
However, the certificate will generate onscreen whether a student passes or fails the course. Do you know of a line of code I can put into the certificate to force the certificate generation to print only upon receiving a passing score (or a score above some determined number)?
I tried using a { void } code, but I am doing something wrong because it voids the generation of a certificate completely.
Thanks for your help,
Becky
Is it possible to generate a random number at the start of a presentation then have the viewer enter that number to prove they watched it?
Using PHP or Flash?
Derek- You could embed another Web Object at the start of your presentation that contains a code or script to generate a random number. Would that do it?
Many thanks for you last response
Can you record the score on the certificate?
It would be FAR better having an option for Articulate provide variables like Score, time, taken etc to another page. An interesting work around but you really shouldn’t need workarounds!
All the best
Derek
Derek- You could probably combine this PHP certificate approach with the Quizmaker email results via PHP method that many of our customers use.
Again many thanks Gabe I’ll have a look at that. Sorry for late response. I’ve been away with health problems 🙂
Gabe,
I’m having trouble getting your web object and PHP certificate approach to work. The demo also is looking for files on an Articulate Server, and doesn’t fill in the certificate anymore. I can get your certificate to publish, but can’t get the page that asks for user info to link to the certificate info. I am publishing to AO. Any ideas? THanks Ed
Hi Ed- You’ll need to host the Web object with the certificate / user input form on your own server that supports PHP. You won’t be able to manage the PHP code on AO.
Hi Gabe,
I’m having a problem when we encounter names with a ‘ (ie. O’Connor). The certificate will output it as O///’Connor. I’m sure this is something to do with the coding. Any ideas on how to fix this?
Thanks.
Hi Umar- That has to do with the way PHP handles apostrophes. So you need to have your code escape the characters so that the output is correct when it displays.
I think the PHP stripslashes function is what you need to strip the slashes on output.
You could also try doing some Web searches on the topic, and I think you should be able to find a solution.
Hello Gabe- I would like to know whether your certificate will work for my agency should I be saving my courses onto our State server and not using Articulate Online to house my courses?
Additionally, when I publish our course, I want only individuals who have successfully completed the course to have access to the certificate into which they can put their name. How do I structure the the course in Articulate presenter to prevent certificate access by those failing the course?
Thanks for your input.
Hi Barbara- If you want to manage private user accounts and have tracking/reporting on your content, then it’s a good idea to continue using Articulate Online. However, you can set up a certificate on a separate server and use as a Web Object in conjunction with Articulate Online and your content hosted there, as described in this blog entry.
Do you have a quiz at the end of your course? You could add a slide containing the Web Object certificate after the quiz, and set up the quiz so that only users who pass it can proceed to the final slide. You can learn more about that in Quizzes -> Setting Properties
Gabe,
I am currently in a situation in which I may need to use a couple of different systems for course hosting. This is why I am trying to create a course that is prepared in such a way that regardless of the system I choose, the SCORM compliant course will run from whereever it is launched. Our state bought into the PeopleSoft ELM system years ago and I am needing to justify going to any other system. For now, my focus is creating self contained courses that can include the tests and allow an individual to print out a certificate of completion for their own records. Documentation within any LMS system is currently not available to me.
Barbara
My apologies Gabe. Thank you for your assistance and recommendations. By the way, I did not understand how to include a “Web Object” for the certificate. As you can probably tell, I am a health educator and NOT a technical person so this puts me at a disadvantage. Soory.
Barbara
Hi Barbara- In Step 4 of this blog entry you’ll see the part where I explain inserting the certificate as a Web Object. Note that to use this example you need to have access to a web server that supports PHP, which is likely one different than your LMS.
RE: “the SCORM compliant course will run from whereever it is launched.” So long as the LMS you’re using is also SCORM compliant, then courses you create with Articulate products should work just fine in the LMS. SCORM Test Track is a good way to get confirmation.
Hi,
can the PHP also pass a variable? I want the course to end when a wrong answer is given.
Roel
Hi Roel- Unfortunately, I don’t know of any way to pass variables between Articulate-generated output and a PHP Web Object. That’s not to say it can’t be done – just that I haven’t come across anything like that.
One idea would be to create a link in your PowerPoint or quiz results finish button that would contain a variable to pass to a new PHP site.
Hi, when adding a web oject it looks for an index.html file. How does an index.html file call you PhP files.
Hi Jameka- you can point directly to the PHP page when the PHP files are hosted on your web server, which they’ll need to be anyway since PHP needs a server running PHP to work properly. When pointing to a Web Object online, you can use any URL you’d like; it doesn’t have to be an index.html file.
I am wondering if anyone figured out a way to grab the students name from the LMS via SCORM so they don’t have to enter it?
We are building a presentation with a quiz. My question is this: Can the quiz answer and score variables be captured and stored in a database? We are using ColdFusion, which is very robust. However, we need to be able to capture the answers to the questions as well as the final score in order to store in a database and either present the user with a certificate or not.
Or, do I need I need to pass those values through a url string?
Hi John- Quizmaker is designed to work with either Articulate Online or a third-party LMS.
However, you might want to check out these two unsupported work-arounds from our forums:
Quiz to database, instructions and code
Articulate ’09 – Email Results Tutorial – PHP
HI Gabe – followed the steps but when I post it I am getting Directory Listing Denied
This Virtual Directory does not allow contents to be listed.
DOes this mean our servers do not support PHP?
Hi Diane- that’s just a setting on your web server. Take a look. Or you can name the index.php file something like certificate.php and point directly to that file instead of its containing directory.
Hi Gabe – I’ve followed all the steps, but when the module launches it tries to download or save the .php file instead of displaying and collecting the input fields. I also didn’t upload the now.fn file, because I really don’t care about displaying the date/time on the form. Please advice.
Thanks!
Hi Gloria- it sounds like your server may not be configured to support PHP. Have you checked with your server admin?
I want to be able to create a completion certificate without hosting it on a web server. My client requires the ability to create the certificate from any where in the world without access to the internet, a centralized server or any connectivity. They want to be able to pop in the CD into a lap top and hook up a small portable printer, take the course, print the certificate and move on. How can I make this happen using Articulate?
Hi Douglas- take a look at this forum thread, which may get you going in the right direction.
This does not solve the issue of not having the certificate info hosted on a web server. I need it fully encompased when published to CD.
The custom SWF solution noted in the thread could work locally. And here’s a solution that may be even easier: Create a custom certificate using the report.html file.
Hello
I wish to know whether there is the possibility for you to share the source code of this demo.
Thanks
youshra
Hi Youshra- yes, the source files are linked to via #1 in the post. Here’s the link.
Hi,
is there any chance to save the certificate as .jpg or .pdf?
thanks
@Mystica: The method described here does not allow for saving of the certificate to one of those formats, so you’d want to explore other options.
Is there a way to generate the certificate, give the user the ability to print the certificate if needed, then have it saved with the users course history as an icon somewhere underneath the pass/fail status on their articulate-online account?
@Michael: Note that this certificate method is not specific to Articulate Online, and if you do use it in conjunction with Articulate Online would require a separate web server that supports PHP (where you’d host and call in the certificate via a Web Object). That said, users should be able to print the certificate, but it cannot be saved in Articulate Online.
If you’d like to see a certificate feature in Articulate Online, let us know here.
Comments are closed on this post. Need more help? Post your question in the E-Learning Heroes Discussions.