コード例 #1
0
ファイル: Action.php プロジェクト: duxiangfei/plugins
 /**
  * 更新相册图片
  *
  * @access public
  * @return void
  */
 public function updategallery()
 {
     if (HighSlide_Plugin::form('update')->validate()) {
         $this->response->goBack();
     }
     $gallery = $this->request->from('gid', 'thumb', 'image', 'description', 'sort', 'name');
     $this->db->query($this->db->update($this->prefix . 'gallery')->rows($gallery)->where('gid=?', $gallery['gid']));
     //返回原页并提示信息
     $this->widget('Widget_Notice')->highlight('gallery-' . $gallery['gid']);
     $this->widget('Widget_Notice')->set(_t('相册组%s: 图片%s 更新成功', $gallery['sort'], $gallery['name']), NULL, 'success');
     $this->response->redirect(Typecho_Common::url('extending.php?panel=HighSlide%2Fmanage-gallery.php&group=' . $gallery['sort'], $this->options->adminUrl));
 }
コード例 #2
0
ファイル: manage-gallery.php プロジェクト: duxiangfei/plugins
        ?>
</div>
							<ul id="file-list"></ul>
						</div>
					</div>

					<div id="tab-forms"><?php 
        HighSlide_Plugin::form()->render();
        ?>
</div>
				<?php 
    } else {
        ?>
					<div id="tab-settings" class="typecho-content-panel">
						<?php 
        HighSlide_Plugin::form('sync', '2')->render();
        ?>
					</div><!-- end #tab-advance -->
				<?php 
    }
    ?>

			</div>

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

<?php 
    include 'copyright.php';
    include 'common-js.php';