block_threadhot.php 2.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112
  1. <?php
  2. /**
  3. * [Discuz!] (C)2001-2099 Comsenz Inc.
  4. * This is NOT a freeware, use is subject to license terms
  5. *
  6. * $Id: block_threadhot.php 23608 2011-07-27 08:10:07Z cnteacher $
  7. */
  8. if(!defined('IN_DISCUZ')) {
  9. exit('Access Denied');
  10. }
  11. require_once libfile('block_thread', 'class/block/forum');
  12. class block_threadhot extends block_thread {
  13. function block_threadhot() {
  14. $this->setting = array(
  15. 'fids' => array(
  16. 'title' => 'threadlist_fids',
  17. 'type' => 'mselect',
  18. 'value' => array()
  19. ),
  20. 'special' => array(
  21. 'title' => 'threadlist_special',
  22. 'type' => 'mcheckbox',
  23. 'value' => array(
  24. array(1, 'threadlist_special_1'),
  25. array(2, 'threadlist_special_2'),
  26. array(3, 'threadlist_special_3'),
  27. array(4, 'threadlist_special_4'),
  28. array(5, 'threadlist_special_5'),
  29. array(0, 'threadlist_special_0'),
  30. ),
  31. 'default' => array('0')
  32. ),
  33. 'viewmod' => array(
  34. 'title' => 'threadlist_viewmod',
  35. 'type' => 'radio'
  36. ),
  37. 'rewardstatus' => array(
  38. 'title' => 'threadlist_special_reward',
  39. 'type' => 'mradio',
  40. 'value' => array(
  41. array(0, 'threadlist_special_reward_0'),
  42. array(1, 'threadlist_special_reward_1'),
  43. array(2, 'threadlist_special_reward_2')
  44. ),
  45. 'default' => 0,
  46. ),
  47. 'picrequired' => array(
  48. 'title' => 'threadlist_picrequired',
  49. 'type' => 'radio',
  50. 'value' => '0'
  51. ),
  52. 'orderby' => array(
  53. 'title' => 'threadlist_orderby',
  54. 'type'=> 'mradio',
  55. 'value' => array(
  56. array('lastpost', 'threadlist_orderby_lastpost'),
  57. array('dateline', 'threadlist_orderby_dateline'),
  58. array('replies', 'threadlist_orderby_replies'),
  59. array('views', 'threadlist_orderby_views'),
  60. array('heats', 'threadlist_orderby_heats'),
  61. array('recommends', 'threadlist_orderby_recommends'),
  62. ),
  63. 'default' => 'heats'
  64. ),
  65. 'postdateline' => array(
  66. 'title' => 'threadlist_postdateline',
  67. 'type'=> 'mradio',
  68. 'value' => array(
  69. array('0', 'threadlist_postdateline_nolimit'),
  70. array('3600', 'threadlist_postdateline_hour'),
  71. array('86400', 'threadlist_postdateline_day'),
  72. array('604800', 'threadlist_postdateline_week'),
  73. array('2592000', 'threadlist_postdateline_month'),
  74. ),
  75. 'default' => '0'
  76. ),
  77. 'lastpost' => array(
  78. 'title' => 'threadlist_lastpost',
  79. 'type'=> 'mradio',
  80. 'value' => array(
  81. array('0', 'threadlist_lastpost_nolimit'),
  82. array('3600', 'threadlist_lastpost_hour'),
  83. array('86400', 'threadlist_lastpost_day'),
  84. array('604800', 'threadlist_lastpost_week'),
  85. array('2592000', 'threadlist_lastpost_month'),
  86. ),
  87. 'default' => '0'
  88. ),
  89. 'titlelength' => array(
  90. 'title' => 'threadlist_titlelength',
  91. 'type' => 'text',
  92. 'default' => 40
  93. ),
  94. 'summarylength' => array(
  95. 'title' => 'threadlist_summarylength',
  96. 'type' => 'text',
  97. 'default' => 80
  98. ),
  99. );
  100. }
  101. function name() {
  102. return lang('blockclass', 'blockclass_thread_script_threadhot');
  103. }
  104. }
  105. ?>