Skip to content
Code-Schnipsel Gruppen Projekte
SideBox2.html 1,65 KiB
Newer Older
  • Learn to ignore specific revisions
  • Henning Leutz's avatar
    Henning Leutz committed
    
    <div class="{$this->getAttribute('grid-class-row')}">
        {if $this->getAttribute('content')}
        <div class="quiqqer-bricks-sidebox2-content">
            {$this->getAttribute('content')}
        </div>
        {/if}
    </div>
    
    <div class="{$this->getAttribute('grid-class-row')}">
    
    {foreach from=$children item=Child key=key}
        <article class="{$this->getAttribute('grid-class-article')} quiqqer-bricks-sidebox-article">
            {if $this->getAttribute( 'showImage' )}
            <a href="{url site=$Child}" class="image">
                {image src=$Child->getAttribute('image_site') width=640}
            </a>
            {/if}
    
            {if $this->getAttribute( 'showTitle' ) || $this->getAttribute( 'showShort' )}
            <header>
                {if $this->getAttribute( 'showTitle' )}
                <h3>
                    <a href="{url site=$Child}">
                        {$Child->getAttribute('title')}
                    </a>
                </h3>
                {/if}
            </header>
            {/if}
    
            {if $this->getAttribute( 'showShort' )}
            <p>
                {text_passage text=$Child->getAttribute('short') start=0 end=120 striphtml=true append="..."}
            </p>
            {/if}
    
            {if $this->getAttribute( 'showContent' )}
                {$Child->getAttribute('content')}
            {/if}
    
            <footer class="article-button">
                <a href="{url site=$Child}" class="button">
                    {locale group="quiqqer/bricks" var="continue.reading"}
                </a>
            </footer>
        </article>
    
        {assign var=modKey value=$key+1}
        {if $modKey && $modKey % 2 === 0 && $Child@last}
            </div>
            <div class="{$this->getAttribute('grid-class-row')}">
        {/if}
        {/foreach}
    </div>