会员
众包
新闻
博问
闪存
赞助商
HarmonyOS
Chat2DB
所有博客
当前博客
我的博客
我的园子
账号设置
会员中心
简洁模式
...
退出登录
注册
登录
venkim
博客园
首页
新随笔
联系
订阅
管理
上一页
1
2
3
4
5
6
下一页
2020年3月16日
纯代码给WordPress后台添加显示用户注册时间和登录 IP 记录
摘要: 在主题functions.php中添加以下代码 /** * add the register record. */ function get_client_ip() { if (getenv("HTTP_CLIENT_IP") && strcasecmp(getenv("HTTP_CLIENT_IP
阅读全文
posted @ 2020-03-16 09:47 venkim
阅读(620)
评论(0)
推荐(0)
2020年2月15日
移除(wp_head)函数-头部不必要的元素标签
摘要: 以下内容都在主题的functions.php文件写入 1.移除WordPress版本信息 remove_action( 'wp_head', 'wp_generator' ); 2.移除离线编辑器开放接口 remove_action( 'wp_head', 'rsd_link' ); remove_
阅读全文
posted @ 2020-02-15 15:00 venkim
阅读(1042)
评论(0)
推荐(0)
引用脚本js文件与css文件
摘要: 使用wp_enqueue_scripts函数配合wp_head()在header.php中使用 在functions.php文件中添加 function tone_front_script() { wp_enqueue_style( 'css名', get_template_directory_ur
阅读全文
posted @ 2020-02-15 14:19 venkim
阅读(425)
评论(0)
推荐(0)
2020年1月23日
wordpress按分类获取文章上下页
摘要: 上一页 <?php $prev_post = get_previous_post(true); if (!empty( $prev_post )): ?> <a href="<?php echo get_permalink( $prev_post->ID ); ?>"></a> <?php endi
阅读全文
posted @ 2020-01-23 13:20 venkim
阅读(359)
评论(0)
推荐(0)
2020年1月21日
WordPress 搜索结果中排除特定的页面、文章和分类
摘要: 在functions.php文件中添加 排除特定 ID 的文章或页面 //搜索结果排除特定 ID 的文章或页面 function Bing_search_filter_id($query) { if ( !$query->is_admin && $query->is_search) { $query
阅读全文
posted @ 2020-01-21 10:24 venkim
阅读(455)
评论(0)
推荐(0)
2020年1月20日
WordPress 自定义查询 WP_Query 所有参数
摘要: <?php /** * WordPress 查询综合参考 * 编译:luetkemj - luetkemj.com * * 官方文档: http://codex.wordpress.org/Class_Reference/WP_Query * 源代码: http://core.trac.wordpr
阅读全文
posted @ 2020-01-20 08:45 venkim
阅读(1235)
评论(0)
推荐(0)
2020年1月17日
get_categories()函数
摘要: get_categories()函数可以获得分类所有信息,返回与查询参数相匹配的类别对象数组。变量与wp_list_categories()函数基本一致,且变量可被作为数组传递,也可在查询句法中被传递。 <?php $categories = get_categories( $args ); ?>
阅读全文
posted @ 2020-01-17 11:18 venkim
阅读(1380)
评论(0)
推荐(0)
2020年1月16日
时间复杂度
摘要: 时间复杂度
阅读全文
posted @ 2020-01-16 20:59 venkim
阅读(105)
评论(0)
推荐(0)
2019年11月26日
vue的生命周期
摘要: <!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <title>vue的生命周期</title> <script src="./js/vue.js"></script> </head> <body> <div id="app
阅读全文
posted @ 2019-11-26 23:35 venkim
阅读(174)
评论(0)
推荐(0)
2019年11月14日
分布式版本控制系统(git)
摘要: 1.git的结构 工作区 >{add}> 暂存区 >{commit}> 本地库 >{push}> 远程库 远程库 >{clone,pull}>本地库 ps:花括号代表其间的操作方式 ,pull由fetch + merge组成 1.1 初始化 git init 1.2 linux查看隐藏文件 ls -
阅读全文
posted @ 2019-11-14 21:01 venkim
阅读(202)
评论(0)
推荐(0)
上一页
1
2
3
4
5
6
下一页
公告