Beispiel #1
0
        <?php 
echo Studip\Button::create(_('Abstimmen'), 'vote', array('value' => $vote->id));
?>
    <? endif ?>
    <?php 
echo Studip\LinkButton::create(_('Ergebnisse'), ContentBoxHelper::href($vote->id, array('preview[]' => $vote->id)));
?>
<? else: ?>
    <?php 
echo Studip\LinkButton::create(_('Ergebnisse ausblenden'), ContentBoxHelper::href($vote->id, array('preview' => 0)));
?>
    <?php 
echo Request::get('sort') ? Studip\LinkButton::create(_('Nicht sortieren'), ContentBoxHelper::href($vote->id, array('preview[]' => $vote->id, 'sort' => 0))) : Studip\LinkButton::create(_('Sortieren'), ContentBoxHelper::href($vote->id, array('preview[]' => $vote->id, 'sort' => 1)));
?>
    <? if ($vote->changeable && $vote->state == 'active' && !$nobody): ?>
        <?php 
echo Studip\LinkButton::create(_('Antwort ändern'), ContentBoxHelper::href($vote->id, array('change' => 1)));
?>
    <? endif; ?>
    <? if (!$vote->anonymous && ($admin || $vote->namesvisibility)): ?>
        <? if (Request::get('revealNames') === $vote->id) : ?>
            <?php 
echo Studip\LinkButton::create(_('Namen ausblenden'), ContentBoxHelper::href($vote->id, array('revealNames' => null)));
?>
        <? else : ?>
            <?php 
echo Studip\LinkButton::create(_('Namen zeigen'), ContentBoxHelper::href($vote->id, array('revealNames' => $vote->id)));
?>
        <? endif; ?>
    <? endif; ?>
<? endif; ?>
Beispiel #2
0
echo $semester_id;
?>
" class="<?php 
echo count($single_dates) === 1 ? 'open' : ContentBoxHelper::classes('singledate-' . $semester_id);
?>
">
            <header>
                <h1>
                    <input type="checkbox" class="date-proxy"
                           data-proxyfor="#singledate-<?php 
echo $semester_id;
?>
 .ids-irregular"
                           data-activates=".actionForAllIrregular">
                    <a href="<?php 
echo ContentBoxHelper::href('singledate-' . $semester_id);
?>
">
                        <?php 
echo htmlReady(Semester::find($semester_id)->name);
?>
                    </a>
                </h1>
                <nav>
                    <span>
                        <?php 
echo sprintf(ngettext('%u Termin', '%u Termine', count($termine)), count($termine));
?>
                    </span>
                    <span>
                        <?php 
Beispiel #3
0
echo CSRFProtection::tokenTag();
?>
                    <input type="hidden" name="comsubmit" value="<?php 
echo $new['news_id'];
?>
">
                    <div align="center">
                        <textarea class="add_toolbar wysiwyg" name="comment_content" style="width:70%" rows="8" cols="38" wrap="virtual" placeholder="<?php 
echo _('Geben Sie hier Ihren Kommentar ein!');
?>
"></textarea>
                        <br>
                        <?php 
echo Studip\Button::createAccept(_('Absenden'));
?>
                    </div>
                </form>
            <? endif ?>
        <? else: ?>
        <a href="<?php 
echo ContentBoxHelper::href($new['news_id'], array("comments" => 1));
?>
">
                <?php 
echo sprintf(_('Kommentare lesen (%s) / Kommentar schreiben'), StudipComment::NumCommentsForObject($new['news_id']));
?>
            </a>
        <? endif; ?>
    </footer>
<? endif; ?>
Beispiel #4
0
<article class="<?php 
echo ContentBoxHelper::classes($termin['id']);
?>
" id="<?php 
echo $termin['id'];
?>
">
    <header>
        <h1>
            <a href="<?php 
echo ContentBoxHelper::href($termin['id']);
?>
">
                <?php 
echo Icon::create('date', 'inactive')->asImg(['class' => 'text-bottom']);
?>
                <?php 
echo htmlReady($termin['title']);
?>
            </a>
        </h1>
        <nav>
            <span>
                <?php 
echo $termin['room'] ? _('Raum') . ': ' . htmlReady($termin['room']) : '';
?>
            </span>
            <? if($admin && $isProfile && $termin['type'] === 'CalendarEvent'): ?>
            <a href="<?php 
echo URLHelper::getLink('dispatch.php/calendar/single/edit/' . $termin['range_id'] . '/' . $termin['event_id'], array('source_page' => 'dispatch.php/profile'));
?>
Beispiel #5
0
    <? $is_new = ($new['chdate'] >= object_get_visit($new->id, 'news', false, false))
            && ($new['user_id'] != $GLOBALS['user']->id); ?>
    <article class="<?php 
echo ContentBoxHelper::classes($new->id, $is_new);
?>
" id="<?php 
echo $new->id;
?>
" data-visiturl="<?php 
echo URLHelper::getScriptLink('dispatch.php/news/visit');
?>
">
        <header>
            <h1>
                <a href="<?php 
echo ContentBoxHelper::href($new->id, array('contentbox_type' => 'news'));
?>
">
                    <?php 
echo Icon::create('news', 'clickable')->asImg();
?>
                    <?php 
echo htmlReady($new['topic']);
?>
                </a>
            </h1>
            <nav>
                <?php 
echo $this->render_partial('news/_actions.php', array('new' => $new, 'range' => $range));
?>
            </nav>
Beispiel #6
0
                    <h1>
                    <? if ($info = $course->getBookedRoomsTooltip($metadate_id)) : ?>
                        <?php 
echo tooltipIcon($info);
?>
                    <? elseif ($course->getCycleColorClass($metadate_id) === 'red'): ?>
                        <?php 
echo tooltipIcon(_('Keine Raumbuchungen vorhanden'));
?>
                    <? else: ?>
                        <?php 
echo tooltipIcon(_('Keine offenen Raumbuchungen'));
?>
                    <? endif; ?>
                        <a href="<?php 
echo ContentBoxHelper::href($metadate_id);
?>
">
                            <?php 
echo htmlReady($cycle['cycle']->toString('long'));
?>
                        </a>
                    </h1>
                    <nav>
                        <span>
                            <?php 
echo _('Raum');
?>
:
                        <? if (count($cycle['room_request']) > 0): ?>
                            <?php 
Beispiel #7
0
<?php

echo $GLOBALS['vote_message'][$vote->id];
?>
<? $show_result = $controller->showResult($vote) ?>
<? $maxvotes = $vote->maxvotes ?>
<section>
    <div>
        <?php 
echo formatReady($vote->question);
?>
    </div>
    <form action="<?php 
echo ContentBoxHelper::href($vote->id);
?>
" method="post">
        <section class="answers">
            <? foreach (Request::get('sort') ? $vote->answers->orderBy("count desc", SORT_NUMERIC) : $vote->answers->orderBy("position", SORT_NUMERIC) as $answer): ?>
                <div class="answer">
                    <? if ($show_result): ?>
                        <div class="bar">
                            <div class="percent">
                                <?php 
echo htmlReady($vote->count ? round($answer->count * 100 / $vote->count) : 0);
?>
%
                            </div>
                            <? $width = $maxvotes ? $answer->count / $maxvotes : 0; ?>
                            <div style="display: inline-block;
                                border:1px solid black;
                                width: <?php