随笔分类 - PHP
摘要:https://websitebeaver.com/prepared statements in php mysqli to prevent sql injection introduction One Row $result fetch_assoc() Fetch an associative a
阅读全文
摘要:``` name) //wrong can not use this as a parameter function __construct($name) //functions starting with __ change and set the value of any attributes
阅读全文
摘要:https://www.tutorialdocs.com/article/16 php magic methods.html
阅读全文
摘要:``` 30) { $current =$this->$property; //notice: $this->property(without $) will create a new attribute called property, $property $this->$property= $value; echo "You are going to update $property from
阅读全文
摘要:``` '; require('reusable.php'); echo 'The script will end now.'; /* there are three situations here 1. if the reusable.php are those codes, which includes php tags '; ?> then, codes will be processed
阅读全文
摘要:``` "; //3. htmlspecialchars() conflict with html tags $new = htmlspecialchars("Test"); echo $new; // <a href='test'>Test</a> $new = htmlspecialchars("Test", ENT_QUOTES); echo $new; // <a href='test'>
阅读全文
摘要:``` '; //var_dump($numbers); //var_dump($odds); //var_dump($letters); $a[3] = 4; //automatically resize the array //4 $student = ['amy', 'joseph', 'mike']; //read array for ($i = 0; $i 89, 'joseph' =>
阅读全文
摘要:simple functions
阅读全文
摘要:1,执行Linux命令 2.为变量起别名 <?php $a = [1,2,3]; $b = [4,2,3]; print_r($a+$b); print_r($b+$a); ```
阅读全文
摘要:建数据库的时候,已经选择了编码格式为UTF-8但是用PDM生成的脚本导进去的时候却奇怪的发现表和表的字段的编码格式却是GBK,一个一个却又觉得麻烦,在网上找了一下办法一个是修改表的编码格式的ALTER TABLE `table` DEFAULT CHARACTER SET utf8;但是虽然修改了表
阅读全文
摘要:1、查询条件分类 2、sql函数 3、分组查询 4、连接查询 4.2 sql99标准 推荐使用 5、子查询 6、 联合查询 7、DML Data Manipulation language 8、DDL Data Definition Language 9、数据类型 10、常见约束 11、TCL 12
阅读全文

浙公网安备 33010602011771号