国内流行的内容管理系统(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.

43 lines
2.0KB

  1. <?php
  2. /**
  3. * @version $id:index.php 8:24 2010年7月9日 tianya $
  4. * @package DedeBIZ.User
  5. * @copyright Copyright (c) 2022 DedeBIZ.COM
  6. * @license https://www.dedebiz.com/license
  7. * @link https://www.dedebiz.com
  8. */
  9. require_once(dirname(__FILE__)."/config.php");
  10. $uid = empty($uid) ? "" : RemoveXSS($uid);
  11. if (empty($action)) $action = '';
  12. if (empty($aid)) $aid = '';
  13. $menutype = 'mydede';
  14. if ($uid == '') {
  15. $iscontrol = 'yes';
  16. if (!$cfg_ml->IsLogin()) {
  17. include_once(dirname(__FILE__)."/templets/index-notlogin.htm");
  18. } else {
  19. $minfos = $dsql->GetOne("SELECT * FROM `#@__member_tj` WHERE mid='".$cfg_ml->M_ID."'; ");
  20. $minfos['totaluse'] = $cfg_ml->GetUserSpace();
  21. $minfos['totaluse'] = number_format($minfos['totaluse'] / 1024 / 1024, 2);
  22. if ($cfg_mb_max > 0) {
  23. $ddsize = ceil(($minfos['totaluse'] / $cfg_mb_max) * 100);
  24. } else {
  25. $ddsize = 0;
  26. }
  27. require_once(DEDEINC.'/channelunit.func.php');
  28. //最新文档20条
  29. $archives = array();
  30. $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";
  31. $dsql->SetQuery($sql);
  32. $dsql->Execute();
  33. while ($row = $dsql->GetArray()) {
  34. $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']);
  35. $archives[] = $row;
  36. }
  37. $dpl = new DedeTemplate();
  38. $tpl = dirname(__FILE__)."/templets/index.htm";
  39. $dpl->LoadTemplate($tpl);
  40. $dpl->display();
  41. }
  42. }
  43. ?>