• 首页
  • PHP
  • 前端
  • OpenCart
  • ZenCart
  • Wordpress
  • Linux
  • MySQL
  • 感悟
  • 网络编程
  • 关于
作者:老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" => "pcdd2",
     "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" => "pcdd2",
     "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

作者:老J 时间:2018-05-09 分类:MySQL
SELECT last_insert_id()

作者:老J 时间:2018-05-09 分类:PHP
>>> $a=array('name'=>'joinsen','age'=>32)
=> [
     "name" => "joinsen",
     "age" => 32,
   ]
>>> $b = serialize($a)
=> "a:2:{s:4:"name";s:7:"joinsen";s:3:"age";i:32;}"
>>> unserialize($b)
=> [
     "name" => "joinsen",
     "age" => 32,
   ]
>>> 

作者:老J 时间:2018-05-07 分类:前端
//通过内容定位
$(e).parents('tr').find('td:contains("待处理")').html('撤单');

下一页

LayBlog 强力驱动.
本站重建于2017年12月2日.
部分内容来自网络,如有问题,请联系站长处理.
友情链接: LayBlog官网 | 喜剧TV | 珠海杜哥笔记记录 | Linux教程 | 沉默是金