phpnow integrated development 1: output, weak variable, global array, md5, time function

1. Foreword
Back-end development: php + mysql
front-end development: html + css + javascript
full-stack development: everything will be
2.1. Output function

	header('Content-Type:text/html;charset=utf-8');
	echo "<h1>hello world</h1>";
	echo ("<h1>hello world</h1>");
	print_r("<h1>hello world</h1>");
	var_dump("hello world");

Insert picture description here
2. Variables (weak variables, determine the type directly according to the content)

	$username='钢铁侠';
	$age=18;
	echo "我是".$username;
	echo "我是{$username},今年{$age}岁";

3. Array (can only be generated by array)
global array:
$ _GET: accept data submitted by get
P THE S T p o s t c o u n t ( _POST: Accept the length of the data array submitted by post: count ( cars)
4.md5 encode
any data into 32-bit hexadecimal string
the only irreversible but can be used to password-protected account
5. time function
time (); // get the current timestamp (in milliseconds with a specified time difference)
dATE ( "MMM d m in the Y h: i: s");

Published 11 original articles · Like1 · Visit 200

Guess you like

Origin blog.csdn.net/weixin_43919927/article/details/105461476