Вход Регистрация
Файл: adultscript-2.0.3-pro/files/admin/templates/default/photo_album_edit.tpl.php
Строк: 155
<?php defined('_VALID') or die('Restricted Access!'); ?>
    <?php echo $this->fetch('errors'); ?>
    <?php echo $this->fetch('messages'); ?>
    <?php echo $this->fetch('warnings'); ?>
    <script type="text/javascript">
    $(document).ready(function() {
          $("input[name='process_advanced']").click(function() {
              if ($('#edit-advanced').is(':visible')) {
                  $('#edit-advanced').hide();
            } else {
                  $('#edit-advanced').show();
            }
        });
        
        $("img[id^='album-cover-']").click(function() {
              $("input[name='cover']").val($(this).attr('id').match(/album-cover-(.*)/)[1]);
              $("img[id^='album-cover-']").removeClass('active');
              $(this).addClass('active');
        });
    });
    </script>
    <div id="container" class="clearfix">
        <div id="page">
            <?php echo $this->fetch('photo_menu'); ?>
            <div class="content clearfix">
                <?php echo $this->fetch('photo_manage_menu'); ?>
                <?php if ($this->album): ?>
                <form id="album-edit-form" method="post" enctype="multipart/form-data" action="<?php echo ADMIN_URL?>/index.php?q=photo/edit&amp;id=<?php echo $this->album_id?>">
                    <fieldset>
                        <legend>Album Information</legend>
                        <div class="required">
                            <label for="username">Username</label>
                            <input name="username" type="text" id="username" class="medium" maxlength="16" value="<?php echo e($this->album['username']); ?>" />
                        </div>
                        <div class="required">
                              <label for="title">Title:</label>
                            <input name="title" type="text" id="title" class="mega" maxlength="100" value="<?php echo e($this->album['title']); ?>" />
                        </div>
                        <div class="required">
                              <label for="desc">Description:</label>
                            <textarea name="description" id="desc" class="mega"><?php echo e($this->album['description']); ?></textarea>
                        </div>
                        <div class="required">
                              <label for="tags">Tags:</label>
                            <textarea name="tags" id="tags" class="mega"><?php echo e($this->album['tags']); ?></textarea>
                        </div>
                        <div class="required">
                              <label for="category">Category:</label>
                            <div class="categories">
                                  <?php $category explode(','$this->album['categories']); foreach ($this->categories as $cat): ?>
                                  <div class="categ"><input name="categories[]" type="checkbox" value="<?php echo $cat['cat_id']; ?>"<?php if (in_array($cat['cat_id'], $category)): echo ' checked="checked"'; endif; ?><?php echo e($cat['name']); ?></div>
                                  <?php endforeach; ?>
                                  <div class="clear_left"></div>
                            </div>
                        </div>
                        <div class="clear"></div>
                        <div class="required">
                            <label for="type">Broadcast:</label>
                            <select name="type" id="type">
                                <option value="public"<?php if ($this->album['type'] == 'public'): echo ' selected="selected"'; endif; ?>>Public</option>
                                <option value="private"<?php if ($this->album['type'] == 'private'): echo ' selected="selected"'; endif; ?>>Private</option>
                            </select>
                        </div>
                    </fieldset>
                    <fieldset>
                          <legend>Album Properties</legend>
                          <div class="required">
                              <label for="flagged">Flagged:</label>
                            <select name="flagged" id="flagged">
                                <option value="0"<?php if ($this->album['flagged'] == '0'): echo ' selected="selected"'; endif; ?>>No</option>
                                <option value="1"<?php if ($this->album['flagged'] == '1'): echo ' selected="selected"'; endif; ?>>Yes</option>
                            </select>
                          </div>
                          <div class="required">
                              <label for="locked">Locked:</label>
                            <select name="locked" id="locked">
                                <option value="0"<?php if ($this->album['locked'] == '0'): echo ' selected="selected"'; endif; ?>>No</option>
                                <option value="1"<?php if ($this->album['locked'] == '1'): echo ' selected="selected"'; endif; ?>>Yes</option>
                            </select>
                          </div>
                        <div class="required">
                            <label for="status">Status:</label>
                            <select name="status" id="status">
                                <option value="0"<?php if ($this->album['status'] == '0'): echo ' selected="selected"'; endif; ?>>Suspended</option>
                                <option value="1"<?php if ($this->album['status'] == '1'): echo ' selected="selected"'; endif; ?>>Active</option>
                            </select>
                        </div>                        
                    </fieldset>
                    <fieldset>
                        <legend>Album Cover</legend>
                        <div class="required">
                            <input name="cover" type="hidden" id="cover" value="<?php echo $this->album['cover']; ?>" />
                            <table cellspacing="2" cellpadding="0" border="0"><tr><td>
                            <div class="thumbs_small">
                                <?php foreach ($this->photos as $photo): ?>
                                <img src="<?php echo RELATIVE_URL,'/media/photos/thumbs/',$photo['photo_id'],'.jpg'?>" id="album-cover-<?php echo $photo['photo_id']; ?><?php if ($this->album['cover'] == $photo['photo_id']): echo ' class="active"'; endif; ?> alt="" width="83" />
                                <?php endforeach; ?>
                            </div>
                            </td></tr></table>
                        </div>
                    </fieldset>
                    <?php if (VF::cfg_item('module.photo.allow_password') == '1'): ?>
                      <fieldset>
                          <legend>Password Protection</legend>
                          <div class="required">
                              <label for="password">Password</label>
                              <input name="password" type="text" id="password" class="medium" value="" /><?php if ($this->album['password'] != ''): echo ' <i>this album is password protected.</i>'; endif; ?>
                              <span class="help-info">Enter a password to password protect this album. Leave this field empty and the previous password will be used (if already set).</span>
                          </div>
                      </fieldset>
                      <?php endif; ?>
                    <div id="edit-advanced" style="display: none;">
                          <fieldset>
                              <legend>Advanced Properties</legend>
                              <div class="required">
                                  <label for="total_photos">Total Photos</label>
                                  <input name="total_photos" type="text" id="total_photos" class="medium" value="<?php echo $this->album['total_photos']; ?>" />
                              </div>
                              <div class="required">
                                  <label for="total_views">Total Views</label>
                                  <input name="total_views" type="text" id="total_views" class="medium" value="<?php echo $this->album['total_views']; ?>" />
                              </div>
                              <div class="required">
                                  <label for="total_comments">Total Comments</label>
                                  <input name="total_comments" type="text" id="total_comments" class="medium" value="<?php echo $this->album['total_comments']; ?>" />
                              </div>
                              <div class="required">
                                  <label for="total_favorites">Total Favorites</label>
                                  <input name="total_favorites" type="text" id="total_favorites" class="medium" value="<?php echo $this->album['total_favorites']; ?>" />
                              </div>
                              <div class="required">
                                  <label for="rating">Rating</label>
                                  <input name="rating" type="text" id="rating" class="medium" value="<?php echo $this->album['rating']; ?>" />
                              </div>
                              <div class="required">
                                  <label for="rated_by">Rated By</label>
                                  <input name="rated_by" type="text" id="rated_by" class="medium" value="<?php echo $this->album['rated_by']; ?>" />
                              </div>
                          </fieldset>
                          <fieldset>
                              <legend>Date Properties</legend>
                              <div class="required">
                                  <label for="add_date">Add Date</label>
                                  <input name="add_date" type="text" id="add_date" class="medium" value="<?php echo $this->album['add_date']; ?>" />
                              </div>
                              <div class="required">
                                  <label for="view_date">View Date</label>
                                  <input name="view_date" type="text" id="view_date" class="medium" value="<?php echo $this->album['view_date']; ?>" />
                              </div>
                          </fieldset>
                    </div>
                    <div class="submit">
                        <input name="submit-edit" type="submit" id="submit-edit" class="button butDef" value=" Edit Album " />
                        <input name="process_advanced" type="button" id="process_advanced" class="button butDef" value=" Advanced " />
                    </div>
                </form>
                <?php else: ?>
                <div class="none">Invalid album id! Are you sure this album exists!</div>
                <?php endif; ?>
            </div>
        </div>
    </div>
Онлайн: 1
Реклама