- 2023/04/23
- |
- 知识
- |
- Views: 5,831
- |
- 1 Replies
function get_str($id = 0) {
global $str;
global $mysqli;
$sql = "select * from site_nav where nav_pid= $id order by nav_sort";
$result = mysqli_query($mysqli,$sql);//查询pid的子类的分类
if($result && mysqli_affected_rows($mysqli)){//如果有子类
$str .= '<ul...
- 2022/12/08
- |
- 知识
- |
- Views: 5,801
- |
- 0 Replies
layui提供的固定块功能,语法:util.fixbar(options),默认只有2个图标,如果需要2个以上的图标,可以自己去写式样代码<style>
.custom-footer {
position: fixed;
right: 15px;
bottom: 15px;
z-index: 999999;
}
.custom-footer li {
width: 50px;
height: 50px;
line-height: 50px;
margin-bottom: 1px;
text-align: ...
- 2022/11/20
- |
- 分享
- |
- Views: 5,468
- |
- 0 Replies
PHP获取当前访问文件名$url = $_SERVER['PHP_SELF'];
$arr = explode( '/' , $url );
$filename= $arr[count($arr)-1];
$php_file = substr($filename,0,-4);
导航条 li 增加与文件名一致的ID,使用js给当前访问的菜单追加CLASS<script>
$= layui.$;
$(function(){
$("#<?=$php_file;?>").addClass("active");
});
<...
- 2022/11/14
- |
- 知识
- |
- Views: 5,604
- |
- 0 Replies
success: function(res) {
var iframe = $(res).find('iframe');;
var Height=iframe[0].contentDocument.body.offsetHeight+50
iframe.css('height', Height);
$(res).css('top', (window.innerHeight - Height - 100) / 2);
...
- 2021/11/17
- |
- 知识
- |
- Views: 7,121
- |
- 0 Replies
根据字段A出现的次数进行排序select * from table a left join
(select count(字段A) as cs,字段A from table WHERE userid = 11 group by 字段A ) b
on a.字段A=b.字段A WHERE userid = 11 order by b.cs desc
- 1
- 2
- 3
- 4
- »