if ($tax_node) { ?> <h2><?php echo $taxonomy->name; ?> </h2> <?php echo $tax_node->body['und'][0]['safe_value']; $assoc_nodes = taxonomy_select_nodes($taxonomy->tid); if (count($assoc_nodes) > 0) { $pageData = array(); foreach ($assoc_nodes as $this_assoc_node) { $assoc_node = node_load($this_assoc_node); $thisPage = array('nid' => $this_assoc_node, 'created' => $assoc_node->created, 'title' => $assoc_node->title, 'html' => $assoc_node->body['und'][0]['safe_value'], 'weight' => $assoc_node->nodeorder[$taxonomy->tid]['weight']); $thisPage['html'] = parseWistia($thisPage['html'], findWistia($thisPage['html']), $assoc_node); $thisPage['html'] = parseSurvey($thisPage['html'], findSurvey($thisPage['html']), $assoc_node); $thisPage['html'] = parseVideo($thisPage['html'], findVideo($thisPage['html']), $assoc_node); array_push($pageData, $thisPage); } usort($pageData, 'sortAssociatedNodes'); foreach ($pageData as $thisPage) { ?> <h3><?php echo $thisPage['title']; ?> </h3> <?php echo $thisPage['html']; } } }
$comments[$i]["game_id"] = NULL; $comments[$i]["review_id"] = NULL; $comments[$i]["survey_id"] = NULL; $comments[$i]["content"] = $new_comments[$i]; $comments[$i]["genre_id"] = $genres[$i]["genre_id"]; $comments[$i]["feature_id"] = $features[$i]["feature_id"]; insertComment($comments[$i]); } echo "<!-- Link feature with genre -->"; if (checkGenresFeatures($genres[$i]["genre_id"], $features[$i]["feature_id"]) == NULL) { linkGenresFeatures($genres[$i]["genre_id"], $features[$i]["feature_id"]); } } require '../model/surveys.php'; echo "<!-- Mark the survey as parsed -->"; parseSurvey($survey_id); echo "<!-- Send the transaction and unlock the database. -->\n"; $app->commit(); $_SESSION["info"] = "Survey parsed with success."; header('location: /app/admin'); break; // Reviews. // Reviews. case "pending_reviews": require '../model/reviews.php'; $past = "Pending"; $reviews = getUnparsedReviews(); $title = "Comparative Review Pending Reviews"; include '../../view/head.php'; include '../../view/header.php'; include 'content/list_reviews.php';