Explore the community Forums Lectora Lectora Questions & Answers Need Help Creating Custom Content using additional programming

Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
    Posts
  • #309416 Score: 0
    Profile photo of Melanie Meister
    Melanie Meister
    Member
    beginner
    intermediate
    friend finder
    @mmeister1007

    Hello all, I am a newbie.  I have been tasked with creating an additional login/register admin area that would display reporting from those who tested but also that interfaces with a MySQL database that is being feed with the testing results.  I honestly don’t know where to start.  Can I use VBScript or PHP custom code to incorporate that into a current Lectora program?  If I can, how can I do this or can you point me into the direction of where I should be posting this?

    #309423 Score: 0
    Profile photo of Math Notermans
    Math Notermans
    Member
    contributor
    intermediate
    advanced
    friend finder
    junior moderator
    advocate
    LUC16 Attendee
    LUC16
    wise owl
    curious george
    118 pts
    @mnotermans5114

    Hi Melanie,

    VBScript i am not sure about if and how it can be connected with Lectora. PHP is server side. So yes, you can connect from Lectora with a PHP script. You can connect with a PHP script by either using a Javascript call in your course somewhere or by using the forms built in Lectora. In both cases you would need to pass variables by using GET or POST data. The serverside script acts on that data and gives back some feedback you can show/work with in Lectora.

    Another option is like this sample:
    https://community.trivantis.com/shared-content/online-journal-proof-of-concept-v2/
    It uses Firebase, a Google cloud realtime database. No PHP needed, just a straight connection through Javascript with the database. If you have a filled complex MySql database from which you need to get data… then PHP probably is your best bet. On the other hand , if no data yet inside a MySql database, and you need to create/setup a database too…then Firebase might be a great option, especially because its realtime and quick too.

    Kind regards,

    Math

    #309506 Score: 0
    Profile photo of Melanie Meister
    Melanie Meister
    Member
    beginner
    intermediate
    friend finder
    @mmeister1007

    VBScript wasn’t something I preferred, it was just something I had read in documentation somewhere so I thought I was limited to using it.  PHP would be much better and seems like, since I will be incorporating with a MySQL database, it would be the best option.  I had never used FireBase so that is good to know.  Thank you so much for your response.  I am sure I will have more questions about how to initially connect with the software and get it to read my code but at least I know what is possible now.

     

    Thanks,

    Melanie

    #309508 Score: 0
    Profile photo of Sergey Snegirev
    Sergey Snegirev
    Member
    contributor
    intermediate
    advanced
    friend finder
    lab member
    junior moderator
    advocate
    LUC16
    LUC16 Attendee
    wise owl
    336 pts
    @ssneg

    Hi Melanie,
    so essentially you want to create a server application that would store Lectora test results along with learner’s input such as Name or Email, correct? That is quite easy:
    – step 1: In Lectora, create a test and all forms for learners to enter their names
    – step 2: create a PHP script and a MySQL database. The script should get POST parameters and store them into a database. This is usually chapter 2 of any PHP textbook. See this for example: http://www.tizag.com/phpT/postget.php
    – step 3: Enable “submit results to CGI / Include all variable value” in Lectora, enter the URL of your server script (e.g. http://www.example.com/submitresults.php), set it to POST.

    Of course, if you want to display the results, you will also need to create a PHP page that reads from the database and displays the results. This is usually Chapter 1 of any PHP textbook.

    Please note that this will not authenticate your users against any database, it will simply take whatever they input as their names. If you want authentication, you have to expand the server side with a database containing learner names and passwords as well as a method of authenticating learners against the database, creating new learners, managing lost passwords, securing it etc. etc. In other words, you are building your own small LMS.

    And if this is your first venture into the wonderful world of PHP, MySQL, servers and databases, then this might be a little bit too much. The easy way out is to just use Lectora’s ability to submit variables to Google Drive.

    Cheers,
    Sergey

    #310074 Score: 0
    Profile photo of Peter Jackson
    Peter Jackson
    Member
    beginner
    intermediate
    advanced
    friend finder
    contributor
    junior moderator
    wise owl
    group mod
    entry
    winner
    17 pts
    @pjackson2462

    G’day Melanie,

    Have you seen what can be done using xAPI (AKA Tin Can)?

    Take a look at the Peer Comparison example, simple click the “Contest” menu option above.

    Regards, Peter

    http://www.LectoraDeveloper.com

Viewing 5 posts - 1 through 5 (of 5 total)

You must be logged in to reply to this topic.