예제 #1
0
function EchoInnovationBlockHTML($AMainDivClass = 'middle_right_block')
{
    $sql = "select title, body, img, uri from innovation where id = innovation_GetRandomID();";
    $rec = GetMainConnection()->query($sql)->fetch();
    if (!empty($rec['img'])) {
        echo '<div class="' . $AMainDivClass . '">' . '<div class="newby">' . '<div class="newby_h3">Новшества</div>' . '<a href="' . $rec['uri'] . '">' . '<img src="' . GetFileURLWithFileDate($rec['img']) . '" width="266" height="200">' . '<span class="newby_title">' . $rec['title'] . '</span>' . '<span class="newby_body">' . $rec['body'] . '</span>' . '</a>' . '</div>' . '</div>';
    }
}
예제 #2
0
                    <?php 
if (!empty($ArticleDocuments) && is_array($ArticleDocuments)) {
    echo '<i>Файлы, доступные для загрузки:</i>';
    foreach ($ArticleDocuments as $key => $val) {
        echo '<p><a href="' . URL . $val['FilePath'] . $val['FileName'] . '" target="blank">' . (empty($val['Comment']) ? $val['FileName'] : $val['Comment'] . ' (' . $val['FileName'] . ')') . '</a></p>';
    }
    echo '<br>';
}
?>

                    <?php 
if (!empty($article->AuthorID)) {
    ?>
                        <div class="author_box">
                            <div class="author_ramka"><img src="<?php 
    echo empty($ArticleAuthor['Photo']) ? URL . 'public/images/avatar1.jpg' : GetFileURLWithFileDate($ArticleAuthor['Photo']);
    ?>
" width="128px" height="170px" style="margin: 0px;"/></div>
                            <div class="author_info">
                                Автор: <strong><span itemprop="author" itemscope itemtype="http://schema.org/Person"><span itemprop="name"><?php 
    echo $ArticleAuthor['Name'];
    ?>
</span></span></strong>
                                <p style="margin-top: 10px;"><i><?php 
    echo $ArticleAuthor['ShortDescription'];
    ?>
</i></p>
                            </div>
                            
                            <div class="author_articles">
                                <?php