dokeos-library
[ class tree: dokeos-library ] [ index: dokeos-library ] [ all elements ]

Procedural File: events.lib.inc.php

Source Location: /main/inc/lib/events.lib.inc.php



Page Details:

EVENTS LIBRARY

This is the events library for Dokeos. Include/require it in your code to use its functionality. Functions of this library are used to record informations when some kind of event occur. Each event has his own types of informations then each event use its own function.




Tags:

todo:  convert queries to use Database API
filesource:  Source Code for this file








event_access_course [line 126]

void event_access_course( [tool 0 = name of the tool (name in mainDb.accueil table)])

Record information for access event for courses



Tags:

author:  Sebastien Piraux <piraux_seb@hotmail.com>


Parameters

tool   0   name of the tool (name in mainDb.accueil table)
[ Top ]



event_access_tool [line 201]

void event_access_tool( tool $tool, [ $id_session = 0])

Record information for access event for tools$tool can take this values : Links, Calendar, Document, Announcements, Group, Video, Works, Users, Exercices, Course Desc ... Values can be added if new modules are created (15char max) I encourage to use $nameTool as $tool when calling this functionFunctionality for "what's new" notification is added by Toon Van Hoecke



Tags:

author:  Sebastien Piraux <piraux_seb@hotmail.com>


Parameters

tool   $tool   name of the tool (name in mainDb.accueil table)
   $id_session  
[ Top ]



event_download [line 277]

void event_download( doc_id $doc_url)

Record information for download event (when an user click to d/l a document) it will be used in a redirection page bug fixed: Roan Embrechts Roan: The user id is put in single quotes, (why? perhaps to prevent sql insertion hacks?) and later again. Doing this twice causes an error, I remove one of them.



Tags:

author:  Sebastien Piraux <piraux_seb@hotmail.com>


Parameters

doc_id   $doc_url   id of document (id in mainDb.document table)
[ Top ]



event_exercice [line 422]

void event_exercice( exo_id $exo_id, result $score, weighting $weighting)

Record result of user when an exercice was done



Tags:

author:  Sebastien Piraux <piraux_seb@hotmail.com>


Parameters

exo_id   $exo_id   ( id in courseDb exercices table )
result   $score   ( score @ exercice )
weighting   $weighting   ( higher score )
[ Top ]



event_link [line 373]

void event_link( link_id $link_id)

Record information for link event (when an user click on an added link) it will be used in a redirection page



Tags:

author:  Sebastien Piraux <piraux_seb@hotmail.com>


Parameters

link_id   $link_id   (id in coursDb liens table)
[ Top ]



event_login [line 93]

void event_login( )

Record information for login event (when an user identifies himself with username & password)



Tags:

author:  Sebastien Piraux <piraux_seb@hotmail.com>


[ Top ]



event_open [line 44]

void event_open( )

Record information for open event (when homepage is opened)



Tags:

author:  Sebastien Piraux <piraux_seb@hotmail.com>


[ Top ]



event_system [line 530]

void event_system( string $event_type, string $event_value_type, string $event_value, [string $timestamp = null], [integer $user_id = null], [string $course_code = null])

Record information for common (or admin) events (in the track_e_default table)



Tags:

author:  Yannick Warnier <yannick.warnier@dokeos.com>


Parameters

string   $event_type   Type of event
string   $event_value_type   Type of value
string   $event_value   Value
string   $timestamp   Timestamp (defaults to null)
integer   $user_id   User ID (defaults to null)
string   $course_code   Course code (defaults to null)
[ Top ]



event_upload [line 326]

void event_upload( doc_id $doc_id)

Record information for upload event used in the works tool to record informations when an user upload 1 work



Tags:

author:  Sebastien Piraux <piraux_seb@hotmail.com>


Parameters

doc_id   $doc_id   id of document (id in mainDb.document table)
[ Top ]



exercise_attempt [line 474]

boolean exercise_attempt( float $score, string $answer, integer $quesId, integer $exeId, integer $j)

Record an event for this attempt at answering an exercise



Tags:

return:  Result of the insert query


Parameters

float   $score   Score achieved
string   $answer   Answer given
integer   $quesId   Question ID
integer   $exeId   Exercise ID
integer   $j   Position
[ Top ]



Documentation generated on Thu, 12 Jun 2008 13:23:42 -0500 by phpDocumentor 1.4.1