立诚勿怠,格物致知
It's all about connecting the dots

标签:sql

wordpress接入七牛云存储和CDN加速

由于博客使用了较多的图片,对首页等页面的加载速度影响较大,对用户体验有一定影响。图片我都会在tinypng等网站上压缩一下再使用。但是对于一些颜色丰富的图片,压缩后大小也比较大。由于个人服务器的带宽有限,访问量一多起来就有点捉襟见肘了。于是,最近两天用上了七牛的存储服务和CDN服务。

记博客访问速度异常慢的优化

感觉是远程开发时在服务器上装软件占用硬盘或者软件资深占用运存过多导致的,或者是迁移数据库造成的,但是同时也会觉得阿里云数据库应该不至于这么慢,不然也太拉胯了。今天看了下宝塔面板,发现硬盘空间已经不多了,猜测最近博客访问慢可能主要是由此导致的(并不是)。

Generate database ER(entity-relationship) diagram

For Macbook user, you can use a software named "DBeaver" to generate database entity-relationship for you automatically. Just select one or multiple tables and then use the menu to generate ER diagram. Here is an ER diagram generated by DBeaver for a Wordpress program,  for reference purpose.

SQL 阅读(2359)去评论赞(0)

how to see sql queried by wordpress when opening a page

For learning purpose, it's meaningful to looking at sql sentences queried by Wordpress. But how to do this? Here is the answer. First, edit the wp-config.php file, just add one line of code. Then, find the common footer.php file of your Wordpress theme, add the following code before the ending html tag (attention: here we only allow administrator to see these sql sentences, taking security into consideration). That's all.

登录

找回密码

注册