show_pics.php 1.0 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647
  1. <?php
  2. /**
  3. * 显示图片
  4. *
  5. *
  6. *
  7. ***/
  8. defined('InShopNC') or exit('Access Invalid!');
  9. class show_picsControl extends SystemControl {
  10. public function __construct() {
  11. parent::__construct();
  12. }
  13. public function indexOp(){
  14. $type = trim($_GET['type']);
  15. if(empty($_GET['pics'])) {
  16. $this->goto_index();
  17. }
  18. $pics = explode('|',trim($_GET['pics']));
  19. $pic_path = '';
  20. switch ($type) {
  21. case 'inform':
  22. $pic_path = UPLOAD_SITE_URL.'/shop/inform/';
  23. break;
  24. case 'complain':
  25. $pic_path = UPLOAD_SITE_URL.'/shop/complain/';
  26. break;
  27. default:
  28. $this->goto_index();
  29. break;
  30. }
  31. Tpl::output('pic_path',$pic_path);
  32. Tpl::output('pics',$pics);
  33. //输出页面
  34. Tpl::showpage('show_pics','blank_layout');
  35. }
  36. private function goto_index() {
  37. @header("Location: index.php");
  38. exit;
  39. }
  40. }