common.inc.php

Constants

SECRETS_FILE

SECRETS_FILE

SCHEMA_FILE

SCHEMA_FILE

MYSQL_PREFIX

MYSQL_PREFIX

Functions

initSecrets()

initSecrets() : \SimpleXMLElement

Initialize a SimpleXMLElement from the SECRETS_FILE

Throws

\CanvasAPIviaLTI_Exception

MISSING_SECRETS_FILE if the SECRETS_FILE cannot be found

\CanvasAPIviaLTI_Exception

INVALID_SECRETS_FILE if the SECRETS_FILE exists, but cannot be parsed

Returns

\SimpleXMLElement

initMySql()

initMySql() : \mysqli

Initialize a mysqli connector using the credentials stored in SECRETS_FILE

Throws

\CanvasAPIviaLTI_Exception

MYSQL_CONNECTION if a mysqli connection cannot be established

Returns

\mysqli —

A valid mysqli connector to the database backing the CanvasAPIviaLTI instance