<?php

use_helper('MyForm');
$params = array();
$params_fields = array('main' => 'topo_filter', 'outings' => 'outing_filter', 'images' => 'image_filter', 'videos' => 'video_filter', 'articles' => 'article_filter');
foreach ($params_fields as $key => $field) {
    $value = $document->getRaw($field);
    if (!empty($value)) {
        $params[$key] = str_replace('+', ' ', $value);
    }
}
echo form_tag('documents/portalredirect', array('method' => 'get', 'class' => 'search'));
echo '<div class="sbox">';
echo portal_search_box_tag($params, 'portals');
echo '</div></form>';
Example #2
0
$is_not_merged = !$document->get('redirects_to');
$mobile_version = c2cTools::mobileVersion();
$show_link_to_delete = $is_not_archive && $is_not_merged && $is_moderator && !$mobile_version;
$show_link_tool = $is_not_archive && $is_not_merged && $is_connected && !$mobile_version;
display_page_header('areas', $document, $id, $metadata, $current_version, array('nb_comments' => $nb_comments));
// lang-independent content starts here
echo start_section_tag('Information', 'data');
include_partial('data', array('document' => $document));
if ($is_not_archive) {
    echo '<div class="all_associations">';
    $associated_areas = array(array('id' => $id, 'name' => $document->getRaw('name')));
    include_partial('areas/association', array('associated_docs' => $associated_areas, 'module' => 'areas', 'areas' => false, 'weather' => true, 'avalanche_bulletin' => true));
    echo '</div>';
    echo form_tag('documents/portalredirect', array('method' => 'get', 'class' => 'search'));
    echo '<div class="sbox">';
    echo portal_search_box_tag('areas/' . $id, 'areas');
    echo '</div></form>';
}
echo end_section_tag();
// lang-dependent content
echo start_section_tag('Description', 'description');
include_partial('documents/i18n_section', array('document' => $document, 'languages' => $sf_data->getRaw('languages'), 'needs_translation' => $needs_translation, 'images' => $associated_images));
echo end_section_tag();
include_partial($mobile_version ? 'documents/mobile_map_section' : 'documents/map_section', array('document' => $document));
if ($is_not_archive && $is_not_merged) {
    echo start_section_tag('Linked documents', 'associated_docs');
    ?>
    <div class="col_left col_50">
    <ul class="children_lists">
        <?php 
    $module_list = array('summits', 'routes', 'huts', 'parkings', 'PT access points', 'sites', 'climbing_gym', 'maps', 'books');