2 /************************************************************************/
4 /************************************************************************/
5 /* Copyright (c) 2002-2008 by Greg Gay, Harris Wong */
6 /* Adaptive Technology Resource Centre / University of Toronto */
9 /* This program is free software. You can redistribute it and/or */
10 /* modify it under the terms of the GNU General Public License */
11 /* as published by the Free Software Foundation. */
12 /************************************************************************/
14 define('AT_INCLUDE_PATH', '../../include/');
15 require(AT_INCLUDE_PATH.'vitals.inc.php');
16 require(AT_INCLUDE_PATH.'classes/testQuestions.class.php');
18 authenticate(AT_PRIV_TESTS);
20 $tid = intval($_GET['tid']);
22 /* Retrieve the content_id of this test */
23 $sql = "SELECT title, random, num_questions, instructions FROM ".TABLE_PREFIX."tests WHERE test_id=$tid";
24 $result = mysql_query($sql, $db);
25 if (!($test_row = mysql_fetch_assoc($result))) {
26 $msg->addError('ITEM_NOT_FOUND');
27 header(url_rewrite('tools/tests/index.php', AT_PRETTY_URL_IS_HEADER));
32 test_qti_export($tid, $test_row['title']);