Skip to content
wiki.fftac.org

Template Research - Source Excerpt 02

Back to Template Research

Summary

This source excerpt preserves a bounded section of Anti-Christ.org/wp-content/themes/antichrist-engine/template-research.php so readers can inspect the evidence without opening the full source file.

**Source path:** Anti-Christ.org/wp-content/themes/antichrist-engine/template-research.php

$is_visible       = $matches_category && $matches_query;

    $projection_visibility[$projection_index] = $is_visible;

    if ($is_visible) {
        $projection_visible_count++;
    }
}

foreach (($network_map['source_hubs'] ?? array()) as $source_index => $source_hub) {
    $lane_slugs = array_values(array_filter(array_map('strval', (array) ($source_hub['lane_slugs'] ?? array()))));
    $normalized_search = antichrist_engine_foundation_normalize_search_text(implode(' ', array_filter(array(
        (string) ($source_hub['record_id'] ?? ''),
        (string) ($source_hub['title'] ?? ''),
        (string) ($source_hub['publisher'] ?? ''),
        implode(' ', (array) ($source_hub['lane_labels'] ?? array())),
        implode(' ', array_map(static function ($claim_reference) {
            return (string) ($claim_reference['record_id'] ?? '');
        }, (array) ($source_hub['claim_references'] ?? array()))),
    ))));
    $matches_kind     = 'all' === $research_filters['map_kind'] || 'source' === $research_filters['map_kind'];
    $matches_category = 'all' === $research_filters['map_category'] || in_array($research_filters['map_category'], $lane_slugs, true);
    $matches_query    = '' === $network_query || false !== strpos($normalized_search, $network_query);
    $is_visible       = $matches_kind && $matches_category && $matches_query;

    $network_source_search_indices[$source_index] = $normalized_search;
    $network_source_visibility[$source_index] = $is_visible;

    if ($is_visible) {
        $network_visible_count++;
    }
}

foreach (($network_map['claim_bridges'] ?? array()) as $bridge_index => $bridge) {
    $lane_slugs = array_values(array_filter(array_map('strval', (array) ($bridge['lane_slugs'] ?? array()))));
    $normalized_search = (string) ($bridge['searchable'] ?? antichrist_engine_foundation_normalize_search_text(implode(' ', array_filter(array(
        (string) ($bridge['primary_record_id'] ?? ''),
        (string) ($bridge['primary_title'] ?? ''),
        (string) ($bridge['secondary_record_id'] ?? ''),
        (string) ($bridge['secondary_title'] ?? ''),
        implode(' ', (array) ($bridge['shared_terms'] ?? array())),
    )))));
    $matches_kind     = 'all' === $research_filters['map_kind'] || 'bridge' === $research_filters['map_kind'];
    $matches_category = 'all' === $research_filters['map_category'] || in_array($research_filters['map_category'], $lane_slugs, true);
    $matches_query    = '' === $network_query || false !== strpos($normalized_search, $network_query);
    $is_visible       = $matches_kind && $matches_category && $matches_query;

    $network_bridge_search_indices[$bridge_index] = $normalized_search;
    $network_bridge_visibility[$bridge_index] = $is_visible;

    if ($is_visible) {
        $network_visible_count++;
    }
}

foreach (($network_map['claim_lanes'] ?? array()) as $lane_index => $lane) {
    $lane_slug = (string) ($lane['slug'] ?? '');
    $normalized_search = antichrist_engine_foundation_normalize_search_text(implode(' ', array_filter(array(
        $lane_slug,
        (string) ($lane['label'] ?? ''),
        implode(' ', array_map(static function ($claim_reference) {
            return trim((string) ($claim_reference['record_id'] ?? '') . ' ' . (string) ($claim_reference['title'] ?? ''));
        }, (array) ($lane['top_claims'] ?? array()))),
        implode(' ', array_map(static function ($source_reference) {
            return trim((string) ($source_reference['record_id'] ?? '') . ' ' . (string) ($source_reference['title'] ?? ''));
        }, (array) ($lane['top_sources'] ?? array()))),
    ))));
    $matches_kind     = 'all' === $research_filters['map_kind'] || 'lane' === $research_filters['map_kind'];
    $matches_category = 'all' === $research_filters['map_category'] || $research_filters['map_category'] === $lane_slug;
    $matches_query    = '' === $network_query || false !== strpos($normalized_search, $network_query);
    $is_visible       = $matches_kind && $matches_category && $matches_query;

    $network_lane_search_indices[$lane_index] = $normalized_search;
    $network_lane_visibility[$lane_index] = $is_visible;

    if ($is_visible) {
        $network_visible_count++;
    }
}

if ('all' !== $research_filters['timeline_category']) {
    $timeline_filter_label = $timeline_labels[$research_filters['timeline_category']] ?? ucwords(str_replace('-', ' ', $research_filters['timeline_category']));
}

if ('all' !== $research_filters['claim_category']) {
    $claim_filter_label = $claim_labels[$research_filters['claim_category']] ?? ucwords(str_replace('-', ' ', $research_filters['claim_category']));
}

if ('all' !== $research_filters['claim_verdict']) {
    $claim_verdict_label = $verdicts[$research_filters['claim_verdict']]['label'] ?? ucwords(str_replace('-', ' ', $research_filters['claim_verdict']));
}

if ('all' !== $research_filters['projection_category']) {
    $projection_filter_label = $claim_labels[$research_filters['projection_category']] ?? ucwords(str_replace('-', ' ', $research_filters['projection_category']));
}

if ('all' !== $research_filters['map_kind']) {
    $network_kind_label = $network_kind_filters[$research_filters['map_kind']] ?? ucwords(str_replace('-', ' ', $research_filters['map_kind']));
}

if ('all' !== $research_filters['map_category']) {
    $network_category_label = $claim_labels[$research_filters['map_category']] ?? ucwords(str_replace('-', ' ', $research_filters['map_category']));
}

$timeline_summary = sprintf(
    __('Showing %1$s of %2$s timeline entries.', 'antichrist-engine'),
    number_format_i18n($timeline_visible_count),
    number_format_i18n($timeline_total)
);

if ($timeline_filter_label) {
    $timeline_summary .= ' ' . sprintf(__('Active lane: %s.', 'antichrist-engine'), $timeline_filter_label);
}

$claim_summary = sprintf(
    __('Showing %1$s of %2$s claim dossiers.', 'antichrist-engine'),
    number_format_i18n($claim_visible_count),
    number_format_i18n($claim_total)
);

if ($claim_filter_label) {
    $claim_summary .= ' ' . sprintf(__('Lane: %s.', 'antichrist-engine'), $claim_filter_label);
}

if ($claim_verdict_label) {
    $claim_summary .= ' ' . sprintf(__('Verdict: %s.', 'antichrist-engine'), $claim_verdict_label);
}

if (!empty($research_filters['claim_q'])) {
    $claim_summary .= ' ' . sprintf(__('Query: "%s".', 'antichrist-engine'), $research_filters['claim_q']);
}

$projection_summary = sprintf(
    __('Showing %1$s of %2$s projection ledger entries.', 'antichrist-engine'),
    number_format_i18n($projection_visible_count),
    number_format_i18n($projection_total)
);

if ($projection_filter_label) {
    $projection_summary .= ' ' . sprintf(__('Lane: %s.', 'antichrist-engine'), $projection_filter_label);
}

if (!empty($research_filters['projection_q'])) {
    $projection_summary .= ' ' . sprintf(__('Query: "%s".', 'antichrist-engine'), $research_filters['projection_q']);
}

$network_summary = sprintf(
    __('Showing %1$s of %2$s research-network items.', 'antichrist-engine'),
    number_format_i18n($network_visible_count),
    number_format_i18n($network_total)
);

if ($network_kind_label) {
    $network_summary .= ' ' . sprintf(__('Type: %s.', 'antichrist-engine'), $network_kind_label);
}

if ($network_category_label) {
    $network_summary .= ' ' . sprintf(__('Lane: %s.', 'antichrist-engine'), $network_category_label);
}

if (!empty($research_filters['map_q'])) {
    $network_summary .= ' ' . sprintf(__('Query: "%s".', 'antichrist-engine'), $research_filters['map_q']);
}
?>
<section class="hero hero--foundation">
    <div class="container hero__grid hero__grid--foundation">
        <div class="hero__content">
            <p class="eyebrow"><?php esc_html_e('Research Program', 'antichrist-engine'); ?></p>
            <h1><?php the_title(); ?></h1>
            <p class="hero__lead"><?php esc_html_e('A comparative research atlas for historical identifications, recurring prophecy claims, contemporary systems, and life after fear-based certainty.', 'antichrist-engine'); ?></p>
            <p><?php esc_html_e('Use the briefings, frameworks, timeline, and claim index to move from panic narratives toward evidence, context, and proportion.', 'antichrist-engine'); ?></p>
            <ul class="hero__meta" aria-label="<?php esc_attr_e('Research program profile', 'antichrist-engine'); ?>">
                <li>
                    <span><?php esc_html_e('Classification', 'antichrist-engine'); ?></span>
                    <strong><?php echo esc_html($document_profile['classification']); ?></strong>
                </li>
                <li>
                    <span><?php esc_html_e('Dossiers', 'antichrist-engine'); ?></span>
                    <strong><?php echo esc_html(number_format_i18n(count($claims))); ?></strong>