• 首页
  • PHP
  • 前端
  • OpenCart
  • ZenCart
  • Wordpress
  • Linux
  • MySQL
  • C语言
  • 感悟
  • 网络编程
  • 关于
作者:老J 时间:2018-07-20 分类:MySQL
-- 改表引擎:
ALTER TABLE `un_user_bank` ENGINE=INNODB;

作者:老J 时间:2018-07-20 分类:MySQL
-- 查看是否全局开启事件
show variables like 'event_scheduler';
-- 设置事件
set global event_scheduler = on;
-- 建立事件
DELIMITER $$
CREATE DEFINER=`root`@`localhost` EVENT `del_music_tips` ON SCHEDULE EVERY 1 DAY STARTS '2018-07-16 12:00:00' ON COMPLETION NOT PRESERVE ENABLE COMMENT '事件备注' DO 
BEGIN
-- [这里写SQL]--
END$$
DELIMITER ;
-- 然后F9执行就可以

作者:老J 时间:2018-07-20 分类:PHP
usleep是微秒,等于百万分之一秒,啥也不说,直接上代码。
usleep(200000);

作者:老J 时间:2018-06-21 分类:PHP
>>> $_config = array('db_host' => 'localhost', 'db_user' => 'edu', 'db_pwd' => 'edu','db_name' => 'edu', 'db_lang' => 'utf8', 'db_prefix' => 'edu_', 'pconnect' => 0,'debug'=>1);
=> [
     "db_host" => "localhost",
     "db_user" => "edu",
     "db_pwd" => "edu",
     "db_name" => "edu",
     "db_lang" => "utf8",
     "db_prefix" => "edu_",
     "pconnect" => 0,
     "debug" => 1,
   ]
>>> 
>>> 
>>> 
>>> $c =  array('db_host' => 'localhost', 'db_user' => 'root', 'db_pwd' => 'xx','db_name' => 'pcdd2', 'db_lang' => 'utf8', 'db_prefix' => 'un_', 'pconnect' => 0,'debug'=>1)
=> [
     "db_host" => "localhost",
     "db_user" => "root",
     "db_pwd" => "xx",
     "db_name" => "xxx",
     "db_lang" => "utf8",
     "db_prefix" => "un_",
     "pconnect" => 0,
     "debug" => 1,
   ]
>>> 
>>> 
>>> array_merge($_config,$c)
=> [
     "db_host" => "localhost",
     "db_user" => "root",
     "db_pwd" => "xx",
     "db_name" => "xxx",
     "db_lang" => "utf8",
     "db_prefix" => "un_",
     "pconnect" => 0,
     "debug" => 1,
   ]
>>>

作者:老J 时间:2018-06-05 分类:Linux
PATH=/software/mysql/bin:$PATH
export PATH
export PATH=/software/mysql/bin:$PATH

作者:老J 时间:2018-05-24 分类:Wordpress
在引用的地方引用全局变量
global $table_prefix;
,然后直接使用这个变量就可以了!

作者:老J 时间:2018-05-15 分类:PHP
>>> $str = "This is some bold text.";
=> "This is some bold text."
>>> htmlspecialchars($str)
=> "This is some <b>bold</b> text."

作者:老J 时间:2018-05-15 分类:PHP
>>> $str = "Who's John Adams?";
=> "Who's John Adams?"
>>> addslashes($str)
=> "Who's John Adams?"

作者:老J 时间:2018-05-15 分类:MySQL
mysql运行久了就会出现大量的二进制文件,可以通过下面的指令清除
reset  master;

作者:老J 时间:2018-05-11 分类:PHP
>>> 8 & 1
=> 0
>>> 7 & 1
=> 1

上一页下一页

LayBlog 强力驱动.
本站重建于2017年12月2日.
部分内容来自网络,如有问题,请联系站长处理.
友情链接: 珠海拖鞋仔博客 | 沉默是金