当前位置:网站首页>社交社区论坛APP超高颜值UI界面
社交社区论坛APP超高颜值UI界面
2022-07-03 11:56:00 【程序员-南】
该项目后端采用 thinkphp+mysql
前端使用iAPP框架
论坛、话题、圈子、私信
超高的颜值界面
话不多说上效果图:




<?php
namespace Action;
use HY\Action;
!defined('HY_PATH') && exit('HY_PATH not defined.');
class Index extends HYBBS {
public function __construct(){
parent::__construct();
//{hook a_index_init}
}
public function Index(){
//{hook a_index_index_1}
$this->v('title',$this->conf['title']);
$pageid = intval(X('get.pageid')) or $pageid=1;
$type = X('get.type') or $type='New';
if($type != 'New' && $type != 'Btime')
$type='';
$this->v("type",strtolower($type));
$Thread = M("Thread");
$desc = ['tid' => 'DESC'];
if($type == 'Btime')
$desc = ['btime'=>'DESC']; //最新回复
//{hook a_index_index_11}
$thread_list = $this->CacheObj->get("index_index_".$type.'_'.$pageid);
//获取主题列表
if(empty($thread_list) || DEBUG){
//{hook a_index_index_22}
$thread_list = $Thread->get_thread_list($pageid,$this->conf['homelist'],$desc);
$Thread->format($thread_list);
foreach ($thread_list as $key => $value) {
if($value['top'] == 2)
unset($thread_list[$key]);
}
$this->CacheObj->set("index_index_".$type.'_'.$pageid,$thread_list);
}
//{hook a_index_index_2}
//获取置顶缓存
$top_data=$this->CacheObj->get("top_data_2");
if(empty($top_data) || DEBUG){
//{hook a_index_index_33}
//全局置顶
$top_data = $Thread->get_top_thread();
//格式数据显示
$Thread->format($top_data);
//写入缓存
$this->CacheObj->set("top_data_2",$top_data);
}
//End
//{hook a_index_index_3}
$count = $this->_count['thread'];
$count = (!$count)?1:$count;
$page_count = ($count % $this->conf['homelist'] != 0)?(intval($count/$this->conf['homelist'])+1) : intval($count/$this->conf['homelist']);
//{hook a_index_index_v}
$this->v("pageid",$pageid);
$this->v("page_count",$page_count);
$this->v("thread_list",$thread_list);
$this->v("top_list",$top_data);
$this->display('index_index');
}
//{hook a_index_fun}
}
需要的小伙伴可留下联系方式~
感谢阅读,留下个关注吧~
边栏推荐
- 2.6 preliminary cognition of synergetic couroutines
- Pki/ca and digital certificate
- Self made pop-up input box, input text, and click to complete the event.
- 2020-10_ Development experience set
- 记录自己vulnhub闯关记录
- Swagger
- Integer string int mutual conversion
- Wechat applet pages always report errors when sending values to the background. It turned out to be this pit!
- If you can't learn, you have to learn. Jetpack compose writes an im app (I)
- CNN MNIST handwriting recognition
猜你喜欢

2021 autumn Information Security Experiment 1 (password and hiding technology)

Togaf certification self-study classic v2.0

Take you to the installation and simple use tutorial of the deveco studio compiler of harmonyos to create and run Hello world?

Record your vulnhub breakthrough record

Cloud Computing future - native Cloud

Swagger

Integer int compare size

4000字超详解指针

1-2 project technology selection and structure

What is more elegant for flutter to log out and confirm again?
随机推荐
Dart: About zone
剑指Offer07. 重建二叉树
wpa_ cli
QT OpenGL rotate, pan, zoom
Fluent: Engine Architecture
2.9 overview of databinding knowledge points
Day 1 of kotlin learning: simple built-in types of kotlin
Comprehensive evaluation of double chain notes · Siyuan notes: advantages, disadvantages and evaluation
Use bloc to build a page instance of shutter
LeetCode 0556. Next bigger element III - end of step 4
2020-11_ Technical experience set
(construction notes) learn the specific technology of how to design reusable software entities from three levels: class, API and framework
1-2 project technology selection and structure
Pki/ca and digital certificate
elastic_ L02_ install
Adult adult adult
剑指Offer03. 数组中重复的数字【简单】
MySQL time zone solution
记录自己vulnhub闯关记录
4000 word super detailed pointer