Url.php 690 B

123456789101112131415161718192021222324
  1. <?php namespace Place\Api;
  2. use Dever;
  3. use Place\Lib\Core;
  4. use Dever\Helper\Secure;
  5. class Url extends Core
  6. {
  7. public function __construct()
  8. {
  9. }
  10. public function place()
  11. {
  12. $id = Dever::input('id');
  13. $info = Dever::db('info', 'place')->find($id);
  14. if ($info) {
  15. $extend = Dever::load('common', 'manage')->extend();
  16. $param['p'] = Dever::load('util', 'place')->entry($extend['info_id'], $extend['module_id'], $extend['data_id'], $id);
  17. $link = Dever::url('place/data.home', $param);
  18. header('HTTP/1.1 301 Moved Permanently');
  19. header('Location: ' . $link);
  20. }
  21. }
  22. }