<div class="sf_admin_form_row sf_admin_text tabbed_div">
    <div>
        <span class="inline-label">Теги</span>
        <div class="content">

            <?php


            $tags = Doctrine::getTable('Tag')->findAll();
            $obj = $form->getObject();

            $selected_tag_dirty = $obj->getArticleTags();
            $selected_tag = array();

            foreach($selected_tag_dirty as $tag)
            {
                $selected_tag[] = $tag->getTagId();
            }

            foreach($tags as $tag)
            {
                $dopAttr = '';
                if(in_array($tag->getId(), $selected_tag))
                {
                    $dopAttr = 'checked';
                }

                ?>

                <label><input type="checkbox" name="article_custom[tags][]" value="<?php echo $tag->getId() ?>" <?php echo $dopAttr ?>><?php echo $tag->getTranslation()->ru->title ?></label>
                &nbsp;

                <?php
            }

            ?>

        </div>
    </div>
</div>