iLite’s Weblog

October 27, 2009

Download a trial version of the iLite Moodle Dashboard

Visit iLite to download the 7 day trial version of the iLite Moodle Dashboard.

There are some funky new additions to the Dashboard which include the multi-lingual support, improved User search functionality and the Course Relationship Map.

The Course Relationship Map is something completely unique to the Dashboard. As you can see in the image below, we can see that the Course – iLite Dashboard, has 8 Users. We can also see that 5 of the 8 Users have a small (+) sign below them. This indicates that they are enrolled in other Courses. By clicking on the (+) sign, we expand a 3rd level, which shows the Courses that this User has enrolled for. Hover over the icon to view the Course name.

You may be wondering what is the purpose of the Relationship map, well it is to help you see what Courses the Users are doing at a glance. If a Course has prerequisites, you can view if they have been met simply by calling up the Relationship map.

- Kirsten

courseRelationships

 

October 21, 2009

iLite Mobile Learning for the iPhone

Filed under: AMFPHP, General, Mobile, Mobile Websites, Moodle, PHP, eLearning — ilite @ 9:12 am
Tags: , , , , ,

It is exciting times here at iLite. We have just finish developing the interface for the iPhone. What happens here is that this interface extracts your data from Moodle and allows you to view it on your iPhone.

Visit http://www.ilite.co.za/i/ to have a look at this component. Please play around and send any feedback or comments that you may have to me at kirsten@ilite.co.za

Username:  ian

Password:  password

- Kirsten

login MainMenu CoursesCourseDetailsNews

September 23, 2009

Dashboard going multi-lingual

It’s time for another sneak preview of the Dashboard. We have been hard at work for several months now trying to make the Dashboard unique, interactive and visually stimulating. New features include a multi-lingual function and has provisions so far for 6 languages, which are English, Spanish, Portuguese, Italian, French and German. We will look at adding more languages as we get closer to the release date.

Another new and exciting feature is the Degrafa graph inside the datagrid. This allows the scores to be more visually stimulating.  The courses that the user is enrolled for is also listed as well as their quiz results and the course interactivity.

-Kirsten

users

June 29, 2009

Dashboard testing

Filed under: AMFPHP, General, Moodle, PHP, dashboard — ilite @ 6:01 pm

Where are looking for a few beta testers for our Moodle dashboard application. If there are any of you out there running Moodle 1.9 and would like to deploy and test the dashboard, drop us a mail.

UserID to view the demo dashboard:

Username: mary
Password: password

Requirements:

  1. Basic knowledge of PHP. You will have to update the config file, and copy some folders to the root of your server. The Dashboard uses the PHP files to access the Moodle DB and return data. This is only a READ, and nothing will be touched, modified or changed in your DB.
  2. A userID

What to do:

  1. Copy the PHP folder to your server
  2. Copy the Flash folder to your server
  3. Create an ID at iLite (or we can send you one)
  4. Update the config.php file with your Moodle details

How the Dashboard works.
The Dashboard uses the PHP files on your server to retrieve the data from your Moodle database. AMFPHP is used, which gives us a little more performance. Use the icons at the top to navigate between the different screens.

If you would like more information, or have some ideas about how we can improve it, please drop me a mail at kirsten@ilite.co.za

If your idea is good enought, we’ll use it and give you a copy of the Dashboard free.

All that we would like from you is a little feedback on how the Dashboard is preforming. Things you do like and things you don’t like. Information like the OS you are using, the number of users and courses you have and whether you are using SCORM Activities.

Kirsten

April 28, 2009

Stored Procedures

Filed under: AMFPHP, Flex, General, PHP — ilite @ 9:29 am
Tags: , , , , ,

I am working on a Flex application that needs to call a Stored Procedure using PHP. This proved to be a real challenge, and since I could not find a lot of information on how it was done, I thought that I would post it here. It might not be the best way of doing it, but it works for me.
The code is at the bottom so you can scroll down and skip the next bit out, I would.

For those of you that are still reading… wow! The library application required you to login into it using your domain username. This was passed to the application in the URL (http:\\mylibrary\index.php#username=MyGroup\Sean). When the application loads, it takes the username, passes it to a PHP page on the server that calls the MSSQL Stored Procedure and returns the users details.

The first step for me was to install the correct DLL’s and switch on the MSSQL extension. This proved to be quiet easy on WAMP, but a real pain on XAMPP. For some reason I could not get the extensions to register. My testing server runs WAMP, and the production server runs XAMPP. It was really annoying when it worked on WAMP but not XAMPP. Anyway, the problem was the DLL’s, so if you get a white screen, look there first.

Once that was working, I tested the PHP code, making sure that it returned values correctly. The PHP code is for AMFPHP.  It took a fair bit of testing to get it to work. In hind-site it might have been easier to do it in plain old vanilla PHP, but since the rest of the site is AMFPHP, I stuck to that route.

Part of the problem was the slash (\) in the username, and knowing how to escape it properly.

Once I got the data back from PHP, I moved on to the Flex side. Here the hardest part for me was how to read the URL and how to get the username from it. The code comes straight out of the help file, so for once Copy/Paste was an option.

I know it is not much, but I hope it helps.

Sean

Solution:

Make a few changes to your php.ini file.
allow_call_time_pass_reference = on
extension=php_mssql.dll (enable this extension)
extension=ntwdblib.dll

Place the php_mssql.dll file in the php extensions folder. Mine I placed in the php\ext folder.
Place the ntwdblib.dll file in the Windows\System32 folder

PHP Code to call the Stored Procedure – using AMFPHP:
//login.php
methodTable = array(
“byName” => array(
“description” => “User details by NAME”,
“access” => “remote”,
)
);
}

function byName ($username) {

$myServer = “myserver”;
$myUser = “myUser”;
$myPass = “myPassword”;
$myDB = “myDatabase”;

$s = @mssql_connect($myServer, $myUser, $myPass)
or die(“Couldn’t connect to SQL Server on $myServer”);

$d = @mssql_select_db($myDB, $s)
or die(“Couldn’t open database $myDB”);

//$username = $_GET['username'];

$partA = substr($username, 0,6);
$partB = substr($username, 6);
$username = $partA.”\\”.$partB;

$query = mssql_init(“GetEmployeeDetailsFromUsername”, $s);

mssql_bind($query , “@Username”, $username, SQLVARCHAR, FALSE, FALSE, 57);
mssql_bind($query, “@EmployeeNo”, &$Userno, SQLINT4, TRUE, FALSE);
mssql_bind($query, “@FirstName”, &$First, SQLVARCHAR, TRUE, FALSE, 50);
mssql_bind($query, “@LastName”, &$Last, SQLVARCHAR, TRUE, FALSE, 50);
mssql_bind($query, “@Email”, &$Email, SQLVARCHAR, TRUE, FALSE, 100);

mssql_bind($query, “RETVAL”, &$SQL_Count, SQLINT2);
$result = mssql_execute($query, FALSE);

echo $return = “”.$Userno.”".$First.”".$Last.”".$Email.”\n\r”;

return ($return);

}
}
?>

The code for the Flex file: (I have trimmed the code to only show the bit for the Stored Procedure)

<![CDATA[

import com.LoginUsername;

import mx.managers.BrowserManager;
import mx.managers.IBrowserManager;
import mx.utils.URLUtil;

private var bm:IBrowserManager;

[Bindable]
public var username:String;

private function init(e:Event):void
{
//Get Users
bm = BrowserManager.getInstance();
bm.init(“”, “Library”);

var o:Object = URLUtil.stringToObject(bm.fragment, “#”);
username = o.username;

fullname.text = username;

dispatchEvent(new LoginUsername(username));

}

[Event(name="LoginUsername", name="flash.events.Event")]

//Login.mxml

[Event(name="LoginDetails", name="flash.events.Event")]

//LoginUsername.as
package com
{
import flash.events.Event;

public class LoginUsername extends Event
{
public var uname:String;

public static const LOGINUSERNAME:String = “LoginUsername”;

public function LoginUsername(username:String)
{
super(LOGINUSERNAME, true, true);
uname = username;
}

override public function clone():Event
{
return new LoginUsername(uname);
}

}
}

August 26, 2008

Blog at WordPress.com.