随笔分类 -  PHP

常用
摘要:echo "<meta http-equiv=\"refresh\" content=\"5;url="."register.php"."\">/n"; 阅读全文
posted @ 2020-12-21 22:43 武卡卡 阅读(47) 评论(0) 推荐(1) 编辑
摘要:Banner::where('title', 'like', "%{$keyword}%")->orWhere('introduce', 'like', "%{$keyword}%")->get(); 阅读全文
posted @ 2020-05-06 22:20 武卡卡 阅读(2091) 评论(0) 推荐(1) 编辑
摘要:<?php session_start(); $codeT = strtoupper(trim($_POST['codeT']));//接收前端传来的数据,转换成大写 $raw_success = array('codeT' => 1, 'msg' => '验证码正确'); $raw_fail = 阅读全文
posted @ 2019-07-21 11:10 武卡卡 阅读(401) 评论(0) 推荐(0) 编辑
摘要:一,主页 index.php <!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> < 阅读全文
posted @ 2019-07-20 18:13 武卡卡 阅读(446) 评论(0) 推荐(0) 编辑
摘要:删除单张图片 <?php require_once '../../conn.php'; //连接数据库 $ID = $_GET['ID']; //获取删除按钮传入要删除图片的 ID $sql = "select * from blogalbum where ID = {$ID}"; $results 阅读全文
posted @ 2019-06-14 16:31 武卡卡 阅读(826) 评论(0) 推荐(0) 编辑
摘要:一,设置 Cookie setcookie("user",$user,time()+3600); // user 为用户名,$user 为变量的值 二,读取 Cookie echo @$_COOKIE["user"]; echo @$_COOKIE["user"]; 阅读全文
posted @ 2019-06-14 09:21 武卡卡 阅读(3541) 评论(0) 推荐(0) 编辑
摘要:一,根据 id 来查询单个的数据 <?php require_once '../../conn.php'; $sql = "select * from blogarticle where ID = {$ID}"; $results = mysql_query($sql); $blog = mysql 阅读全文
posted @ 2019-06-13 22:26 武卡卡 阅读(1148) 评论(0) 推荐(0) 编辑
摘要:1、创建数据表 3、用于点击选择文件后提交页面的index.php 4、实现图片上传的代码存放 upimage.php 5、实现图片显示的getimage.php 阅读全文
posted @ 2019-06-13 20:40 武卡卡 阅读(3621) 评论(0) 推荐(0) 编辑

喜欢请打赏

扫描二维码打赏

支付宝打赏

点击右上角即可分享
微信分享提示