国内流行的内容管理系统(CMS)多端全媒体解决方案 https://www.dedebiz.com
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

45 lines
2.0KB

  1. <?php
  2. /**
  3. * 会员面板
  4. *
  5. * @version $id:login.php 8:38 2010年7月9日 tianya $
  6. * @package DedeBIZ.User
  7. * @copyright Copyright (c) 2022 DedeBIZ.COM
  8. * @license https://www.dedebiz.com/license
  9. * @link https://www.dedebiz.com
  10. */
  11. require_once(dirname(__FILE__)."/config.php");
  12. $uid = empty($uid) ? "" : RemoveXSS($uid);
  13. if (empty($action)) $action = '';
  14. if (empty($aid)) $aid = '';
  15. $menutype = 'mydede';
  16. if ($uid == '') {
  17. $iscontrol = 'yes';
  18. if (!$cfg_ml->IsLogin()) {
  19. include_once(dirname(__FILE__)."/templets/index-notlogin.htm");
  20. } else {
  21. $minfos = $dsql->GetOne("SELECT * FROM `#@__member_tj` WHERE mid='".$cfg_ml->M_ID."'; ");
  22. $minfos['totaluse'] = $cfg_ml->GetUserSpace();
  23. $minfos['totaluse'] = number_format($minfos['totaluse'] / 1024 / 1024, 2);
  24. if ($cfg_mb_max > 0) {
  25. $ddsize = ceil(($minfos['totaluse'] / $cfg_mb_max) * 100);
  26. } else {
  27. $ddsize = 0;
  28. }
  29. require_once(DEDEINC.'/channelunit.func.php');
  30. //最新文档20条
  31. $archives = array();
  32. $sql = "SELECT arc.*, category.namerule, category.typedir, category.moresite, category.siteurl, category.sitepath, mem.userid FROM `#@__archives` arc LEFT JOIN `#@__arctype` category ON category.id=arc.typeid LEFT JOIN `#@__member` mem ON mem.mid=arc.mid WHERE arc.arcrank > -1 ORDER BY arc.sortrank DESC LIMIT 20";
  33. $dsql->SetQuery($sql);
  34. $dsql->Execute();
  35. while ($row = $dsql->GetArray()) {
  36. $row['htmlurl'] = GetFileUrl($row['id'], $row['typeid'], $row['senddate'], $row['title'], $row['ismake'], $row['arcrank'], $row['namerule'], $row['typedir'], $row['money'], $row['filename'], $row['moresite'], $row['siteurl'], $row['sitepath']);
  37. $archives[] = $row;
  38. }
  39. $dpl = new DedeTemplate();
  40. $tpl = dirname(__FILE__)."/templets/index.htm";
  41. $dpl->LoadTemplate($tpl);
  42. $dpl->display();
  43. }
  44. }
  45. ?>