showSuccess.php 3.14 KB
Newer Older
Яков's avatar
first  
Яков committed
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
<div class="content__main">
    <?php
    $translation = $article->getTranslation();
    slot('title', $translation[$culture]['title']);
    include_partial('main/breadcrumbs');
    echo '<h1 class="content_title">' . $translation[$culture]['title'] . '</h1>';
    ?>
    <div class="article_wrap">
        <div class="max_width_small">
            <?php
            $image = '/u/i/' . Page::replaceImageSize($article['cover'], 'M');
            if (file_exists(sfConfig::get('sf_web_dir') . $image)) {
                $size = getimagesize(sfConfig::get('sf_web_dir') . $image);
                echo '<img ' . $size[3] . ' src="/u/i/' . Page::replaceImageSize($article['cover'], 'M') . '" />';
                echo '<i class="br30"></i>';
            }
            echo '<div class="ftext pages">'. $article->getBody(ESC_RAW) .'</div>';

            echo '<div style="position: relative">';
            $counter = 0;
            foreach ($tags_art as $tag)
            {
                if ($counter == 7)
                {
                    break;
                }
                $counter++;
                echo '<a href="/'.$culture.'/article/?tag_id='.$tag['id'].'" class="art_tags">' . $tag['Translation'][$culture]['title'] . '</a>';
            }
            echo '</div>';

            if ($article_prev || $article_next) {
                ?>
                <table class="article_wrap_arrows" cellspacing="0" cellpadding="0" width="100%">
                    <tbody valign="middle">
                    <tr>
                        <?php
                        echo '<td class="article_wrap_arrows_left" align="left" width="50%" height="70">';
                        if ($article_prev) {
                            echo '<a href="' . url_for('@article_show?alias=' . $article_prev['alias']) . '" class="green_link"><span>' . $article_prev['Translation'][$culture]['title'] . '</span>';
                            echo '<div class="article_wrap_arrows_left__icon"></div>';
                            echo '</a>';
                        }
                        echo '</td><td class="article_wrap_arrows_right" align="right" width="50%" height="70">';
                        if ($article_next) {
                            echo '<a href="' . url_for('@article_show?alias=' . $article_next['alias']) . '" class="green_link"><span>' . $article_next['Translation'][$culture]['title'] . '</span>';
                            echo '<div class="article_wrap_arrows_right__icon"></div>';
                            echo '</a>';
                        }
                        echo '</td>';
                        ?>
                    </tr>
                    </tbody>
                </table>
                <?php
            }
            ?>
        </div>
    </div>
    <?php
    /*
      <div class="article_section">
        <div class="max-width">
            <div class="caption">Вам будут интересны эти товары</div>
            <i class="br20"></i>
            <div class="lending_product_area product_card_wrap">
                <?php include_partial("product/product", array("count" => 4)); ?>
            </div>
        </div>
    </div>
    */
    ?>
</div>