--- branches/paul/admin/include/subject_builder.php 2004/03/18 19:24:54 67 +++ branches/paul_xx/admin/include/subject_builder.php 2004/03/18 20:01:09 69 @@ -44,15 +44,15 @@ . " AND othersub_id = " . $subject_id_array[$subscript]; - $rs = mysql_tryquery($sql); - if (mysql_num_rows($rs) == 0) { + $rs = xx_tryquery($sql); + if (xx_num_rows($rs) == 0) { $sql = "INSERT INTO sub_othersub (subject_id, othersub_id) VALUES (" . $subject_id . ", " . $subject_id_array[$subscript] . ")"; - mysql_tryquery($sql); + xx_tryquery($sql); } // other subject not already assigned @@ -83,15 +83,15 @@ . " AND page_id = " . $page_id_array[$subscript]; - $rs = mysql_tryquery($sql); - if (mysql_num_rows($rs) == 0) { + $rs = xx_tryquery($sql); + if (xx_num_rows($rs) == 0) { $sql = "INSERT INTO sub_page (subject_id, page_id) VALUES (" . $subject_id . ", " . $page_id_array[$subscript] . ")"; - mysql_tryquery($sql); + xx_tryquery($sql); } // page not already assigned @@ -120,7 +120,7 @@ . $resource_id . " AND subject_id = " . $subject_id . " AND infotype_id = " . $infotype_id; - mysql_tryquery($sql); + xx_tryquery($sql); header("Location: subject_builder.phtml?subject_id=" . $subject_id); @@ -146,7 +146,7 @@ . $subject_id . " AND othersub_id = " . $key_list_array[$element]; - mysql_tryquery($sql); + xx_tryquery($sql); } header("Location: subject_builder.phtml?subject_id=" . $subject_id); @@ -172,7 +172,7 @@ . $subject_id . " AND page_id = " . $key_list_array[$element]; - mysql_tryquery($sql); + xx_tryquery($sql); } header("Location: subject_builder.phtml?subject_id=" . $subject_id); @@ -204,8 +204,8 @@ // Find the default information type for this resource $sql = "SELECT infotype_id FROM resource WHERE resource_id = " . $resource_id; - $rs = mysql_tryquery($sql); - $row = mysql_fetch_array ($rs, MYSQL_ASSOC); + $rs = xx_tryquery($sql); + $row = xx_fetch_array ($rs, xx_ASSOC); $infotype_id = $row["infotype_id"]; // Check to see if it's already there. @@ -241,7 +241,7 @@ . ", " . $highlighted . ")"; - mysql_tryquery($sql); + xx_tryquery($sql); } @@ -264,7 +264,7 @@ $sql = "UPDATE subject SET rqs_published = '1' WHERE subject_id = " . $subject_id; - mysql_tryquery($sql); + xx_tryquery($sql); header("Location: subject_builder.phtml?subject_id=" . $subject_id); } @@ -282,7 +282,7 @@ $sql = "UPDATE subject SET rqs_published = '0' WHERE subject_id = " . $subject_id; - mysql_tryquery($sql); + xx_tryquery($sql); header("Location: subject_builder.phtml?subject_id=" . $subject_id); } @@ -302,7 +302,7 @@ . $sess_staff_account . "' WHERE subject_id = " . $subject_id; - mysql_tryquery($sql); + xx_tryquery($sql); } @@ -332,7 +332,7 @@ . " OR infotype_id = " . $infotype_id . ")"; - mysql_tryquery($sql); + xx_tryquery($sql); // If the user opted for default resource description, void out the incoming $description; if ($descr_default == 1) $description = ""; @@ -360,7 +360,7 @@ . "', '" . $description . "')"; - mysql_tryquery($sql); + xx_tryquery($sql); header("Location: subject_builder.phtml?subject_id=" . $subject_id . "#" . $resource_id); }